Troubles With Breathing Animation, Assistance Requested

Hey all, hope all is going well!

I’m having another issue here where I’m attempting to make a breathing animation, but keep hitting all kinds of walls. A bit of Background: I’m using Rigify along with a model from MakeHuman, using the first patch version of Unity 5.3.5, and using Blender 2.77a.

The first thing I tried was simply scaling the chest widget in Blender a bit to get a simple breathing animation, which didn’t work because Unity discarded all my scale information concerning that.
I then tried a custom chest bone, which works, except it’s not highly realistic. So I wanted to get the shoulders involved.
So I tried something straight-forward enough: I animated the chest bone as needed in Blender, and then animated the shoulders, putting those into their own action. No luck, the shoulders move now, but not the chest, and any attempts to make a chest animation in Unity to combine with that just results in a mess.
Then I decided to try the other way around: have an animated chest in Blender, then animate the shoulders in Unity. Still no luck, it appears you can’t animate those particular bones within Unity due to something about being a humanoid rig.
The last thing I tried was to set up a semi-complicated constraint system so that when the chest bone moves out in Blender, the shoulders move up a bit.
Foiled again, though, the shoulders animated, but the chest remained inactive.

So I’m at a loss, essentially. While I want a more realistic breathing animation, this is just getting beyond ridiculous.
I’m hoping that someone in this community can maybe help out a bit with how I should go about doing this sort of thing as I’m completely out of ideas myself.

Thanks, and take care!

EDIT: I’ve also tried animating the shoulders via script, but apparently I can’t get anything smooth and working at the same time.

If you want a more realistic breathing animation - you are going to have to choose either going with the generic rig, allowing for more realistic breathing animation with added bones, but not being able to retarget animations from other rigs, OR conforming to the humanoid rig and not having as realistic breathing animation.
There is a 3rd option - humanoid rig with transform masked bones - but if you were familiar with that technique you would already be using is it.

For better breathing animations - add 2 bones to the character rig to mimic the upper chest/rib cage in the upper outer pectoral area.
2662674--187771--upload_2016-6-3_11-36-9.jpg
Then setup the character as generic in Unity.

If you HAVE to use humanoid rig - use this same rigging - but you will need to create transform masks for the added breathing bones, and setup the animations slightly different in the state machine.

3 Likes

Hey theANMATOR2b, thanks so much for the reply!

Mm, unfortunately I was hoping to use the retargeting capabilities of the humanoid setting. In the project I’m working on, we’re going to have a fair amount of human figures, each using roughly the same animations, so it would be easiest (as far as I know) to have one animation file for all those figures.
It looks like that third option might be best, and concerning that, do you mean the transform section of an avatar mask? I am familiar with it, but I suppose you could say I don’t know its full potential just yet, so if you could maybe explain a bit how I would do that, I would appreciate it. =-)

EDIT: Ok, I messed around a bit and got something working, at least to some degree. What I’ve done is ensure in the imported animation that the chest bone used for the breathing is checked under the mask settings. Then I made two masks, one for idles, one for breathing, using the transforms as a mask instead of the other type. After assigning these to the two layers, one for idles and one for breathing (made to be additive,) it looks like it might be working. But I am curious if this is the proper way of going about doing such a thing. I’ll also be rigging up my character as you suggested shortly, but wanted to test things a bit in Unity first.

1 Like

Each character is different - but this sounds right, like the same workflow I used. My (tests) experience only went up to getting 2 extra tail bones to animate and retarget successfully with using humanoid setup.

Before proceeding you may want to test this setup and animation on another character to make certain it retargets like you want it to.
Unfortunately - this is where my tests (experience) has stopped - atm.

I’ll definitely be sure to do that. Thanks for all the help, and take care! =-)

1 Like