Joe Hultgren - Technical Artist
  • Blog
  • Demo reel
  • About Me
  • Maya Scripts (bitbucket)

unicycle rig

4/26/2011

0 Comments

 
So I'm just gonna say this right now the finale of my film is pretty awesome, I mean it has a unicycle for pete's sake. Of course that means I would have to animate a unicycle. Screw that lets script it.

It's really not that hard once you get down to it. 
The first step for both direction and wheel rotation, get a vector of where you are now compared to where you just were. 

for wheel rotation take that vector and divide it by the radius of your wheel and you have the amount of rotation in radians, easy.

For direction use atan2 on the vector to get the rotation for the direction.  I also check to see if I'm moving backwards from where I was just and then offset the rotation so it doesn't just flip around.

one problem right now is to have auto/manual control I add the change in rotation for both the auto and manual controls to the the current rotation, which is going to cause problems for direction at least when I loop through the animation.

I'll need to add a hard manual mode where the rotations are directly linked to the manual controls.  Then I just have to start my animation in that mode so it resets every time it loops
0 Comments



Leave a Reply.

    Archives

    September 2017
    February 2017
    April 2016
    October 2013
    September 2013
    August 2013
    March 2012
    February 2012
    August 2011
    July 2011
    May 2011
    April 2011
    February 2011
    October 2010
    August 2010
    July 2010
    June 2010
    April 2010
    January 2010
    October 2009
    July 2009
    June 2009

    Categories

    All
    Art
    Blender
    Code
    Flash
    Free
    Maya
    Personal
    Pymel
    Python
    Rig
    School
    Siggraph
    Vancouver
    Vfs
    Website
    Work

    RSS Feed

    View my profile on LinkedIn
Powered by Create your own unique website with customizable templates.