2
0
Эх сурвалжийг харах

Support Texture datatype in GLTFLoader

Takahiro 8 жил өмнө
parent
commit
b06ab4048c

+ 2 - 0
examples/js/loaders/GLTFLoader.js

@@ -1072,6 +1072,8 @@ THREE.GLTFLoader = ( function () {
 
 							if ( texture.name !== undefined ) _texture.name = texture.name;
 
+							_texture.type = texture.type !== undefined ? WEBGL_TEXTURE_TYPES[ texture.type ] : THREE.UnsignedByteType;
+
 							if ( texture.sampler ) {
 
 								var sampler = json.samplers[ texture.sampler ];