Search Unity

Animation legs (Mecanim) + Movement arms (Kinect)

Discussion in 'Animation' started by Ferox, Sep 16, 2013.

  1. Ferox

    Ferox

    Joined:
    Apr 3, 2013
    Posts:
    8
    Hi guys,I'm working in a project where I have to controll the movement of the legs and of the avatar with a joystick, and i want to use Mecanim for the animations. And to move the arms, hands, etc i have to use kinect.

    So my question is, how i can specify to the Animator that i want only the animations of legs and feet. I saw there is something similar with Masks, but are when i work with 2 layers. In this case i use only one layer to control legs, and then with a script i control arms and hands with kinect.

    Someone can help me?

    thankssss
     
  2. Ferox

    Ferox

    Joined:
    Apr 3, 2013
    Posts:
    8
    None can help me????
     
  3. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,694
    Try configuring your avatar so that only the lower body bones are assigned. I haven't tested it exactly in your case, but I do a similar thing for my lip sync. By default, the jaw bone gets assigned to the avatar. I set the avatar's jaw to none so my facial animation system can control the jaw bone.
     
  4. Dicsolovag

    Dicsolovag

    Joined:
    Jan 13, 2014
    Posts:
    1
    I managed to create a scene like you want.
    I describe the process for you, or anyone who will face this problem in the future.

    I get a rigged character and set rig to "Humanoid".
    After that i added the free "raw mocap package" from the store. And installed the kinect package too.

    I had to create a new animation controller. It has one base layer and i put the needed animation on it and made it loop.
    After this just simply add a "animator" to the character, and set the created animation controller.

    This is how you can create a animation.
    For the kinect control there is an example in the package.

    If you want to move the upper body with kinect and animate the legs, you have to add a kinect character controller v2 to the character and a animator too.

    Place the kinect character controller v2 on top the animator. The order matters! Set the kinect character controllers "mask" field to "Upper_body" and check the animated checkbox.

    You can have further settings on the animation with more detailed animation controller or skeleton masks.

    I hope it helps.

    Tom
     
  5. Gazowen

    Gazowen

    Joined:
    Oct 15, 2014
    Posts:
    4
    Where is the mask option? Is it from an old asset. I can't see it?
     
  6. Gazowen

    Gazowen

    Joined:
    Oct 15, 2014
    Posts:
    4
    I found it but have never managed to get the Kinect wrapper working, I always have a error.
     
  7. Gazowen

    Gazowen

    Joined:
    Oct 15, 2014
    Posts:
    4
    Hi I have looked at the model controller and wondered exactly how it worked? What are the numbers?

    None = 0x0,
    Hip_Center = 0x1,
    Spine = 0x2,
    Shoulder_Center = 0x4,
    Head = 0x8,

    Im trying to recreate this but I am not using the assets, as I am already using a different assets. How would i recreate this in my own script? I'm not sure what the numbers represent.
    thanks
     
  8. Baldolin

    Baldolin

    Joined:
    Feb 27, 2013
    Posts:
    3
    Which Kinect package are you guys using? I don't see the mask option in mine?