A GPU Approach to Voronoi Diagrams
nullprogram.com
nullprogram.com
More interesting articles about voronoi diagrams, for those who are interested.
Is this true? I was recently playing around with a webgl Mandelbrot [1] and the core algorithm escapes with a break. I wrote it without thinking and it worked on my computer and the computers of the people to whom I showed it. Was this just luck that it works?
This is the usual way in which thread divergence is dealt with in GPU land.
http://blog.alexbeutel.com/332/interactive-voronoi-diagrams-...
That's when it hit me! Render each seed as cone pointed towards the camera in an orthographic projection, coloring each cone according to the seed's color. The Voronoi diagram would work itself out automatically in the depth buffer. That is, rather than do all this distance comparison in the shader, let OpenGL do its normal job of figuring out the scene geometry.