Explorar el Código

Merge pull request #8810 from Popov72/mesh-clone-getter

Add a cloneMeshMap getter to the Mesh class
David Catuhe hace 5 años
padre
commit
6fea19db83
Se han modificado 1 ficheros con 9 adiciones y 0 borrados
  1. 9 0
      src/Meshes/mesh.ts

+ 9 - 0
src/Meshes/mesh.ts

@@ -394,6 +394,15 @@ export class Mesh extends AbstractMesh implements IGetSetVerticesData {
     }
     }
 
 
     /**
     /**
+     * Gets the list of clones of this mesh
+     * The scene must have been constructed with useClonedMeshMap=true for this to work!
+     * Note that useClonedMeshMap=true is the default setting
+     */
+    public get cloneMeshMap(): Nullable<{ [id: string]: Mesh | undefined }> {
+        return this._internalMeshDataInfo.meshMap;
+    }
+
+    /**
      * Gets or sets a boolean indicating that this mesh does not use index buffer
      * Gets or sets a boolean indicating that this mesh does not use index buffer
      */
      */
     public get isUnIndexed(): boolean {
     public get isUnIndexed(): boolean {