@RobA - wow. Thanks! I'm going to have to give that a go. You answered exactly what I wanted to know. (I'd love to know what a Voronoi pattern maker is)
@RobA - wow. Thanks! I'm going to have to give that a go. You answered exactly what I wanted to know. (I'd love to know what a Voronoi pattern maker is)
You should try some web pages on it as some people have written little java applets which allow you to drop points down and it draws the voronoi pattern out of them.
The Voronoi pattern is basically regions around points such that all the area in each region is the closest to the point it surrounds. So if you have just two points in space then the pattern is merely a line dividing the region in two midway between them perpendicular to a line joining the two points. As you drop more in then it fractures more into the triangles and polygons.
Natural examples of Voronoi patterns are created with bubbles so that looking down onto a dish of bubbles that are all packed together is a perfect pattern. The bubbles all try to form the least amount of surface tension. Since all the bubbles are made out of the same stuff then they pull on each other until it equalizes to that pattern which is optimal. When one bubble bursts then they all jiggle about and reform the new pattern.
There is an opposite space cutting pattern which is called the Delaunay pattern and it has lines which join up the dots. Actually all the shapes are triangles in this pattern. They use this algorithm to make 3D models from point clouds. You can use it in terrain models by specifying a few height points, stitching it all up with Delaunay and then it has triangles covering the area so it has a complete surface instead of just a few points. I.e. Its really useful !
RR-
I just read about a really cool way to create a Voronoi mesh using 3d graphic cards. center a 45 degree cone of the same hight as your image space on each point, giving each a colour.
Render it orthagonally from the top down with no shading.
Every separate colour will be a Voronoi cell, so running an edge detect alco with give you the mesh!
It is funny how it is can be faster to model a mathematical problem in a GPU rather than solving the math in the main processor!
-Rob A>
My tutorials: Using GIMP to Create an Artistic Regional Map ~ All My Tutorials
My GIMP Scripts: Rotating Brush ~ Gradient from Image ~ Mosaic Tile Helper ~ Random Density Map ~ Subterranean Map Prettier ~ Tapered Stroke Path ~ Random Rotate Floating Layer ~ Batch Image to Pattern ~ Better Seamless Tiles ~ Tile Shuffle ~ Scale Pattern ~ Grid of Guides ~ Fractalize path ~ Label Points
My Maps: Finished Maps ~ Challenge Entries ~ My Portfolio: www.cartocopia.com
Yeah thats a well known way of doing it and its true that can be super fast too. You don't have to use 45 deg cones - any cones will do as long as they are all the same angle and you can also grab the image data from the depth buffer instead of faffing with sorting out all the color too if your just after which was the closest region. I think that with the new cards you might be able to write a shader kind script to run on the card and process the result into the normal lines version. Is there an equally nifty way of doing that with Delaunay in 2D ? I haven't heard of anyone doing that and yet the two patterns are kind of transposes of each other.