Project

General

Profile

« Previous | Next » 

Revision 7d8cc029

Added by Leszek Koltunski about 3 years ago

Simplify.

View differences:

src/main/java/org/distorted/objects/TwistyBandaged3Plate.java
95 95
       { 0.0f,  0.0f, -1.0f}
96 96
      };
97 97

  
98
  private final double[][] VERTICES_SMALL = new double[][]
99
          {
100
              { 0.5, 0.5, 0.5 },
101
              { 0.5, 0.5,-0.5 },
102
              { 0.5,-0.5, 0.5 },
103
              { 0.5,-0.5,-0.5 },
104
              {-0.5, 0.5, 0.5 },
105
              {-0.5, 0.5,-0.5 },
106
              {-0.5,-0.5, 0.5 },
107
              {-0.5,-0.5,-0.5 },
108
          };
109

  
110
  private final double[][] VERTICES_BIG = new double[][]
111
          {
112
              // TODO
113
          };
114

  
115
  private final int[][] VERT_INDEXES = new int[][]
116
          {
117
              {2,3,1,0},   // counterclockwise!
118
              {7,6,4,5},
119
              {4,0,1,5},
120
              {7,3,2,6},
121
              {6,2,0,4},
122
              {3,7,5,1}
123
          };
124

  
125 98
  private static final int[] QUAT_INDICES = new int[] { 1, 3 };
126 99

  
127 100
///////////////////////////////////////////////////////////////////////////////////////////////////
......
132 105
    super(size, quat, texture, mesh, effects, moves, ObjectList.BAN3, res, scrWidth);
133 106
    }
134 107

  
135
///////////////////////////////////////////////////////////////////////////////////////////////////
136

  
137
  double[][] getVertices(int cubitType)
138
    {
139
     if( cubitType==0 )  // Small cubit
140
      {
141
      return VERTICES_SMALL;
142
      }
143
    if( cubitType==1 )  // Big cubit
144
      {
145
      return VERTICES_BIG;
146
      }
147

  
148
    return null;
149
    }
150

  
151
///////////////////////////////////////////////////////////////////////////////////////////////////
152

  
153
  int[][] getVertIndexes(int cubitType)
154
    {
155
    return VERT_INDEXES;
156
    }
157

  
158
///////////////////////////////////////////////////////////////////////////////////////////////////
159

  
160
  int getNumCubitTypes(int numLayers)
161
    {
162
    return 2;
163
    }
164

  
165 108
///////////////////////////////////////////////////////////////////////////////////////////////////
166 109

  
167 110
  float[][] getPositions()

Also available in: Unified diff