Revision 12aa6192
Added by Leszek Koltunski over 3 years ago
src/main/java/org/distorted/objectlib/helpers/FactoryBandaged3x3Cubit.java | ||
---|---|---|
21 | 21 |
|
22 | 22 |
import java.util.ArrayList; |
23 | 23 |
|
24 |
import org.distorted.library.mesh.MeshBase; |
|
24 | 25 |
import org.distorted.library.type.Static3D; |
25 | 26 |
import org.distorted.objectlib.touchcontrol.TouchControlHexahedron; |
26 | 27 |
|
28 |
import static org.distorted.objectlib.main.TwistyObject.MESH_NICE; |
|
29 |
|
|
27 | 30 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
28 | 31 |
|
29 | 32 |
public class FactoryBandaged3x3Cubit |
... | ... | |
1169 | 1172 |
|
1170 | 1173 |
return new ObjectFaceShape(bands,bandIndices,corners,cornerIndices,centers,centerIndices,null); |
1171 | 1174 |
} |
1175 |
|
|
1176 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
|
1177 |
|
|
1178 |
public MeshBase createMesh(float[] pos) |
|
1179 |
{ |
|
1180 |
prepare(1); |
|
1181 |
ObjectShape shape = createIrregularShape(0,pos); |
|
1182 |
ObjectFaceShape face = createIrregularFaceShape(0); |
|
1183 |
int[][] indices = shape.getVertIndices(); |
|
1184 |
int numComponents = indices.length; |
|
1185 |
|
|
1186 |
FactoryCubit factory = FactoryCubit.getInstance(); |
|
1187 |
factory.createNewFaceTransform(shape,null); |
|
1188 |
return factory.createRoundedSolid(shape,face,MESH_NICE,numComponents); |
|
1189 |
} |
|
1172 | 1190 |
} |
Also available in: Unified diff
Beginnings of support for display of a collection of bandaged cubits in the CreatorView.