Variable Curve Offset By Mesh Steepness

I want to offset these mesh section curves and offset them more in areas of the mesh that have a gentle slope and less in areas where the mesh is steep.

I’ve tried doing this by using the Z component of the Mesh Closest Point to 100 points around each curve to effect the Distance parameter in a Variable Offset.

It didn’t work!

Mesh and curves internalised

Any ideas?

OffsetCrvMeshSteepness.gh (2.0 MB)

hi @martynjhogg maybe this helps?

OffsetCrvMeshSteepness.gh (1.9 MB)

also, when selecting your normals, you weren’t using the vectors of the mesh faces per closest point:

1 Like

Looks great! I will check it out properly later. Thank you! @René_Corella

no problem!

NOTE:
I realized you were using the plug-ins, I re-connected your original stuff: riched graph mapper to offset variable - notice that offset variable is tricky - sometimes you need to break the curve into as many segments as the amount of values you’re feeding the offset variable, which then produces a chain of regions you might be able to unify with ‘region union’ command later (sometimes it doesn’t work and you have to change the number of segments until it does):

updated file:
OffsetCrvMeshSteepness.gh (2.0 MB)

1 Like

Nice! Thanks again!
The application, BTW, is stacking layers of material to then CNC a surface. I need more overlap of layers in flatter areas so I leave plenty of material when I CNC the surface. A constant offset of the layer profiles leaves less material in areas where the surface slope is not steep.