Jump to content

How to scale a bone?


hen
 Share

Recommended Posts

Not enough information.  Scaling is part of animation matrix, so you could have an animation of scaling.

Is this about copying AnimationRanges from one skeleton to another with same structure?  There is a length member of a bone, if your export populates it.  There is also a skeleton method I just added, which uses bone.length if present & rescaleAsRequired = true:

/** 
  *  note: This is not for a complete retargeting, only between very similar skeleton's with only possible bone length differences
 */
public copyAnimationRange(source: Skeleton, name: string, rescaleAsRequired = false): boolean {

If you are doing a complete re-targeting, with different skeleton structure & or bone names, you are on your own.  I am also in the process of adding a rest pose member, if this might help.  Blender exporter is only exporter populating length & rest pose, AFAIK.

Link to comment
Share on other sites

4 minutes ago, bulisor said:

Relate to this question.

Here is an old topic, where you can find the answer.

Ohhh thanks!!

Thats not the answer i expected :(  

Now im confused if there is some workaround. Otherwise i cannot use babylon anymore.

Link to comment
Share on other sites

  • 2 weeks later...

Another question regarding this..

I understand the animation does set the bone matrix with every frame.
Actually i dont like the solution to apply scaling before rendering every animation frame. 
That would just destroy the good animation performance babylon has.

Would it maybe possible to loop over all frames to apply the scaling to the whole animation?
Like i would only do this once on animation start and not update before rendering each frame?

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...