0
$\begingroup$

I believe I have a unique scenario in which I need to capture a control point. I have looked at other solutions and have found them to be different from my problem and need help.

Any help would be much appreciated.

The overview

I have a collection of 4 splines that have identical control points. This collection is called "Spline Set". enter image description hereenter image description here

I have a separate Single GN object to merge those 4 splines. The Outcome of the GN group is to be able morph between each spline in a linear fashion similar to shapekeys.You can use the value input in the GN modifier group to change the target from . it has a range form 0 to 1 enter image description here

Overall I am creating a wave . I will be duplicating the GN spline group a bunch of times and I will be using a particular control point (the red one in the above picture) to instance a curve line across the splines that will become a control for a foam simulation enter image description here

My problem The current GN group resamples the original curves in order to morph them. I loose the control point information. I don't know how to capture in particular the "red" control points of all the original splines and be able to use that information to instance an object on that location as the wave transforms.

I am asking for help only with reinstating the position of the control point . I can work on instancing a loft over the splines later.

Desired outcome To have an instanced cube copying the original positions of the combined red control point of the 4 splines in the "spline set" collection, applied on the resampled GN spline. see image below enter image description here

I have a blend file available If anyone can provide help it would be amazing

$\endgroup$
5
  • $\begingroup$ and how to you wanna set/mark the control point? does it has always the same index? and is the green line that, what you wanna have? $\endgroup$
    – Chris
    Jan 12 at 20:38
  • $\begingroup$ thankyou Chris. I have amended my question you can find the updated information you requested under "Desired outcome" $\endgroup$
    – ben
    Jan 12 at 20:54
  • $\begingroup$ happy to donate if you can provide a viable solution $\endgroup$
    – ben
    Jan 12 at 21:04
  • $\begingroup$ Could you confirm that the "red" control point has the same index for all four splines ? Using an "Instance on Points" node with a selection based on the "Spline Parameter" Index, I succeed to capture the displacement of the CP with index=3, but for splines "E.A" and "F.A" it seems far too offset to the right. As I am using version 3.6.5, I am wandering if it could be an issue importing your version 4 file... $\endgroup$ Jan 14 at 16:23
  • $\begingroup$ I also have to switch off the GeometryNodes modifier on spline "A.A", otherwise there were 5 splines, those with index 0 and 1 being the same. $\endgroup$ Jan 14 at 16:28

3 Answers 3

0
$\begingroup$

There are a couple of techniques that might be considered to be that control point on your new curve. You're basically interpolating between two curves; we could find the location of the control point on each curve, and then interpolate its new position. But this new position isn't necessarily even on your new curve. (And, I'm not sure if your original curves have a consistent ordering for this index-- hard to tell with all the shapekeys.) Or, we could find the distance along the curve of each control point, interpolate between those two distances, and measure this distance on your new curve.

But it seems to me that what you're actually after here is the sharpest point of your wave, and there's no guarantee that either of those methods will give it to you. If what you want is the sharpest point, then rather than getting the position of some interpolated control point, let's just get the place where the tangent changes the most:

enter image description here

Just plugged into the end of your existing nodes. This could even be a different GN modifier. I check each control's tangent against the tangent of the next point (except for the final control); where those two have the sharpest angle, I draw a point.

Note: this doesn't work for a flat line, but I don't think you're interested in this point for a flat line.

$\endgroup$
0
$\begingroup$

(Using Blender 3.6.5)

Results:
Animation

Geometry nodes Graph:
GN Graph The fourth control point (i.e. with Index=3) of each spline in the collection is captured through an Instance on Points node. These instances have the same index as the original splines, so the mixing factor is the same also. The positions bracketing the current Value are recovered by Sample Index nodes, after a Realize Instances node.

Remarks:

  • From the original Blender file, splines E.A and F.A were edited to reposition the fourth control point.
  • From the original Blender file, all scaling factors were reset to 1 to limit interference with GN.
  • As judiciously written by Nathan, interpolation between two resampled curves does not yield the same curve as interpolation between splines control points, because the curves length is different. As a consequence, the captured control point could be a bit off the interpolated curve. Splitting splines in two partitions at this fourth point before resampling and interpolation could be a way to improve this.

Resources:

$\endgroup$
0
$\begingroup$

A user by the name of SOZAP on blender artists has a technique that I have used. It yeilds great results by first capturing the desired index value of each curve with this node setup on each curve. enter image description here

Then using a seperate GN group it creates a merged result of all curves aswell as capturing and blending between each captured index value.

enter image description here Here is a file

$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .