Nodes/DJZ-Nodes/Fractal Art Generator V2
ComfyUI Node

Fractal Art Generator V2

Actual Mandelbrot in ComfyUI, now in color

By MushroomFleet·Created 2 years ago·Updated 5 months ago· 78
Fractal Art Generator V2
    • IMAGE
    width1024
    height1024
    max_iterations500
    presetClassic Mandelbrot
    zoom_level1.0
    color_presetClassic White-Grey
    power2.0
    escape_radius2.0
    color_cycles1.0
    smooth_coloringtrue
    x_center-0.7500
    y_center0.0000

    You don't need a diffusion model to make trippy art - a Mandelbrot set at 1024×1024 is already gorgeous, and it renders in seconds instead of minutes. FractalGeneratorV2 is DJZ-Nodes' escape-time fractal renderer with real color control bolted on. If you've ever wanted fractal backgrounds, textures, or just a hallucination-ready source image to feed into img2img or a ControlNet pipeline, this is the node. V2's whole reason to exist over V1 is the color system.

    How it works

    It's a genuine escape-time fractal renderer, iterating a complex function per pixel (z = z^p + c and friends) until it escapes a radius, then coloring by iteration count. Under the hood it's numpy vectorized across the whole grid, so even 4K renders are fast - the escape iterations dominate the cost, which is what max_iterations (50-2000, default 500) controls. Higher iterations reveal deeper detail but cost time.

    Presets: Classic Mandelbrot, Julia Set, Burning Ship, Tricorn, Newton, and Custom. The Newton fractal is a genuinely different beast - it colors by which cube root of unity each pixel converges to, giving those smooth colored basins, and the source handles it with special-cased code. The other four share the same iterate-and-escape pipeline with different equations.

    The inputs that matter

    • preset - the fractal family. Start with Classic Mandelbrot.
    • zoom_level - how deep you are. Combined with x_center / y_center (optional, default -0.75, 0.0 - the classic spot), this is how you explore. Bump zoom to 5+ and drift the centers by tiny amounts to get those infinite-detail regions.
    • color_preset - the V2 headline feature: eight palettes (Classic White-Grey, Electric Blue, Fire, Rainbow, Deep Space, Ocean, Forest, Psychedelic).
    • power (2-5) - the exponent in z^p + c. Higher powers warp the set into those multi-lobed shapes.
    • escape_radius (1-10) - when a point "bails out." Default 2 is standard; lower it for denser, muddier interiors.
    • color_cycles - how many times the palette wraps across the iteration range. 0.1 gives long smooth gradients, 5+ gives tight psychedelic banding.
    • smooth_coloring - smooths the iteration counts so you get gradients instead of hard contour bands. Leave it on.
    • width / height - up to 4096. Output is an IMAGE tensor ready to wire anywhere.

    Installing

    Part of DJZ-Nodes (Drift Johnson / MushroomFleet):

    cd ComfyUI/custom_nodes
    git clone https://github.com/MushroomFleet/DJZ-Nodes
    cd DJZ-Nodes
    pip install -r requirements.txt
    

    Or "DJZ-Nodes" in ComfyUI Manager. Needs numpy and PIL, both in the pack's requirements.

    Tips

    The fun combo nobody mentions: render a FractalGeneratorV2 image and pipe it into an img2img pass - the fractal's edge detail gives the sampler a ton to work with, and you get fractal-organic hybrids. For video, batch it by varying the seed of a downstream noise node rather than re-rendering. And the Newton preset at low max_iterations is the fastest way to a smooth abstract piece; the Mandelbrot wants more iterations to shine. If all you need is a grey-scale fractal, V1 (without the color controls) is the leaner pick.

    CategoryDJZ-Nodes

    Inputs (12)

    NameTypeDefaultDescription
    widthINT102464–4096
    heightINT102464–4096
    max_iterationsINT50050–2000
    presetCOMBOClassic Mandelbrot6 options: Custom, Classic Mandelbrot, Julia Set, Burning Ship, Tricorn, Newton
    zoom_levelFLOAT1.00.1–100
    color_presetCOMBOClassic White-Grey8 options: Classic White-Grey, Electric Blue, Fire, Rainbow, Deep Space, Ocean, +2
    powerFLOAT2.02–5
    escape_radiusFLOAT2.01–10
    color_cyclesFLOAT1.00.1–10
    smooth_coloringBOOLEANtrue
    x_centeroptFLOAT-0.7500-2–2
    y_centeroptFLOAT0.0000-2–2

    Outputs (1)

    NameTypeDescription
    IMAGEIMAGE