FORUMS: list search recent posts

Rotating/Orienting a Wheel on 2 axes

COW Forums : Adobe After Effects Expressions

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Mike Foran
Rotating/Orienting a Wheel on 2 axes
on Mar 23, 2013 at 2:33:56 pm

I am attempting to rotate a wheel from it center point anchor on the Z axis, while at the same time orienting it from a second anchor at center bottom. I am trying to be able to roll the wheel, but angle it out when it goes around sharp corners by changing the x orientation. The bottom of the wheel should not slide as it rotates.

I am having a tough time figuring it out. I have built a test comp (which you can see here: https://www.dropbox.com/s/7t4m3zgl63nmfvn/Rolling%203D%20Wheel.2.aep) in which I have my main wheel (blue) which I rotate on the Z axis from the center anchor. I have a controller wheel (red) that shifts it's anchor point so it can then orient on the x axis.

The problem, as demonstrated here, is that the main wheel, not sharing the same anchor point, looks like it is sliding away when the controller changes orientation. How can I keep the position of the blue wheel the same as the controller while it rotates and orients?


Return to posts index

Dan Ebberts
Re: Rotating/Orienting a Wheel on 2 axes
on Mar 23, 2013 at 6:49:43 pm

How about putting a null at the wheel's contact point, make it the parent of the wheel, and rotate it on its x axis to tilt the wheel out?

Dan



Return to posts index

Mike Foran
Re: Rotating/Orienting a Wheel on 2 axes
on Mar 23, 2013 at 8:03:36 pm

I had already discounted this because it felt like to blunt an solution, and it was breaking the other wheel rotation script you wrote in a previous post. But after some finessing this actually worked quite well. Thanks again.


Return to posts index


Mike Foran
Re: Rotating/Orienting a Wheel on 2 axes
on Mar 23, 2013 at 9:36:22 pm

Ugh. Well every solution poses new problems. All of the wheel questions I have been asking have been are so that I can create a controller for a wheel in Element 3D. So with Dan's help I now have a wheel controller that automatically rotates nicely along a path and can be oriented from it's base. Here's my test project: https://www.dropbox.com/s/0d3jtyll0bpxwpa/Rolling%203D%20Wheel.4.aep

If you turn off the Element layer (or if you don't have Element installed) You can see the control wheel(s) are working quite nicely. My problem arises when I try to orient the Element model to match the controller. As you can see it just starts wobbling all over the place when I start to mess with the orientation.

Can anyone figure why is this happening? This is really the last hurdle.


Return to posts index

Matt Tillman
Re: Rotating/Orienting a Wheel on 2 axes
on Mar 24, 2013 at 7:25:57 am

I think the wobbling has to do with the rotation order.

To get around it you need to use both the "Particle Replicator" Rotation as well as the "Particle Look" Rotation.

Particle Replicator Rotation
Y = thisComp.layer("Wheel_Orientation").transform.yRotation+90
Z = thisComp.layer("Wheel_Orientation").transform.orientation[2]+90

Particle Look Rotation
Y = thisComp.layer("Wheel_Rotation").transform.zRotation


Return to posts index

Mike Foran
Re: Rotating/Orienting a Wheel on 2 axes
on Mar 24, 2013 at 11:00:26 pm

Yes, that was it. Thanks so much! this really works and now I can really start animating.


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2018 CreativeCOW.net All Rights Reserved
[TOP]