Maya rig joint based + corrective blendshape

Hi everybody,

I am trying to export a rig that I made in maya. I built the facial rig with a double system of bones and corrective blendshapes. Now the movement of my joint is the same that I have in maya, but the deformation of the blendshape happens on a different time range.
what am i doing wrong? I cannot obtain the results that I have in maya.

Many thanks

maybe @PatrickRyan can help?

@gerald85, I’m happy to help you with your issue, but it is hard to understand the context with just words. Can you share screen shots or videos of what you are seeing? Also, can you describe your export process and what you have checked in the exporter window? If this is a project that isn’t public, you can message me directly and I can help you that way too.

hey Patrick,
thank you so much for your help. I can share it, it’s just a test for now.
Unfortunately the forum doesn’t let me upload video.

“Sorry, new users can not upload attachments.”

I can send u the file in any other way?

Thanks a lot

Gerald

@gerald85, this has to do with Discourse’s trust level. Basically it’s so that people can’t sign up for a new account and then spam links to the community. You can get out of the new user trust level (0) by doing the following:

Get to trust level 1 by…

  • Entering at least 5 topics
  • Reading at least 30 posts
  • Spend a total of 10 minutes reading posts

Understanding Discourse Trust Levels | Blog

You can then post links and more than one image. I know this is a bit of an artificial hurdle, but it is bad practice for us to just change the trust level on an account arbitrarily, and you may want to get to know more of the forum as you are starting your journey here.

Thanks @PatrickRyan. In the meantime I’ve almost finished my rig without blendshape.
I am still curious about it, cause I can always implement it with some blendshapes :slight_smile:
I am having some problems now with props attached with constraint that are not following the animation after the export. I am gonna post the videos asap.

Cherers

thanks @Deltakosh

@PatrickRyan this is the first test that I try to export in babylon. As you can see from the video below, when I move the corner of the mouth, a blendshape modifies the cheek of the char.

I

And this is a printscreen of the export window.

And the .gbl file zipped :slight_smile:

test_blendshape_bee.zip (141.9 KB)

@gerald85 you can either .zip the .glb file and attach it to your message or you can share with a link to github, dropbox, google drive, etc.

@gerald85, there are a couple of things to note in the warnings in the export window. The first is that if you are using morph targets, you can’t use optimize mesh as that would change the triangle list and break your morph target. We do disable that at export when we see morph targets, but just for a gut check, make sure to uncheck that box.

The second thing to address is that you have too many influences per vertex in your skinning. Babylon.js supports 8 bones of influence per vertex, and you have 12. This can produce unexpected results, but I don’t know if that would explain the timing issue. The other thing to look at is your animation frame rate. Maya defaults to 24 fps where Babylon.js is native at 60 fps. There is a conversion done, but converting from 24 to 60 is not straight forward and may throw off the timing of your animation. If you want to animate at a frame rate other than 60, I would suggest 30 as the conversion is much cleaner.

I would take the first steps of either reweighting or reskinning your mesh to have no more than 8 bone influences per vertex first to eliminate that warning. Then retime your animation in Maya if you are at any other frame rate than 30 or 60. Then export without optimize mesh checked. Make sure you don’t have any other warnings in your console window either when exporting, then we can take a look at the results and see what might be the next step.

@PatrickRyan thanks again. I did what youo suggest but It doesn’t seems to solve the problem.

test_blendshape_bee_02.zip (122.6 KB)

any other idea? :smiley:

I’ve tried to bake the animation of the blendshape on every frame before exporting to babylon. This workflow seems to give me the right result and keep the animation as I have in maya.

I don’t know if this is the right process to do it.

@gerald85, this was what I was worried about. We have some logic in the exporters to optimize animation curves but when a looping animation starts and ends on the same value, our optimization would assume that the value did not change and would optimize out the keys on that parameter. We tried to mitigate that by trying to curve fit and simplify keys, but that method does not always result in the right animation based on the initial curve.

For now, if you bake your keys, you will get the exact animation at the cost of a little more data in your glTF file. For short animations, this isn’t a huge tradeoff. We are looking for another option for animation optimization but that will take some time. For now, there’s no issue with baking your animation timeline other than file size. You won’t notice any performance issues and your animations will look exactly as authored.

We are also working on an animation curve editor for the next release, so this will also play a role in the animation optimization story. This is why I can’t say for sure when we may have a better optimization solution. But I hope this gets you unblocked for now.

Thanks for your help @PatrickRyan .As I told you, I will try to don’t use blendshape on the final rig, unless I really need it. :slight_smile:

1 Like