Three.js: SkeletonHelper and colladaLoader2: Helper not visible

Created on 17 Jul 2017  路  2Comments  路  Source: mrdoob/three.js

Description of the problem

Im using the SkeletonHelper on a SkinnedMesh coming from the colladaLoader2.
In r82+colladaLoader I used to traverse the scene, check for a THREE.SkinnedMesh and then create a Helper with the current Object.
Code looked like this:

dae.scene.traverse( function ( child ) {
    if ( child instanceof THREE.SkinnedMesh ) {
        var skeletonHelper = new THREE.SkeletonHelper( child );
        skeletonHelper.material.linewidth = 3;
        skeletonHelper.visible = true;
        scene.add( skeletonHelper );
    }
});

Doing this with r87dev and the colladaLoader2 no skeleton is displayed and no Errors. 鈿狅笍

Looking at the r87dev webgl_loader_collada_skinning (dancing trooper) example you can try it yourself. It looks like currently you have to create the Helper by giving it the dae.scene.
My model contains multiple skinned Meshes, so im looking for a way to create the helper using the particular mesh, not the whole scene. I have to add Im not seeing any problems right now, Im just confused about the change in code.

Three.js version
  • [x] Dev
Browser
  • [x] Firefox
OS
  • [x] Windows

Most helpful comment

Thank you for the clarification Mugen and all the work lately regarding the AnimationSystem.

All 2 comments

SkeletonHelper assumes that bones are children of the skinned mesh. This ist not true for ColladaLoader2. In order to support correct transformations of skeletons it was necessary to leave all joint nodes in their original position in the scene hierarchy.

Thank you for the clarification Mugen and all the work lately regarding the AnimationSystem.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

makc picture makc  路  3Comments

jlaquinte picture jlaquinte  路  3Comments

fuzihaofzh picture fuzihaofzh  路  3Comments

seep picture seep  路  3Comments

yqrashawn picture yqrashawn  路  3Comments