浏览代码

Fixed MorphAnimation mesh reference.

Mr.doob 11 年之前
父节点
当前提交
dcc9353317
共有 1 个文件被更改,包括 5 次插入5 次删除
  1. 5 5
      src/extras/animation/MorphAnimation.js

+ 5 - 5
src/extras/animation/MorphAnimation.js

@@ -51,17 +51,17 @@ THREE.MorphAnimation.prototype = {
 
 
 			if ( frame != currentFrame ) {
 			if ( frame != currentFrame ) {
 
 
-				mesh.morphTargetInfluences[ lastFrame ] = 0;
-				mesh.morphTargetInfluences[ currentFrame ] = 1;
-				mesh.morphTargetInfluences[ frame ] = 0;
+				this.mesh.morphTargetInfluences[ lastFrame ] = 0;
+				this.mesh.morphTargetInfluences[ currentFrame ] = 1;
+				this.mesh.morphTargetInfluences[ frame ] = 0;
 
 
 				lastFrame = currentFrame;
 				lastFrame = currentFrame;
 				currentFrame = frame;
 				currentFrame = frame;
 
 
 			}
 			}
 
 
-			mesh.morphTargetInfluences[ frame ] = ( currentTime % interpolation ) / interpolation;
-			mesh.morphTargetInfluences[ lastFrame ] = 1 - mesh.morphTargetInfluences[ frame ];
+			this.mesh.morphTargetInfluences[ frame ] = ( currentTime % interpolation ) / interpolation;
+			this.mesh.morphTargetInfluences[ lastFrame ] = 1 - this.mesh.morphTargetInfluences[ frame ];
 
 
 		}
 		}