animation_nodes icon indicating copy to clipboard operation
animation_nodes copied to clipboard

Proposal: Hexagonal Distribution

Open Gerstmann-Bradley opened this issue 3 years ago • 7 comments

There's a reference from Sverchok "Polygon Grid" node. I'm not sure how far we need this. because its' a much more complex node in reality. Another thing is that I think both vertices of hexagon or Centers of a hexagon are important information that's needed. Current workaround is to Replicate "Circle Mesh" Node so we may potentially get vertices and centers of a hexagon, but it's difficult to make it mathematically correct. Considering the fact we may need both vertices and centers of a hexagon as output. I think we need to make a separate node besides distribution matrices node? What do you think? image image

Gerstmann-Bradley avatar Apr 27 '21 11:04 Gerstmann-Bradley

So a Hexagonal Grid Mesh node?

OmarEmaraDev avatar Apr 27 '21 11:04 OmarEmaraDev

So a Hexagonal Grid Mesh node?

Yes, I think that's acceptable.

Gerstmann-Bradley avatar Apr 27 '21 11:04 Gerstmann-Bradley

@OmarEmaraDev and @Gerstmann-Bradley

I built a setup for this a while ago and think I got the math right based on some algorithm I found online. You can check it out here, maybe it helps:

https://p7s1-my.sharepoint.com/:f:/g/personal/par0001d_belgium_fhm_de/Eq0yQVSYfZNHrVcE-YQ6pTIBZ_zEucGlNTBfCD39bn1zBw?e=iO5ozS

It would be cool, if this can be implemented natively. Thank you

dapa5900 avatar May 03 '21 14:05 dapa5900

@dapa5900 Seems to be similar to @harisreedhar's implementation in #1707. I want to merge a more general implementation though as I described there.

OmarEmaraDev avatar May 03 '21 14:05 OmarEmaraDev

@OmarEmaraDev I have a patch for Hexagon distribution in Distribute Matrix node. Do you think it worth adding to master?

https://user-images.githubusercontent.com/46858047/117156708-98ec5400-addb-11eb-80f1-d99c97fdf59c.mp4

harisreedhar avatar May 05 '21 14:05 harisreedhar

@harisreedhar Sure.

OmarEmaraDev avatar May 05 '21 15:05 OmarEmaraDev

I consulted this reference when programming my music visualization software. It is a very helpful, exciting and interactive reference for understanding and programming hexagonal grids. I strongly recommend it.

lgmventura avatar Oct 20 '22 21:10 lgmventura