Ver código fonte

Fix error in engine.rawTextureGL2

Alex Gordon 5 anos atrás
pai
commit
b3008ddcff
1 arquivos alterados com 5 adições e 1 exclusões
  1. 5 1
      src/Engines/Extensions/engine.rawTextureGL2.ts

+ 5 - 1
src/Engines/Extensions/engine.rawTextureGL2.ts

@@ -94,7 +94,11 @@ function _createRawTextureFunction(is3D: boolean) {
         texture.type = textureType;
         texture.generateMipMaps = generateMipMaps;
         texture.samplingMode = samplingMode;
-        texture.is3D = true;
+        if (is3D) {
+            texture.is3D = true;
+        } else {
+            texture.is2DArray = true;
+        }
 
         if (!this._doNotHandleContextLost) {
             texture._bufferView = data;