A React application for calculating familiar Mandlebrot sets images.
The following images were created using the tool:
The images are generated in two phases:
- Iteration data calculation - a pool of web workers (threads) is constructed. Each worker calculates the iteration data for a given line of the final image at a time. The workers delegate to functions written in WebAssembly script and write their results to shared memory.
- Colourisation - a WebAssembly non-shared memory is constructed to back an ImageData object. The iteration data is copied into this memory and colourised by another WebAssembly based function. The ImageData object is rendered directly onto an HTML canvas.
This two phase implementation allows the re-colourisation of images without needing to regenerate them at the expense of approximately twice the memory overhead.
- The WebAssembly scripts that implement: the Mandlebrot calculations and, colourisation.
- Add some other fractals: Newton, ....
- Cursor keys for movement (ditch the inputs?).
- Implementing BigInts in WASM for 'infinite' scrolling?
- Optimised rendering using the simply connected property of the Mandlebrot set.
- More interesting colourisation methods.
- Improve the UI:
- Maybe full screen (scrollable) image with floating controls (if we keep them at all)?
- Free hosting.
- User-friendly image saving (with details on the extents maybe).
- Publish the WebAssembly script modules as proper dependencies.
- Handle (resource construction) errors conditions properly
- In CanvasHelper.canvasCursorLocation, why do we need to use the min and floor function?
See Version History
The Unlicense