|
@@ -147,13 +147,14 @@ function loadGeometry( data, url ) {
|
|
|
|
|
|
} else {
|
|
} else {
|
|
|
|
|
|
|
|
+ mesh = new THREE.Mesh( data.geometry, material );
|
|
|
|
+
|
|
if ( data.geometry.morphTargets.length > 0 ) {
|
|
if ( data.geometry.morphTargets.length > 0 ) {
|
|
|
|
|
|
console.log( 'loading morph targets' );
|
|
console.log( 'loading morph targets' );
|
|
data.materials[ 0 ].morphTargets = true;
|
|
data.materials[ 0 ].morphTargets = true;
|
|
- mesh = new THREE.MorphAnimMesh( data.geometry, material );
|
|
|
|
|
|
|
|
- mixer = mesh.mixer;
|
|
|
|
|
|
+ mixer = new THREE.AnimationMixer( mesh );
|
|
animation = mixer.clipAction( mesh.geometry.animations[ 0 ] );
|
|
animation = mixer.clipAction( mesh.geometry.animations[ 0 ] );
|
|
hasMorph = true;
|
|
hasMorph = true;
|
|
|
|
|