Hexagonal pattern with gaps between tiles, and black/white gradient

Hi all,

I’m trying to create this hexagonal pattern below, but with spacing for grout between each of the mosaic tiles. I’m currently struggling to split the offsetted curves and create a surface boundery for each ‘tile’

pattern I want to achieve:

I’ve highlighted in blue the intersections out each curve:

I had a attempt, but the resulting split is organising the crvs in a strange way as the selection of each indices within the list is random. I’ve provided one exmaple below with green being correct while magenta is wrong and this is coming from a single index from one data tree:

script: Hexagonal_Tile.gh (15.9 KB)

I’m reluctant to jump into MCX because it’s complicated and this looks simpler than that, if each hexagon in the original grid is considered alone.

Is that grout spacing not shown in your first image? Is it the spaces defined by the 0.018 offset? Which is twice that value between the large hexagons?

Does the center of really need to be split into triangles or could that be a small hexagon? I guess the attractor effect is to be added later?

Phew :exploding_head:

I used (among other things) Surface Split to define one hexagon, then Orient to build the entire pattern.

Hexagonal_Tile_v2.gh (22.2 KB)

3 Likes

Hey,

Thanks you for taking the time to have a look, the result is impressive! is there a way to control the pattern through a attractor point at all? so you can, for example, control the graident patterns size and location from black to white?

Hey Joseph,

Yes, the grout spacing size is defined by the 0.018 slider. I divided the dimension by two in the script to get achieve the correct width. The first image was an example not produced in grasshopper, merely a reference.

I’d prefer to keep the smaller triangles in the centre, as the final result would look odd without the cuts. Correct, that was my original thought process with the coloured attractor effect being applied over the geometry.

Yes you could change the Plane Coordinates to a Distance from a reference point.

2 Likes

Hah! You really went for it, “attractor” effect and all. I studied your code (after I wrote mine) and see groups of groups, C#, bitmap patterns of 1s and 0s, some unnecessary bits. Impressive!

I should have waited for answers to my questions but plunged in anyway.


Hexagonal_Tile _2023Feb21a.gh (56.7 KB)

Odd, I looked away for a little while and my data tree structure appears to have changed… :crazy_face:


Ah, too late, I’ve just let the better part of three hours slip away fooling around with this. No more! Not now anyway.

2 Likes

I found a flaw in your code. Your C# bitmap widget is hard wired for only four divisions when the number is a parameter (slider). Easily fixed?

1 Like

Ha, this is probably the time I thought this was becoming a little too crazy and fast-forwarded to the end :man_facepalming:

Hexagonal_Tile_v2b.gh (20.5 KB)

1 Like

Can you clarify this please? “gradient pattern size”? Shades of gray as well as cull pattern?

1 Like

I was wondering if there is a way to reduce the radius size or ‘strength’ of the attractor point. At the moment there is a issue where as the grid size increases so does the pattern

My question is more about what effect the distance from attractor point has rather than its range? I see four different ring cull patterns in your reference image?

1 Like

If I’m understanding your question correctly, the method Magic did with the pattern is correct. So, you have 16 different iterations/steps going from complete white to complete black. Then you can control the size of the attractor radius and everything outside of the defined radius would be complete white.





sorry about the chopped up images, my current setup screen is tiny and this was the only to show. I hope that answered the question?

Here is another process with only 11 (4*(4+1)/2 +1) steps, which is more gradual visually.
The influence of the point is controlled with Graph Mapper.

Hexagonal_Tile_v2c.gh (24.9 KB)

Or using a curve as the attractor…

Hexagonal_Tile_v2d.gh (25.8 KB)

3 Likes

Hey Magic,

Thanks for the help it’s greatly appreciated! I did personally try the graph mapper with unsuccessful results, but after studying your script I see the error I made!

Yikes, I’m really slow today. Uses an MD Sider (white group) to choose the attractor point, a 'Range" slider (blue group) limits its effect. Wrote a Python bits thing to create the ring cull pattern. And just discovered a flaw when increasing the ring count slider!! :man_facepalming: Arrgh. :frowning: I’m going blind!

Uses an MD Sider (white group) to choose the attractor point, a 'Range" slider (blue group) limits its effect. Wrote a Python bits thing to create the ring cull pattern.

The slowest part by far is SrfSplit. @magicteddy saved a lot of time by creating only one set of hexagonal rings and then replicating it.


Hexagonal_Tile _2023Feb21b.gh (39.6 KB)

Make it stop! What a day, not what I had planned… :sob:

1 Like

And saved a lot of data tree complexity too! Nice work.

This thread title needs to be changed, it has nothing to do with curve intersections.

With the clarity of hindsight, inspiration from @magicteddy and curiosity about the effect of sorting cull patterns by area, I refactored my code.

Yesterday’s version ‘21b’ was an advanced exercise in managing data trees. This effort has a lot of flattening because all the ungrouped components at the top construct just one tiled hexagon. The gray group copies that to all the points in the HexGrid and the purple group sorts the cull patterns (once!) by the sum of areas of the un-culled (white) tiles.

Finally, the white group implements the attractor point and remaps its distance from each HexGrid point, used as a lookup index to the sorted cull patterns.

Results? Easier to understand and modify, faster and perhaps better cull patterns. Peace of mind.


Hexagonal_Tile _2023Feb22a.gh (33.5 KB)

2 Likes

After studying yours and Magic’s scripts, I’ve realised the pattern is far more complex and can’t be achieved without custom code. Is there a way to have more control over the pattern colours? I’m trying to mimic a 3-dimensional effect of the 2D tiles. In the zoomed-in image, they’re three differentiating shades of black and white separated by red, blue and green. Can this be achieved?

Black Pattern Logic:
image

White Pattern Logic:
image

I’ve also notice your pattern is slightly different transition when going from black and white, is there a way to make it more like magic’s logic?

Magics:

Josephs