Blog

Portfolio CV

Flash fractals

Published:
2009-09-13 17:11:41
Posted from:
Home
Tags:
Fractals, GLSL, Pixel Bender,

Today I've been playing with fractals after being inspired by a couple of posts by Nick Porcino on various procedural stuff. Despite being a computer graphics geek I've never before implemented a classical fractal renderer. But I've discovered that it's quite fun and very easy to create some amazing images.

I wrote a GLSL based program that lets you explore the Julia sets associated with the Mandelbrot set. I really liked the interactivity so I wanted to publish it here. But first, I ported it to Flash Player using Pixel Bender (view source enabled source here):

Pixel Bender shaders are quite fast, but since they doesn't support recursive calls (neither does GLSL, AFAIK) or loops (at least when exported to Flash Player) you're a bit limited in the complexity of shaders you can create. I had to unwind my loops and put a hard limit on 20 iterations using 20 if-statements in a row. This also caused a huge performance hit until I nested the statements in groups of five.

If I have the energy I'll look into orbit trapping next. Orbit trapping is a technique for mapping textures to a fractal space, resulting in images such as this one (by Tom Beddard):

Comments

No comments so far. You leave the first:

Name
Email
Website
Text

© 2008 Markus Johnsson