Jump to content

Curve from two points and vectors


ydyd

Recommended Posts

Hi everyone!

I'm new to Houdini and I'm having an issue I can't solve. I thought it would be easy, but after researching, I can't find a solution and would appreciate very much any help!

I have two points, each one with a vector (transferring the normals for a surface in this case) and I want to connect them by a curve the follows those vectors. I guess this should be a Bezier curve.
The idea would be that if the length of the vectors increase or decrease, then the curve would be adjusted.

Hope I can get some help. Thank you!

Curve from points with normals.png

Link to comment
Share on other sites

Polybridge SOP has a similar function but it works for polygon faces/edge groups.

One way you could achieve this effect is to use Add SOP to create a line between the points, resampling the line, and then using an attribute at each endpoint to nudge the intermediate points towards the vector directions. Attribute Blur/Smooth may also be useful here.

curve_from_point_vectors.hiplc

Edited by Fenolis
Attached sample file.
  • Like 2
Link to comment
Share on other sites

Hi,

there is also a VEX function called "spline", which can evaluate bsplines (equivalent to cubic bezier). Once you have the attributes on the points (surface position/normal), you can build the curve from these attributes. The spline function is quite similar to the resample subdivision result. Another VEX function which is quite helpful here to get the attributes from the surface is xyzdist().

curve_between_surfaces.hipnc

  • Like 2
Link to comment
Share on other sites

  • 2 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...