Sfoglia il codice sorgente

Removed redundant type check, per PR feedback.

Justin Murray 6 anni fa
parent
commit
c0013ee64f
1 ha cambiato i file con 1 aggiunte e 2 eliminazioni
  1. 1 2
      src/Engines/nativeEngine.ts

+ 1 - 2
src/Engines/nativeEngine.ts

@@ -1090,8 +1090,7 @@ export class NativeEngine extends Engine {
     }
 
     private static _GetNativeTextureFormat(format: number, type: number): number {
-        if (format == Engine.TEXTUREFORMAT_RGBA && (type == Engine.TEXTURETYPE_UNSIGNED_INT || type == Engine.TEXTURETYPE_UNSIGNED_BYTE)) {
-            // Note: Babylon considers TEXTURETYPE_UNSIGNED_INT and TEXTURETYPE_UNSIGNED_BYTE to be synonyms.
+        if (format == Engine.TEXTUREFORMAT_RGBA && type == Engine.TEXTURETYPE_UNSIGNED_INT) {
             return NativeTextureFormat.RGBA8;
         }
         else if (format == Engine.TEXTUREFORMAT_RGBA && type == Engine.TEXTURETYPE_FLOAT) {