Mandelbrot Canvas

This is a basic Mandelbrot plotter

preview black interior

Hmm, seems canvas isn't working for your browser...

I've given no thought to styling, tidying the code, or cross-browser compatibility, but it has a couple of nice features:
  • preview, allowing zooming in to interesting areas without waiting for whole thing to render
  • configurable iteration count, to allow compromise between speed and accuracy - but more importantly allowing the interesting areas to be found quickly and then recalculate at a higher iteration count as needed
  • ability to specify colour functions for the RGB components. All are functions of i, which is the integer number of iterations completed before bailing out (will be equal to MAX_ITER if within the set itself). The functions should return a value in the range 0-255
  • a position stack allowing unlimited 'back' operations