提交 0647e1ce 编写于 作者: M Mr.doob

WebGLRenderer: Simplified updateSkeletons code.

上级 884205e8
......@@ -3185,7 +3185,8 @@ THREE.WebGLRenderer = function ( parameters ) {
if ( camera.parent === undefined ) camera.updateMatrixWorld();
// update Skeleton objects
function updateSkeletons( object ) {
scene.traverse( function ( object ) {
if ( object instanceof THREE.SkinnedMesh ) {
......@@ -3193,15 +3194,7 @@ THREE.WebGLRenderer = function ( parameters ) {
}
for ( var i = 0, l = object.children.length; i < l; i ++ ) {
updateSkeletons( object.children[ i ] );
}
}
updateSkeletons( scene );
} );
camera.matrixWorldInverse.getInverse( camera.matrixWorld );
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册