Project

General

Profile

« Previous | Next » 

Revision 5581ba2b

Added by Leszek Koltunski about 4 years ago

Progress with the Skewb Diamond.

View differences:

src/main/java/org/distorted/objects/TwistyDiamond.java
73 73

  
74 74
  private static final int[] FACE_COLORS = new int[]
75 75
         {
76
           COLOR_YELLOW, COLOR_WHITE,
77
           COLOR_BLUE  , COLOR_GREEN,
78
           COLOR_RED   , COLOR_BROWN,
79
           COLOR_PINK  , COLOR_VIOLET
76
           COLOR_YELLOW, COLOR_WHITE ,
77
           COLOR_BLUE  , COLOR_GREEN ,
78
           COLOR_PINK  , COLOR_VIOLET,
79
           COLOR_RED   , COLOR_BROWN ,
80 80
         };
81 81

  
82 82
  // All legal rotation quats of a Diamond: unit + three 180 deg turns + 8 generators
......
163 163
    float[] vertices = { -F,-E/3, +F,-E/3, 0.0f,2*E/3};
164 164

  
165 165
    float[] bands = new float[] { 1.0f    , 0,
166
                                  1.0f  -C, D*0.50f,
167
                                  1.0f-2*C, D*0.80f,
168
                                  1.0f-4*C, D*1.00f,
169
                                  0.5f    , D*1.20f,
170
                                  0.0f    , D*1.25f };
166
                                  1.0f  -C, D*0.55f,
167
                                  1.0f-2*C, D*0.85f,
168
                                  1.0f-4*C, D*1.20f,
169
                                  0.5f    , D*1.40f,
170
                                  0.0f    , D*1.50f };
171 171

  
172 172
    MeshBase[] meshes = new MeshPolygon[FACES_PER_CUBIT];
173 173
    meshes[0] = new MeshPolygon(vertices, bands, 2,2);
......
281 281
    float[] bands = new float[] { 1.0f    , 0,
282 282
                                  1.0f  -C, D*0.50f,
283 283
                                  1.0f-2*C, D*0.80f,
284
                                  1.0f-4*C, D*1.00f,
285
                                  0.5f    , D*1.20f,
286
                                  0.0f    , D*1.25f };
284
                                  1.0f-4*C, D*1.10f,
285
                                  0.5f    , D*1.30f,
286
                                  0.0f    , D*1.35f };
287 287

  
288 288
    MeshBase[] meshes = new MeshBase[FACES_PER_CUBIT];
289 289
    meshes[0] = new MeshPolygon(vertices, bands, 2,2);
......
424 424

  
425 425
  float getBasicStep()
426 426
    {
427
    return SQ6/6;
427
    return SQ6/4;
428 428
    }
429 429

  
430 430
///////////////////////////////////////////////////////////////////////////////////////////////////
src/main/java/org/distorted/objects/TwistyObject.java
61 61
  static final int COLOR_GREEN  = 0xff00ff00;
62 62
  static final int COLOR_RED    = 0xffff0000;
63 63
  static final int COLOR_BROWN  = 0xffb5651d;
64
  static final int COLOR_PINK   = 0xffe134eb;
65
  static final int COLOR_VIOLET = 0xffa534eb;
64
  static final int COLOR_PINK   = 0xffff90ff;
65
  static final int COLOR_VIOLET = 0xff7700bb;
66 66

  
67 67
  private static final float NODE_RATIO = 1.32f;
68 68
  private static final float MAX_SIZE_CHANGE = 1.3f;

Also available in: Unified diff