Project

General

Profile

« Previous | Next » 

Revision e6cf7283

Added by Leszek Koltunski about 3 years ago

Change the Cubit center from a Static3D to a float[].
The point: now we can have more than one center, and bandaged objects need more than one, because in this way they are going to fill up their RotationRow bitmaps.

View differences:

src/main/java/org/distorted/objects/TwistyDino.java
74 74
         };
75 75

  
76 76
  // centers of the 12 edges. Must be in the same order like QUATs above.
77
  private static final Static3D[] CENTERS = new Static3D[]
77
  private static final float[][] CENTERS = new float[][]
78 78
         {
79
           new Static3D( 0.0f, 1.5f, 1.5f ),
80
           new Static3D( 1.5f, 0.0f, 1.5f ),
81
           new Static3D( 0.0f,-1.5f, 1.5f ),
82
           new Static3D(-1.5f, 0.0f, 1.5f ),
83
           new Static3D( 1.5f, 1.5f, 0.0f ),
84
           new Static3D( 1.5f,-1.5f, 0.0f ),
85
           new Static3D(-1.5f,-1.5f, 0.0f ),
86
           new Static3D(-1.5f, 1.5f, 0.0f ),
87
           new Static3D( 0.0f, 1.5f,-1.5f ),
88
           new Static3D( 1.5f, 0.0f,-1.5f ),
89
           new Static3D( 0.0f,-1.5f,-1.5f ),
90
           new Static3D(-1.5f, 0.0f,-1.5f )
79
             { 0.0f, 1.5f, 1.5f },
80
             { 1.5f, 0.0f, 1.5f },
81
             { 0.0f,-1.5f, 1.5f },
82
             {-1.5f, 0.0f, 1.5f },
83
             { 1.5f, 1.5f, 0.0f },
84
             { 1.5f,-1.5f, 0.0f },
85
             {-1.5f,-1.5f, 0.0f },
86
             {-1.5f, 1.5f, 0.0f },
87
             { 0.0f, 1.5f,-1.5f },
88
             { 1.5f, 0.0f,-1.5f },
89
             { 0.0f,-1.5f,-1.5f },
90
             {-1.5f, 0.0f,-1.5f }
91 91
         };
92 92

  
93 93
  private static MeshBase mMesh;
......
184 184

  
185 185
///////////////////////////////////////////////////////////////////////////////////////////////////
186 186

  
187
  Static3D[] getCubitPositions(int size)
187
  float[][] getCubitPositions(int size)
188 188
    {
189 189
    return CENTERS;
190 190
    }

Also available in: Unified diff