Fractal Generator

Use the form below to generate a fractal. Warning though, this is computationally intensive. If you try and generate a large image, it will take longer to process and your browser may become unresponsive. If you let it sit, it should eventually finish, or you may have to force-close your browser... :/ I made this to play around with using web assembly.


WASM Loading... Please wait... Ensure Javascript is enabled...

If you like the generated image, click here or right-click and select save to keep it. Pro tip, you can select a region of the image by clicking and dragging. Then it will zoom into that region and re-render.

xpx

This controls the size of the image drawn in pixels. You can start with small images until you generate an image you like, then increase the resolution using this field. Updating this field will auto-update the "Complex Size" field to maintain the aspect ratio. Otherwise, your image would look stretched.

+i

This is the start of where we draw from the complex plane. The top left part of the image will be mapped to the complex plane at this location. Changing this will move the fractal within your generated image. If your image is off-center, this is the field to alter to fix it.

+i

This is how far we travel the complex plane from the start position. You can think of this like the zoom level. Smaller numbers here will zoom into the fractal. You can click and drag within your generated image to automatically change this easier.


This is how many recursive operations we perform to get the value of a point on the complex plane. Or put another way, how long we spend calculating the color of a pixel in your image. Lower numbers give more bloby results, where higher numbers will give finer details to the fractal. Higher numbers will also impact performance when generating though. In general, you will need to increase this as you zoom into a region of the fractal.

+i

When generating a Julia fractal, this is the C value used in the recursive calculation. This does nothing for Mandelbrot fractals. Changing this will change the shape of the Julia fractal.




Generate a Mandelbrot or a Julia fractal. These are different but related ways to generate a fractal. The same mathematical formula will have drastically different visual results based on this. Mandelbrot will recursively calculate Z*Z+Z where Julia fractals recursively generate Z*Z+C. Where Z is the location in the complex plane and C is a constant value provided above.













These are various functions supported by this tool. The fractal function defines the overall shape of the fractal that is generated.


If this is selected, colors will gradient both based on colors selected below, and the fractal value. This is always used if only 1 color is selected. If this is off and you have multiple colors below, the image will be generated with sharp edges between the colors and the colors themselves will be saturated.

Below here, you can set the colors used in the generated image. The percent relates to how fast a specific pixel drift to infinity. This is in a range of 0-1, and relates to where the color is used in the image. In practice, the higher the percentage specified, the closer toward the fractal shape the color will appear. Low percents will show outward from the fractal shape.

  • Percent, Red, Green, Blue, Swash, Remove

Finally here you can set the color of the fractal shape itself. This is the color used where the value never drifts to infinity within the defined iteration count. This is in Red Green Blue values, 0-255. Pure black or white tend to produce the most interesting images.