0
$\begingroup$

I have a mesh that I want to bend along the curve, then move all vertices to match its Z position. Here's the process:

  1. Mesh in X length of the curve
  2. Bend the mesh to curve on XY plane
  3. Align mesh's Z positions to the curve, using the X position from step 1 for curve length sampling. Process And there's a problem - the mesh is not properly aligned with curve, depending on the angle it's too low or too high. I assume I have to correct the X length input for sampling, but I have no idea how to do this.

Edit: the blend with the case: https://blend-exchange.com/b/Pav9wL2L

$\endgroup$
12
  • $\begingroup$ I need to bend an existing mesh $\endgroup$ Commented Jun 29, 2022 at 14:20
  • $\begingroup$ However, the mesh you show here can be easily constructed with Geometry Nodes. Or is it actually a more complex mesh? $\endgroup$
    – quellenform
    Commented Jun 29, 2022 at 14:22
  • $\begingroup$ It's complex mesh - I want to bend any input mesh possible, so I can't generate it from curve $\endgroup$ Commented Jun 29, 2022 at 14:23
  • 1
    $\begingroup$ I don't understand the part about "bend Z positions". Can you explain this a bit more? $\endgroup$
    – quellenform
    Commented Jun 29, 2022 at 16:27
  • 1
    $\begingroup$ @quellenform it's a 'Z Up' deformation I think.. One route: capture curve Z, flatten curve, deform mesh to flat curve, offset by captured Z. You or me? $\endgroup$
    – Robin Betts
    Commented Jun 29, 2022 at 16:47

1 Answer 1

1
$\begingroup$

I hope this is what you're after.. it's just an adaptation of the X Curve Deform group from here, which you say you are using, changing the mapping in the curve's coordinates.

  • X to the position on the curve
  • Y to the cross-product of the curve tangent with (0,0,1), flat to XY, at right-angles to the tangent
  • Z to (0,0,1)

The new arrangement is shown below:

enter image description here

The result:

enter image description here

It would be simpler to adjust the tilt to make the curve 'Z Up'.. figuring that one out, unless @quellenform gets there first :)

You could take this futher in the mesh, by, for example, flattening the tops of the turrets to XY

$\endgroup$
4
  • $\begingroup$ Well, @RobinBetts, you have taken the cake once again ;-) $\endgroup$
    – quellenform
    Commented Jun 29, 2022 at 18:24
  • 1
    $\begingroup$ @quellenform Unless I can figure it, I'll post the 'Z-up' Q as one of my own.. just an invitation to have think about it :D $\endgroup$
    – Robin Betts
    Commented Jun 29, 2022 at 19:00
  • 1
    $\begingroup$ It works well on the spiral, but on other curves it's getting misaligned image $\endgroup$ Commented Jun 29, 2022 at 19:05
  • $\begingroup$ @UserNoRandomNumber See Edit $\endgroup$
    – Robin Betts
    Commented Jun 29, 2022 at 21:13

You must log in to answer this question.

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