Revision 2402d0ff
Added by Leszek Koltunski over 2 years ago
src/main/java/org/distorted/objectlib/objects/TwistyCuboid.java | ||
---|---|---|
250 | 250 |
{3,7,5,1} |
251 | 251 |
}; |
252 | 252 |
|
253 |
float[][] corners = new float[][] { {0.036f,0.12f} }; |
|
254 |
float[][] centers = new float[][] { {0.0f, 0.0f, 0.0f} }; |
|
255 |
int[] indices = new int[] { 0,0,0,0,0,0,0,0 }; |
|
256 |
|
|
257 |
int extraI2 = numL<=3 ? num-2 : 0; |
|
258 |
|
|
259 |
float[][] bands = new float[][] |
|
253 |
float[][] corners= new float[][] { {0.036f,0.12f} }; |
|
254 |
float[][] centers= new float[][] { {0.0f, 0.0f, 0.0f} }; |
|
255 |
int[] indices = new int[] { 0,0,0,0,0,0,0,0 }; |
|
256 |
float[][] bands = new float[][] |
|
260 | 257 |
{ |
261 |
{height,35,0.5f,0.7f,num,extraI ,extraV}, |
|
262 |
{height,35,0.5f,0.7f, 2,extraI2, 0}, |
|
263 |
{height,35,0.5f,0.7f, 2, 0, 0}, |
|
264 |
{height,35,0.5f,0.7f, 2, num-2,extraV}, |
|
258 |
{height,35,0.5f,0.7f,num,extraI,extraV}, |
|
259 |
{height,35,0.5f,0.7f, 2, num-2,extraV}, |
|
260 |
{height,35,0.5f,0.7f, 2, 0, 0}, |
|
265 | 261 |
}; |
266 | 262 |
|
267 | 263 |
int[] bandIndices; |
268 | 264 |
|
269 | 265 |
if( variant==0 ) bandIndices = new int[] {0,0,0,0,0,0}; |
270 |
else if( variant==1 ) bandIndices = new int[] {3,3,3,0,3,0};
|
|
271 |
else bandIndices = new int[] {1,1,1,1,0,2};
|
|
266 |
else if( variant==1 ) bandIndices = new int[] {1,1,1,0,1,0};
|
|
267 |
else bandIndices = new int[] {2,2,2,2,0,2};
|
|
272 | 268 |
|
273 | 269 |
return new ObjectShape(vertices,vert_indices,bands,bandIndices,corners,indices,centers,indices,getNumCubitFaces(), null); |
274 | 270 |
} |
Also available in: Unified diff
Correct the edges of the cuboid mesh - part 2.