driving rotation problem

Become a member of the CGSociety

Connect, Share, and Learn with our Large Growing CG Art Community. It's Free!

THREAD CLOSED
 
Thread Tools Search this Thread Display Modes
Old 06 June 2013   #1
driving rotation problem

A and B are bones in 2 separate hierarchies.
B rotation values are nonzero(and must remain thus).
I need control the rotation of obj A from obj B in the following way:

A rotation follows B rotation
A is also still inherits everything from its on hierarchy.

orient constraining A to B fails, because A loses its hierarchy orientation, becoming completely slaved to B

I tried param wiring B to A, which got me close,
But B is not at a zero value to start, so A is forced into the initial orientation of B.
I need A to stay put when the connection is made.

would a scripted rotation controller solve this problem?
 
Old 06 June 2013   #2
you can use rotation list controllers for both A and B nodes. list controllers has to have two subcontrollers: Initial and Zero. if you wire (or use the same instance) Zero controllers you will get what you want

here is a sample

delete objects
b0 = box name:"parent" width:1 length:1 height:5 wirecolor:red
b1 = box name:"source" width:1 length:1 height:3 parent:b0 wirecolor:orange position:[0,0,5]
b1[#transform][#rotation].value = eulerangles 0 40 0

b2 = box name:"target" width:1 length:1 height:3 wirecolor:green pos:[10,0,0]

c1 = b1.rotation.controller = Rotation_List()
c1.available.controller = Bezier_Rotation()

c2 = b2.rotation.controller = Rotation_List()
c2.available.controller = Bezier_Rotation()
c2.setactive 2

paramWire.connect c2[2] c1[2] "Smooth_Rotation"

Last edited by denisT : 06 June 2013 at 05:44 PM.
 
Old 06 June 2013   #3
Thnak Dennis.
your scritp works as advertised

In my case, I was stuck with an object B that had a rotation.controller[2]=Euler_xyz. that I can't change (too many downstream things dependent)

I was able to use my first attempt -param wiring the X_rotation, y_rotation, and z_rotation, and adjusting for the offset of A in the "Froze Rotation" controller.

Last edited by Mambo4 : 06 June 2013 at 10:01 PM.
 
Old 06 June 2013   #4
Thread automatically closed

This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
 
Thread Closed share thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
CGSociety
Society of Digital Artists
www.cgsociety.org

Powered by vBulletin
Copyright 2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump
Miscellaneous

All times are GMT. The time now is 12:50 PM.


Powered by vBulletin
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.