SkeletonViewer v4.2 - What changed?

That was very fast, thank you!

Do you happen to know why the mesh disappears when I bind it to the bone?

Looking into that too, I am fixing it working with the new display modes as well for you.

Update
Ohh it was your weights, Ill fix that in the demo back to you.

1 Like

Playing with this a little more, & do not see a reason to have a separate topic. Wanted to see what the other display types looked like. Had to run update() to get out of stick, but no problem. The sphere & spurs type “worked”, but it was much higher & behind the actual mesh.

I should point out that the rootbone & the origin of the mesh are at the pelvis, and I exported that way. On load, I raise the mesh so that the feet are on the ground. I also moved it .42 meters backward & parented to the mesh to a keyboard stand. The stand is set to invisible in the picture, so I can get a better look at the fingers from behind.

While seems like it could be an edge case, in line display it works, so thought you might want to know.

can you send me your GLB so I can look at it?

I gotta figure all these fringe cases out.

“Had to run update()” You should not have to let me look into that.

First, I use inline javascript, mesh subclass generation out of Blender, not GLB. The meshes are multiple sub-classes to BABYLON.Mesh, so I would also have to send a JS which had an intermediate class. that’s how I implement speech / expressions & integrate with my animation system. Very clean if you have all the parts.

No matter, a few quick test results:

  • turning off the parenting, but still doing the positioning changed nothing.
  • leaving the parenting, but taking out the moves got the viewer positioned in the right place.

I tried to modify a PG I made recently, and even with update(), it did not change. I did a straight cut and paste. This PG does adds the viewer before an actual render. My scene did it off a checkbox callback, so it might be related to that. Maybe look at that first, then I’ll work on a PG to do the same thing as my scene.

No hurry. I do not really need this.

edit: https://www.babylonjs-playground.com/#VSURBJ#1

@reimund Just trying to make a few revisions to get my PG accepted and your update will be live.

1 Like

@reimund this fix should be live, let me know if it works for you now!

@Pryme8 seems to be working, awesome! Thanks a lot.

The version is still 4.2.0-alpha.35, is that correct? I was expecting the 35 to get bumped as things are fixed/added, but I guess not?

Yes, the version is still an alpha 35. The number is not bumped each time there’s a nighly build, else we would be in the 500 or 600 :slight_smile:

A new npm will be deployed next week :slight_smile:

on it! It will be the first BETA!! Hurray!

1 Like

I should have the tutorials and documents done on it this week as well!

2 Likes

Nice.

What about the other display modes? I never got any of them working.
Also I wonder why there’s both a method changeDisplayMode and a setter for displayMode. Looks to me like changeDisplayMode is the preferred way to change the mode.

Another small thing I just noticed: in the documentation for displayMode's getter and setter, there seem to be leftovers from the getter and setter of the material property.

Perhaps the setter can either be removed or maybe we should add a hint in the documentation that it’s better to use changeDisplayMode?

I will be doing the docs here this week!

With example playgrounds and explanations.

Ill take a look at your suggestions now.

For the other display modes, make sure you have your restPoses bound to the bones correctly as they rely on that.

1 Like

I’m actually quite confused about the rest pose.

My initial idea was that the pose the bones are in when I assign the skeleton to a mesh would be treated as the rest pose. Is that assumption correct? If there is any in-depth resource/how-to on the topic I would be happy to learn about it!

I also noticed that there are methods for both getRestPose and getBindPose. I thought rest pose and bind pose was the exact same thing. Having both leads me to believe they are not the same thing in the world of Babylon.

Another thing I probably will be needing is a visual representation of the local coordinate system for each bone. I’m not sure if it’s built in to Babylon. I might have to try to create it myself. To get an idea of if my skeleton is created correctly.

https://playground.babylonjs.com/#76444U#32

Maybe @Evgeni_Popov would know how to get the correct matrices bound to the skeleton.

I know in the bones constructors there are arguments for them, so I bet you need to include them.

nevermind here you go!
https://playground.babylonjs.com/#76444U#34

1 Like

Cool, thanks!

Another thing I noticed when I tried to get/set the material:

console.log(skeletonViewer.material);

Gives you

babylon.max.js:29956 Uncaught (in promise) RangeError: Maximum call stack size exceeded at SkeletonViewer.get

I’ll fix this one. The material property is not used. I will remove it

1 Like

Power is on today, I can fix that @Deltakosh