Reordering Geometry Indicies on Curve

Hi,

I’m working on creating a slab edge condition that uses multiple section profiles along the way. The ultimate goal is to sweep these profiles with the slab edge curve, but I’m running into a bit of a data structure issue. I placed the section profiles on every 3rd point, therefore there are 3 separate sections that ultimately need to come together. I used a merge to bring all these profiles back to one data tree, but the ordering isn’t in the way I desire.


As you can see, the order of the data is all the 1st type of section profile (red), then all the 2nd type (blue), and finally all the 3rd type (green) in order only relative to their original grouping. Is there a way to order all of these section profiles holistically following the curve?

Slab Edge Sweep.gh (17.9 KB)


Slab Edge Sweep_2024Jan12a.gh (17.3 KB)

2 Likes

Thank you!

Your base curve is not closed…

1 Like

the sweep wouldn’t work with a closed curve, so i left it intentionally open. but this is another great solution for it to be closed and wrap the entire slab, thanks!

Sorry, I was distracted earlier with cooking. I think this is better? Using Loft instead of Swp1, but also just better (simpler) code.


Slab Edge Sweep_2024Jan12b.gh (15.6 KB)

3 Likes

this works great too! i’m doing some additional manipulation to this so this is giving me a few different prelim workflows to work through if the backend fails! thanks again

Joseph, quick question for you. If I were to change the starting point where “0” essentially starts somewhere else on that curve, how would I go about doing that?

“quick questions” don’t always have quick answers!

I was about to say that moving the Seam is quick and easy but am surprised to learn that the curve is not closed :exclamation:

But assuming you can fix that, Seam is the best way to move start / end points of a closed curve.

P.S. Here is a fix:


Slab Edge Sweep_2024Jan16a.gh (18.8 KB)

NOTE: Swp1 works at some seam positions, it’s weird that way.

P.P.S. You can get the ‘t’ input for Seam by other means instead of the slider, such as Crv CP (Curve Closest Point) for example.

1 Like


I was also playing around with this, seems to be working okay too

Without code, I don’t know what that is?

turns out my method doesnt work. I haven’t had time to play around with your simplified code yet, perhaps that could change my methods success too
Slab Edge.gh (24.4 KB)

missing

Definitely not interested :exclamation: :cry:

no worries, that’s my fault. your previous methods will work great!



Something interesting is happening here, as you adjust where the seam point is. The profiles of the sections will just randomly rotate and change their orientation. I’m going to keep looking into this

I doubt that changes are random. Try this:


Slab Edge Sweep_2024Jan16b.gh (20.4 KB)

The PFrames were flipping 90 degrees depending on their positions. Added yellow group to align them with ‘Z’.

Hah :exclamation: :rofl:

1 Like

turned out to be everything but quick, thanks for your help!