Dark Bit Factory & Gravity

GENERAL => Projects => Topic started by: Pixel_Outlaw on July 13, 2009

Title: Interesting Voronoi diagram...
Post by: Pixel_Outlaw on July 13, 2009

Well this is my first attempt at a Voronoi diagram. This is just a quick project to take a break from the C++ I've been doing as of late. Yes it takes forever, but then again I'm using the plot function rather than quicker pixmap operations.Time was not a concern here and this made for shorter code. Here I've assigned each point a color from a palette, then I only draw the pixel if  the distance away from the center is divisable by 12. This of course gives bands of color. Just a fun artsy take on the traditional shading methods.

(http://img530.imageshack.us/img530/3209/ver.png)


Sloppy source and .exe for Windows.
V
Title: Re: Interesting Voronoi diagram...
Post by: Shockwave on July 13, 2009
Thats a pretty psychedelic colour scheme, I always liked voronoi, this one looks quite different to those which I have seen before, and yeah, it takes a few seconds to render but it's worth it :)
Title: Re: Interesting Voronoi diagram...
Post by: Pixel_Outlaw on July 13, 2009


Thanks Shockwave, this would probably have a meta blobs effect if done in real time. Thanks for replying. :) I guess it is kind of like meta balls meets Voronoi diagram, one can see both.
Title: Re: Interesting Voronoi diagram...
Post by: Hezad on July 13, 2009
hum can't run it since I'm on Debian but it looks really cool

Thats a pretty psychedelic colour scheme, I always liked voronoi, this one looks quite different to those which I have seen before, and yeah, it takes a few seconds to render but it's worth it :)

+1 never saw this kind of voronoi diagram, cool :)
Title: Re: Interesting Voronoi diagram...
Post by: Jim on July 13, 2009
Nice graphic!  How about combining this effect with plasma?

Jim
Title: Re: Interesting Voronoi diagram...
Post by: hellfire on July 13, 2009
Quote
I only draw the pixel if  the distance away from the center is divisable by 12
You could also draw the other 11 circles in different colours and animate the whole thing using palette-rotation.
Title: Re: Interesting Voronoi diagram...
Post by: benny! on July 13, 2009
Nice one PO. Keep updates coming.
Title: Re: Interesting Voronoi diagram...
Post by: zawran on July 14, 2009
Looks very interesting. Perhaps if some precalculations were made it could be made to animate using a variable seed number? It would probably look really cool with movement.
Title: Re: Interesting Voronoi diagram...
Post by: Shockwave on July 14, 2009
Rotating the palette as Hellfire said will provide the fastest result, but here's an idea I had.

If you generate the voronoi pattern bigger than the screen and you shade or fill in the black areas between the lines you could apply a sine wave across the horizontal plane of the image, adding blended vertically sined lines accross the top of the image (this would help to disguise that it is just a sined and cycled picture), this would be a really good way of cheating an excellent psychedelic plasma pattern.
Title: Re: Interesting Voronoi diagram...
Post by: rdc on July 14, 2009
Looking at the source it appears that you are using RGB colors, so you could just apply a scaling factor to a particular color to push or pull it along the the color scale. You would have to apply the scale factor to each color component equally (or not) and clamp the values to 0 or 255, but you could create an interesting effect with little change to your source.
Title: Re: Interesting Voronoi diagram...
Post by: va!n on July 22, 2009
@Pixel_Outlaw:
Screenshot looks very interesting... nice work!