@@ -1798,6 +1798,12 @@ var BABYLON;
tube.arc = arc;
return tube;
};
+ Mesh.CreatePolyhedron = function (name, options, scene) {
+ var polyhedron = new Mesh(name, scene);
+ var vertexData = BABYLON.VertexData.CreatePolyhedron(options);
+ vertexData.applyToMesh(polyhedron, options.updatable);
+ return polyhedron;
+ };
Mesh.CreateDecal = function (name, sourceMesh, positionOrOptions, normal, size, angle) {
if (angle === void 0) { angle = 0; }
var indices = sourceMesh.getIndices();
@@ -2076,7 +2076,7 @@
}
- public static CreatePolyhedron(name: string, options: {type?: number, size?: number, sizeX?: number, sizeY?: number, sizeZ?: number, custom?: any, faceUV?: Vector4[], faceColors?: Color4[], updatable?: boolean, sideOrientation?: number}, scene: Scene): Mesh {
+ public static CreatePolyhedron(name: string, options: { type?: number, size?: number, sizeX?: number, sizeY?: number, sizeZ?: number, custom?: any, faceUV?: Vector4[], faceColors?: Color4[], updatable?: boolean, sideOrientation?: number }, scene: Scene): Mesh {
var polyhedron = new Mesh(name, scene);
var vertexData = VertexData.CreatePolyhedron(options);
@@ -2486,3 +2486,4 @@
+