Parcourir la source

Editor: Ensure to correctly configure GLTFLoader with DRACOLoader.

Mugen87 il y a 5 ans
Parent
commit
8e37797a0d
1 fichiers modifiés avec 4 ajouts et 0 suppressions
  1. 4 0
      editor/js/Loader.js

+ 4 - 0
editor/js/Loader.js

@@ -219,7 +219,11 @@ var Loader = function ( editor ) {
 
 					} else {
 
+						var dracoLoader = new DRACOLoader();
+						dracoLoader.setDecoderPath( '../examples/js/libs/draco/gltf/' );
+
 						loader = new GLTFLoader( manager );
+						loader.setDRACOLoader( dracoLoader );
 
 					}