Having trouble implementing the shrinkwrap modifier in geometry nodes?

Hello guys. So I have recreated the shrinkwrap modifier in geometry nodes and everything works. (here is my node setup)


The only thing I’m stuck on now is how do I implement the “Offset” input parameter from the original shrinkwrap modifier…

2 Likes

You can achieve this by displacing the surface of the target object geometry:


custom_shrinkwrap_offset.blend (199.7 KB)

Edit: this is not the same, though, as first applying the shrinkwrap modifier and then displacing the wrapped geometry along the normals. I think you would have to use Blender 3.0’s features for this (Attribute transfer or something).

As they have included geometry nodes fields now, this is the way to go anyway (fields rock!).

You said, “this is not the same, though”. But would the order actually matter? Shouldn’t displacing the target obj geometry and then shrinkwrapping to the target obj be the same result as shrinkwrapping to the target obj and then displacing?

I haven’t tested it, but I believe the problem lies in the " find the closest point in the target mesh" operation. If you change the target mesh, the closest point may be somewhere different depending on the offset value.

Oh yeah, your right.

Also, I’m very interested in converting to fields. I thought about it before but I’m actually making the jump right now.
Would you happen to know what should be used in place of the “Attribute Proximity” node since it’s not there anymore? I can’t seem to find something similar.

Yeah, I couldn’t figure it either and deactivated fields again.

This is how it works however (apparently, they updated how normals are calculated):

The right objects show the other method: displacing the target geometry.

nodes_3alpha_shrinkwrap.blend (217.6 KB)

seems they now added proximity to fields:

https://developer.blender.org/rB9f0a3a99ab664b

1 Like