algorithmic modeling for Rhino
In this post Daniel Piker describes how to do custom iteration in Kangaroo with scripting. My C# skills aren't great, and after researching how to translate his scripts to Python, I decided it wouldn't be worth the effort. What I really wanted was a way to do the same thing without scripting.
After two days of experimenting, I finally got some results! I was able to recreate Piker's "growing line" script at the above post by putting the Kangaroo Solver inside an Anemone loop. During each iteration the underlying geometry changes, which is something I'd never seen before in a Kangaroo/gh script without writing code. To make it work, the trick is to attach a Boolean list with [True, False] to the Kangaroo Solver's "Reset" input, while keeping the "On" input set to True. That way at each iteration the solver resets itself and starts again with the new geometry provided by that iteration. Then you have to extract only the output from the second iteration to feed back to Anemone.
The only code I wrote was about 7 lines of Python to split line segments that get too long. That could have been done with only Grasshopper components, but doing it in Python was just too easy.
Tags:
I used your growingDisk file with a torus input and a few adjustments using cocoon pluging, turned out kind of like a brain with hemispheres. I'm Really looking forward to using kangaroo and anemone.
Welcome to
Grasshopper
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
© 2024 Created by Scott Davidson. Powered by