PDA

View Full Version : constrain objects y value


morgn
05-18-2004, 03:49 PM
hi

http://www.seedanimation.com/cgtalk/ball.gif


I want to constrain the y value of the ball to the poly mesh landcape so that if i move it in x or z it can still move, but it follows the contours of the land.

ive tried shrink wrap, which does this, but flattens the ball. i also tried deform by surface, but this follows the contours of the mesh in all directions.

any help, greatly recieved!

cheers,

Morgn.

ThE_JacO
05-18-2004, 04:08 PM
get a triangle (curve or poly) and make a cluster out of all its points.
now constrain a Null to that cluster.
shrink wrap the triangle to the surface

this will make the object constrained to the cluster to always follow the average of all the points, in the case of a triangle this basically gives you a follow surface system with an approximation threshold of value:
threshold = radius of the circle the triangle is inscribed in.

make the sphere child of the null, constrain it, use expressions... whatever, the null can drive any parameter you want across the surface while you move the triangle.

there are other ways too, but this is pretty straightforward, doesn't require scripting and still gives a good degree of control.

morgn
05-18-2004, 05:47 PM
im hearing ya!
thanks v much

morgn.

CGTalk Moderation
01-18-2006, 06:00 AM
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.