Explorar o código

Examples: Improve webgl_skinning_simple

Mugen87 %!s(int64=7) %!d(string=hai) anos
pai
achega
648e6b9d5b

BIN=BIN
examples/models/gltf/SimpleSkinning.glb


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 288 - 0
examples/models/gltf/SimpleSkinning.gltf


+ 2 - 6
examples/webgl_skinning_simple.html

@@ -95,17 +95,13 @@
 				//
 
 				var loader = new THREE.GLTFLoader();
-				loader.load( './models/gltf/SimpleSkinning.glb', function ( gltf ) {
+				loader.load( './models/gltf/SimpleSkinning.gltf', function ( gltf ) {
 
 					scene.add( gltf.scene );
 
 					gltf.scene.traverse( function ( child ) {
 
-						if ( child.isMesh ) {
-
-							child.castShadow = true;
-
-						}
+						if ( child.isSkinnedMesh ) child.castShadow = true;
 
 					} );
 

Algúns arquivos non se mostraron porque demasiados arquivos cambiaron neste cambio