.. Use of a Raycast node for "natural" randomization of the wire's path (?)

Hello.
I haven’t been able to find a solution for my latest project.
To put it simply, the goal was to have wires run along the slats of a fence like in the attached photos, or as close to that as possible and using a procedural approach with Geometry Nodes.

I got too caught up in my project and lost sight of those examples, ultimately making things unnecessarily complicated for myself: I started imagining the thread weaving back and forth between the blades—but inconsistently, sometimes “skipping” two or even wrapping all the way around a single blade—aiming for an extra layer of randomness. In the end, I gave up on that and just roughly routed a few threads by snapping vertices to the blades :frowning:
The tutorials I found pointed me toward using the “Raycast” node, sometimes combined with a “Switch” - promising leads, certainly, but I couldn’t quite achieve a satisfactory result, so I abandoned the idea.

  • Result achieved out of necessity, without geometry nodes :

  • Tested geometry node setup:

I’m no Geometry Nodes expert at all; honestly, I don’t even really know what all these nodes do anymore. This is simply the best I could manage. I’m amazed by people who navigate this stuff with ease—I wonder where they got their training (mathematics?).

  • Insufficient result :

Thanks for any information or help. Best regards.

P.S.: This is my first “thread” of this kind; I hope it meets the standard.

Final result :

Nice ! it works pretty well already. Someone made a very complete fence generator years ago on here, you should search for it. Maybe it can generate this, or something close.