Store Curve Point Positions for later?

I need to store the Positions for a Curves Points for later use but no idea how to get it back? So if I create some Points with the same count I can position them to the stored info.

Hi espr3ss0,
either use the output from the Capture Attribute directly, as you already did with the White Noise, or use a Named Attribute node to access the stored values

It won’t work, either straight into the Points → Position or with Set Position. :frowning:

1 Like

Just read that you want to create new points - sry! In this case a Sample Index node with the old curve as the Source Geometry will do the trick

2 Likes

Thanks but doesn’t seem to work?

Although when I used Set Position with a slight offset now the Points have the right colors instead of just pink.

When I try without using the Named Attribute works fine.

That’s because you were storing on the wrong geometry (well, you don’t even need to store in this case).
You’re sampling from the curve onto points.
So if you still want to store Named Attribute to use on Points, you need to store it on Points.

2 Likes

Sorry not sure I follow?

Hmmm, I’m not sure how to phrase it better :thinking:

So you use Sample Index, which for every Index of Points looks up the same index from a Curve.
That’s enough to get the Positions - you can use them as is.

Now if you want to store these Positions, you need to do it on Points - plug Points into Geometry input of that node.
[Writing the attribute onto curve is pointless in this case, because then you’d need to sample it from curve (again)]

2 Likes

I see your point but I must be missing something, I’m still not able to get it back later.

Could you be a little bit more specific? What’s your goal here? What do you mean with “get it back later”? Why aren’t the solutions already provided to you not working?

2 Likes

In this case, it’s to pass to another GN Modifier. Otherwise, there would be no need to use Store Attribute.

OK, lets try it with an example…

Assume we have a BezierCurve object in our scene like so:

In a first Geometry Nodes setup we just want to create a bunch of points. These points should store the position of our original curves points. We can do this by sampling our original curves points with a Sample Index node and then store the value to our newly created points with a Store Named Attribute node:


Now, the point from our newly created points with the index 0 stores the position from the point #0 from our curve → index #1 from our new points stores the position from point #1 from our curve → index #2… and so on.
For the output of this modifier, we use our newly created points with the stored values. Note that we didn’t change the position of our new points yet. We just stored the values from our original curve to the points.

In a second Geometry Nodes modifier, we finally make use of the stored values. We can access these values using a Named Attribute node set to the same name as we used in the Store Named Attribute node in the first modifier:


You then have to simply plug the Attribute output into a Set Position node or do whatever you want to do with it → Thats it!

Does this make sense to you now?

2 Likes

Thanks, I’ve copied the images and that works fine but as soon as I break the connection flow of the Geometry it no longer works. In other words (the part with Named Attribute) if I don’t use the input geometry and create an entirely new set of Points using the stored data won’t work.

Yeah, because if you create another set of points, these points don’t have an attribute called “p” (in my example). You would then have to repeat the same steps as in the first modifier with the Sample Index node.

But honestly, i have absolutely no clue what you’re trying to do here…

2 Likes

I’m trying to store a Curve so I can use it later but that won’t be in the flow connected to the Geometry output.

Been really helpful so far. :slight_smile:

Maybe make a duplicate of the curve object and use that for sampling?

All the data is written/read on geometry. So you need to write on the Output Geometry of the first mod, to have access to later.

What geometry is going to be transferred between two modifiers? Where the curve comes from? Why does the tree have to be broken into two modifiers this way?

It would be much easier if you’d described exactly what your modifiers are supposed to do. There is always a possibility that there’s a misunderstanding in your approach to the modifier design.

1 Like

Doesn’t seem to do any different.

Have you even tried it? Why should this not work?


You can create as many modifiers as you want and still sample the curve at any point in the modifier stack.

If this is not what you want, then i’m out of ideas… post a .blend file and some screenshots of what you’re trying to do!

2 Likes

Sorry, I didn’t mean to upset anybody.

The sampling part is not the problem, as I keep mentioning. It’s the storing data part I’m trying to understand. It’s become very clear now that without the connection and data transfer, there is no way to store it independently due to it being stored on that geometry, etc.

So far I’m glad for the help. :slight_smile: