我有这个功能来运行动画,但我得到了
无法找到皮肤的骨架!
实际上,当fbx动画时,我使用Clara io从fbx转换为collada,并且我检测到collada是否被帧或骨架动画化。我有关于骨架的动画问题
function loadObjectAnimatedFrames(){
console.log("Loading Object Frames Animated");
var loader = new THREE.ColladaLoader();
loader.load( modelPath.val(), function ( collada ) {
model = collada.scene;
animations = collada.animations;
kfAnimationsLength = animations.length;
var box = new THREE.Box3().setFromObject( model );
setConfigObject(model,box);
activeModel = model;
objControl = new THREE.TransformControls( camera, renderer.domElement );
objControl.addEventListener( 'change', render );
objControl.setSize( .1);
objControl.attach( model );
scene.add( objControl );
for ( var i = 0; i < kfAnimationsLength; ++i ) {
var animation = animations[ i ];
var kfAnimation = new THREE.KeyFrameAnimation( animation );
kfAnimation.timeScale = 1;
kfAnimations.push( kfAnimation );
}
start();
animateFrames( lastTimestamp );
scene.add( model );
});
}