Adding Randomised Cabling in Grasshopper

So, unfortunately I am a very button-clicky person, and I am also very reliant on the command line in Rhino.

I am not wanting someone to solve the problem for me as such, but I have never really used Grasshopper (used a bit of Nautilus and Pufferfish, then ran away), so I feel rather dumb about it.

Anyway, I often find myself wanting to connect cables between items. I don’t always want to do it in a “proper” way (maintain constant lengths, ribbon cables, whatever). However it would be nice if they were:

  • Not self-intersecting
  • Have randomisation control (straightness, entanglement, smoothness)
  • One can spread the ends across two arbitrary end surfaces at a perpendicular, so they have a controllable “clustering”.
  • Maintain perpendicularity at the ends.
  • Maintain thier curves (or end points) to be baked, so I can also use the curve ends as points to place N termination blocks or other junctions.

Below is the embarassingly slow method I am using for my cables. I take normal curves on a pair of surfaces and make short perpendicular curves to theseurfaces, and then just flow them by hand around objects using interstitial segments.

Sometimes I try and work around it by using Record History in a hideous way to make my first cable and junctions, and then see if I can drag the bits around and hope the History changes the pipe for me.

Having a look around, I came across this Blender Geometry node tutourial:

I would think that Grasshopper could provide me with the functionality I want to have (I’d imagine somewhat even more superior and controllable to the Blender GN approach), but I wonder if anyone here thinks that this is a reasonable expectation. I’m happy to go and try learn myself, if it takes me some weeks. It isn’t important in the sense that I only do these things for aesthetic rendering quality, and my Line-Line-BlendCrv routine seems very lacklustre.

Really, one would take two surfaces, with N randomly scattered short perpendicular lines, 1:1, and then do something like join all arbitray pairs, but with parameterisations that permit the nice Blender Geometry Node behaviours shown in the video.

Thank you for any advice.

I think I will start by seeing if the Blender implementation can be reproduced in some sense. It seems reasonably logical.

I am quite sure Kangaroo could help here and if you don’t want too much physics it could be doable to make a tool using Rtree or function like that to avoid collision.
I began something with bands like Jordane Saget (I have some collisions due to rotation of bands)

Thanks for the information. That topic looks very useful, and a good starting point for me. I’ll return when I make progress.

Regards.