Imonobor Posted July 27, 2022 Share Posted July 27, 2022 Hello! I have this grid of dots that I want to expand, so they take up all the white space between them, while not colliding into eachother (which means they won't be circles anymore, but weird hexagon-ish shapes, depending on how many neighbors they have, except the outermost circles that would still be circles on the outside, albeit bigger ones). Kinda similar to what Substance Painter does with unused parts of the texture, so there are no seams around the edges, but in vector. Basically divide the white space to the objects evenly, while keeping them separate objects, so I can color them differently and make a mosaic. Does anyone know what this "technique" is called so I can search it better or know a way to achieve it in Designer? Thanks in advance! Quote Link to comment Share on other sites More sharing options...
GarryP Posted July 27, 2022 Share Posted July 27, 2022 I would be pleasantly surprised if you can do this with the Affinity applications. It’s the “while not colliding into each other” part which is the most difficult bit, meaning that the software will need to do geometrical calculations on each shape, taking the geometries of the surrounding shapes into consideration, and modify each shape accordingly. This may be possible with a combination of functionalities, probably with rasterisation (not vector), but I’m fairly sure that it can’t be done without a lot of manual effort. Imonobor 1 Quote Link to comment Share on other sites More sharing options...
Imonobor Posted July 27, 2022 Author Share Posted July 27, 2022 @GarryP Well, it doesn't have to be calculated in such a caveman way. It could be an algorithm that calculates where the "seams" between these objects (or even just the centerpoints of the objects, they don't have to be seen as circles, just points) are and split a larger circle shape by these seams. I just don't know if such an algorithm exists or is possible to do in the program. Quote Link to comment Share on other sites More sharing options...
GarryP Posted July 27, 2022 Share Posted July 27, 2022 I’m not quite sure what you mean by “caveman way” but, if I have understood your requirements correctly, lots of very specific complex vector calculations will need to be made and I don’t think the Affinity software can do what you want it to do. (I’d be happy to learn otherwise.) There may be other software out there that will do it but I don’t know what you could search for to find it. Imonobor 1 Quote Link to comment Share on other sites More sharing options...
NotMyFault Posted July 27, 2022 Share Posted July 27, 2022 Maybe this pattern? Only bitmap, may use an tracing app to vectorize. Recipe: add Gaussian blur, radius px size of circles as starting point add Gaussian blur, set blend mode to difference, 0.1px radius Add levels adjustment, set white level to about 1% add threshold adjustment, adjust to taste circle pattern.afphoto Quote Mac mini M1 A2348 | Windows 10 - AMD Ryzen 9 5900x - 32 GB RAM - Nvidia GTX 1080 LG34WK950U-W, calibrated to DCI-P3 with LG Calibration Studio / Spider 5 iPad Air Gen 5 (2022) A2589 Special interest into procedural texture filter, edit alpha channel, RGB/16 and RGB/32 color formats, stacking, finding root causes for misbehaving files, finding creative solutions for unsolvable tasks, finding bugs in Apps. Link to comment Share on other sites More sharing options...
NotMyFault Posted July 27, 2022 Share Posted July 27, 2022 Honest question: how did you create the circle pattern? Can you share the .afphoto file? Quote Mac mini M1 A2348 | Windows 10 - AMD Ryzen 9 5900x - 32 GB RAM - Nvidia GTX 1080 LG34WK950U-W, calibrated to DCI-P3 with LG Calibration Studio / Spider 5 iPad Air Gen 5 (2022) A2589 Special interest into procedural texture filter, edit alpha channel, RGB/16 and RGB/32 color formats, stacking, finding root causes for misbehaving files, finding creative solutions for unsolvable tasks, finding bugs in Apps. Link to comment Share on other sites More sharing options...
Staff MEB Posted July 27, 2022 Staff Share Posted July 27, 2022 Hi @Imonobor, No, there's no way to do this in Affinity dinamically. Actually as far as I'm aware no 2d illustration vector software is able to do what you want. You have more chances to find this type of function on a 3d based software then on a vector based illustration app. You can however draw an hexagonal grid from scratch in Designer and eventually use a custom grid to help you snap the hexagons in place as you see fit. Imonobor 1 Quote A Guide to Learning Affinity Software Link to comment Share on other sites More sharing options...
Imonobor Posted July 27, 2022 Author Share Posted July 27, 2022 @NotMyFault Sorry, I need it to be this precise pattern. I did it mostly with geometry and maths - made a line of dots, spaced them evenly and started duplicating and rotating some of them, ended up with this. I've attached the file if you want it. @MEB Thanks for the answer, I'll look into doing this kind of thing in blender. Is it possible to import the vertex "vectors" from planes in blender back to curves in Affinity Designer? Also, the thing I'm trying to do is called Voronoi Diagram apparently - https://en.wikipedia.org/wiki/Voronoi_diagram Circle.afdesign Quote Link to comment Share on other sites More sharing options...
Pšenda Posted July 27, 2022 Share Posted July 27, 2022 22 minutes ago, Imonobor said: Also, the thing I'm trying to do is called Voronoi Diagram apparently https://affinity.help/photo/English.lproj/pages/Filters/filter_voronoi.html Quote Affinity Store (MSI/EXE): Affinity Suite (ADe, APh, APu) 2.4.0.2301 Dell OptiPlex 7060, i5-8500 3.00 GHz, 16 GB, Intel UHD Graphics 630, Dell P2417H 1920 x 1080, Windows 11 Pro, Version 23H2, Build 22631.3155. Dell Latitude E5570, i5-6440HQ 2.60 GHz, 8 GB, Intel HD Graphics 530, 1920 x 1080, Windows 11 Pro, Version 23H2, Build 22631.3155. Intel NUC5PGYH, Pentium N3700 2.40 GHz, 8 GB, Intel HD Graphics, EIZO EV2456 1920 x 1200, Windows 10 Pro, Version 21H1, Build 19043.2130. Link to comment Share on other sites More sharing options...
Imonobor Posted July 27, 2022 Author Share Posted July 27, 2022 34 minutes ago, Pšenda said: https://affinity.help/photo/English.lproj/pages/Filters/filter_voronoi.html Sadly, that's just a filter that generates cells at random, not a real Voronoi generator. This is how it's supposed to be generated, from points, not a raster image: Quote Link to comment Share on other sites More sharing options...
Old Bruce Posted July 27, 2022 Share Posted July 27, 2022 9 hours ago, Imonobor said: Does anyone know what this "technique" is called so I can search it better or know a way to achieve it in Designer? I think what you are after is a packing problem. My math/geometry skills have atrophied to the point of uselessness. The centre dot would be a hexagon because of the six surrounding dots. The six would be ... this is where I fail, there are ten dots outside ... so maybe pentagons for the six dots or 3 + 4 or 3 + 2? I just can't recall how to do this. Each larger radius would be composed of polygons which fit side by side for the circles and inner radius and outer radius number of sides would need to fit with the number of dots in those circles. I think it is easy once you understand the packing. Imonobor 1 Quote Mac Pro (Late 2013) Mac OS 12.7.4 Affinity Designer 2.4.1 | Affinity Photo 2.4.1 | Affinity Publisher 2.4.1 | Beta versions as they appear. I have never mastered color management, period, so I cannot help with that. Link to comment Share on other sites More sharing options...
Alfred Posted July 27, 2022 Share Posted July 27, 2022 (edited) 2 hours ago, Old Bruce said: I think what you are after is a packing problem. My math/geometry skills have atrophied to the point of uselessness. The centre dot would be a hexagon because of the six surrounding dots. The six would be ... this is where I fail, there are ten dots outside ... so maybe pentagons for the six dots or 3 + 4 or 3 + 2? I just can't recall how to do this. Why would you switch from hexagons to pentagons, instead of using hexagons throughout (like bees do for their honeycombs)? One hexagon is surrounded by a ring of six hexagons, a ring of six is surrounded by a ring of twelve, and so one on. Edited July 27, 2022 by Alfred Corrected typo. Imonobor 1 Quote Alfred Affinity Designer/Photo/Publisher 2 for Windows • Windows 10 Home/Pro Affinity Designer/Photo/Publisher 2 for iPad • iPadOS 17.4.1 (iPad 7th gen) Link to comment Share on other sites More sharing options...
Imonobor Posted July 27, 2022 Author Share Posted July 27, 2022 I found a couple of videos and scripts that generate real Voronoi patterns from points, but they are all for Adobe Illustrator. Guess I'll use that then. @Old Bruce @Alfred The pattern I have is not "regular" at all - the points are placed seemingly randomly (athough I did follow certain mathematical calculations), so the end result won't have any regular hexagons or pentagons, besides the central one. I'll post it here once (and if I'm able to) I make it. But doing this manually is just not something a sane person would try to do. Alfred 1 Quote Link to comment Share on other sites More sharing options...
Old Bruce Posted July 27, 2022 Share Posted July 27, 2022 17 minutes ago, Alfred said: Why would you switch from hexagons to pentagons, instead of using hexagons throughout (like bees do for their honeycombs)? One hexagon is surrounded by a ring of six hexagons, a ring of six is surrounded by a ring of twelve, and so one. Because of the drawing in the first post, centre, then a ring of six then a ring of 10. Quote Mac Pro (Late 2013) Mac OS 12.7.4 Affinity Designer 2.4.1 | Affinity Photo 2.4.1 | Affinity Publisher 2.4.1 | Beta versions as they appear. I have never mastered color management, period, so I cannot help with that. Link to comment Share on other sites More sharing options...
Pšenda Posted July 27, 2022 Share Posted July 27, 2022 26 minutes ago, Old Bruce said: Because of the drawing in the first post, centre, then a ring of six then a ring of 10. ??? I see 12 of them! Alfred 1 Quote Affinity Store (MSI/EXE): Affinity Suite (ADe, APh, APu) 2.4.0.2301 Dell OptiPlex 7060, i5-8500 3.00 GHz, 16 GB, Intel UHD Graphics 630, Dell P2417H 1920 x 1080, Windows 11 Pro, Version 23H2, Build 22631.3155. Dell Latitude E5570, i5-6440HQ 2.60 GHz, 8 GB, Intel HD Graphics 530, 1920 x 1080, Windows 11 Pro, Version 23H2, Build 22631.3155. Intel NUC5PGYH, Pentium N3700 2.40 GHz, 8 GB, Intel HD Graphics, EIZO EV2456 1920 x 1200, Windows 10 Pro, Version 21H1, Build 19043.2130. Link to comment Share on other sites More sharing options...
Old Bruce Posted July 27, 2022 Share Posted July 27, 2022 24 minutes ago, Pšenda said: ??? I see 12 of them! Right. I was wrong. But we cannot have a series of dots in circles that match a Hexagonal grid. Distance across the flats versus across the points. This is tiling the plain or packing problem. Quote Mac Pro (Late 2013) Mac OS 12.7.4 Affinity Designer 2.4.1 | Affinity Photo 2.4.1 | Affinity Publisher 2.4.1 | Beta versions as they appear. I have never mastered color management, period, so I cannot help with that. Link to comment Share on other sites More sharing options...
v_kyr Posted July 27, 2022 Share Posted July 27, 2022 14 hours ago, Imonobor said: Does anyone know what this "technique" is called so I can search it better or know a way to achieve it in Designer? I think it's called Circle Packing ! Circle packing theorem See related: Circular Packing Basic Circle Packing Chart Packing circles in a circle Position N circles of different radii inside a larger circle without overlapping Circle Packing Using Stochastic Search circlepacking (GitHub) ... etc. Controlled circle packing with Python Quote ☛ Affinity Designer 1.10.8 ◆ Affinity Photo 1.10.8 ◆ Affinity Publisher 1.10.8 ◆ OSX El Capitan ☛ Affinity V2.3 apps ◆ MacOS Sonoma 14.2 ◆ iPad OS 17.2 Link to comment Share on other sites More sharing options...
Imonobor Posted July 28, 2022 Author Share Posted July 28, 2022 Okay of all the places, I found a perfectly-working Voronoi Diagram Generator that was built into Inkscape. Open source software never ceases to amaze me. This is exactly the result I was looking for. Thanks for all the input everyone! Renderluz and MEB 2 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.