I was exploring Grasshopper some more (particularly the voronoi component), and was wondering if anyone had any suggestions for how one might go about creating voronoi between two concentric circles, with the cells all touching each other. The way I was suggested to go about it using a rectangular bounds was with the 3D voronoi component, and taking a cross section of that. However, I know that the 3D voronoi component is bounded by a box, so I was wondering how it would be done for concentric circles. Thanks!!
Voronoi attractor for non-box boundary
You can compute the voronoi shapes and afterwards cut them against circular boundaries. Would that work for you?
So generate it within a rectangle, and then trim to fit within the circular bounds? I guess it probably could. The idea is to be able to use an attractor to cause certain areas to be composed of smaller pieces and other regions to be composed of larger pieces
You can distribute your points however you like. That’s step 1, the boundary cutting is step 2.
The region intersections are slow, but it works: voronoi custom boundary.gh (21.0 KB)
Thanks a lot!! I’ll mess around with it and see
So I recreated your definition on my own, and for some reason (even after I finally directly copied over each of your components), the definition fills the inner circle instead of the region between the two. Any idea why this could be? My definition should be identical to yours
Pottery Barn rule (“you break it, you own it”).
Why is your GH file 1 MB while David’s is only 21KB?
Because it has other definitions inside.
The file has a GHX extension so it is text XML, not binary compressed GH file.
@aaronsmolar GHX are just useful if you want to look inside or debug after acrash. Not very effective in term of size.
Yeah I heard about that on another thread I made. I already created this file, but next time, I will use .gh
You could also look at this thread, it is about copy about Julien Leonard work
Go to file > save as >.gh
Elementary my dear Watson, you took the wrong component, use Region Difference instead of Region Intersection
HAH I knew it was something stupid. Thanks so much!!
Sometimes it is tricky. Use the green button to follow the flow of the definition and to see the steps and see where is the problem.
Thanks a lot! So that will step through and show the results for each component? I’m pretty new to Grasshopper, so I didn’t even know that existed
So that will step through and show the results for each component?
No. It will only preview any components you select. @laurent_delrieu is telling you to turn it on then select components one by one up stream and see what each one does.
I think my problem is understanding what the graph mapping component usually does
It works like any graph does (you know the kind you learn in high school with one of these)
It takes your values and sets them along an axis. Where they hit the graph curve on the other axis is the value they are mapped to. In the case of the below image a value of .7 would become .35.