Search - User list
Full Version: pinning and averaging curve points
Root » Houdini Indie and Apprentice » pinning and averaging curve points
etudenc
Hello! I'm hoping someone will nudge me in the right direction on this little challenge I've set for myself.

In a nutshell, I want to set up a NURBS curve such that if I move either end point of the curve, each interior point will maintain a position that's the average of its neighboring points' positions (so point 4 would always be positioned between point 3 and point 5, point 3 would stay between point 2 and point 4, etc.).

I've set this up in Maya using expressions but am wondering how to do it in Houdini using operators. FWIW, I'd rather not use a spring if possible as I'd rather do it with a little math.

Also, what do I have to do to make a point on the curve follow something like a null or a sphere?

Any pointers would be appreciated!
Phil
etudenc
No one has any suggestions on how to do this?
john_z
Hi,

do you need to move interior points or is the line always straight ?
etudenc
john_z
Hi,

do you need to move interior points or is the line always straight ?

Hi John. The interior points would be moved because I want their positions to be an average of their neighboring points' positions. This would result in the line always being straight, though.

Hope that makes it clearer!
Thanks!
Phil
john_z
something like this ?
etudenc
Brilliant! That's exactly what I was after! I appreciate your putting it together, very helpful and instructive. Seems so much easier/cleaner to do than all the expressions I had to write in Maya.

Cheers!
Phil
edward
To do that, you need connectivity information. So I would just create a VOP SOP network and use the Get Neighbours (and friends) VOPs to help with this.
etudenc
edward
To do that, you need connectivity information. So I would just create a VOP SOP network and use the Get Neighbours (and friends) VOPs to help with this.
Thanks Edward, I'll look into that as well - I've been focusing on trying to get a handle on SOPs but sounds like I need to move VOPs up on my list!
etudenc
john_z
something like this ?
Hey John, hate to bother you but any ideas on how I'd connect the end point of the curve to a specific point on a circle rather than a sphere? I tried isolating the curve point by making it into a group but this doesn't produce very good results. Hope you won't mind my asking!
john_z
Hi,

you could use the Carve Sop to extract a point on a nurbs circle
based on a parametric coordinate.

Take a look at the Misc tab of the circle object in the attached file.

Happy to help if I can
etudenc
john_z
Hi,

you could use the Carve Sop to extract a point on a nurbs circle
based on a parametric coordinate.
Great idea, I wouldn't have thought of that!
Thank you again, John!
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Powered by DjangoBB