Explorar o código

Fix updatable buffers

sebavan %!s(int64=4) %!d(string=hai) anos
pai
achega
6b06dc23be
Modificáronse 1 ficheiros con 2 adicións e 2 borrados
  1. 2 2
      src/Meshes/geometry.ts

+ 2 - 2
src/Meshes/geometry.ts

@@ -208,7 +208,7 @@ export class Geometry implements IGetSetVerticesData {
 
         // Index buffer
         if (this._meshes.length !== 0 && this._indices) {
-            this._indexBuffer = this._engine.createIndexBuffer(this._indices);
+            this._indexBuffer = this._engine.createIndexBuffer(this._indices, this._updatable);
         }
 
         // Vertex buffers
@@ -752,7 +752,7 @@ export class Geometry implements IGetSetVerticesData {
 
         // indexBuffer
         if (numOfMeshes === 1 && this._indices && this._indices.length > 0) {
-            this._indexBuffer = this._engine.createIndexBuffer(this._indices);
+            this._indexBuffer = this._engine.createIndexBuffer(this._indices, this._updatable);
         }
         if (this._indexBuffer) {
             this._indexBuffer.references = numOfMeshes;