Explorar el Código

Merge pull request #18066 from TyLindberg/gltf-draco-preload

GLTFLoader: Preload DRACO libraries on DRACO glTF load
Mr.doob hace 5 años
padre
commit
92630a886c
Se han modificado 2 ficheros con 2 adiciones y 0 borrados
  1. 1 0
      examples/js/loaders/GLTFLoader.js
  2. 1 0
      examples/jsm/loaders/GLTFLoader.js

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

@@ -490,6 +490,7 @@ THREE.GLTFLoader = ( function () {
 		this.name = EXTENSIONS.KHR_DRACO_MESH_COMPRESSION;
 		this.json = json;
 		this.dracoLoader = dracoLoader;
+		this.dracoLoader.preload();
 
 	}
 

+ 1 - 0
examples/jsm/loaders/GLTFLoader.js

@@ -557,6 +557,7 @@ var GLTFLoader = ( function () {
 		this.name = EXTENSIONS.KHR_DRACO_MESH_COMPRESSION;
 		this.json = json;
 		this.dracoLoader = dracoLoader;
+		this.dracoLoader.preload();
 
 	}