init:
Runs once for a pixel. Set the initial orbit value and any helper variables here.
Learn FractalPark's tested FRM subset, understand how source becomes a GPU shader, and build three working formulas from the same examples used by the editor.
FRM is a compact, text-based way to describe an iterative fractal. A formula names its starting state, the calculation repeated for each orbit, and the condition that decides whether iteration continues.
The format grew out of the Fractint ecosystem, where formula files made it possible to exchange experiments without rebuilding the rendering program. FractalPark carries that authoring idea into a browser workflow while documenting its own tested subset instead of claiming complete compatibility.
For the wider project's origins and history, see the Fractint project site.
FractalPark tokenizes, parses, validates, and compiles a deliberate FRM subset. The table separates constructs that work directly, constructs with documented FractalPark semantics, and constructs the current workflow cannot preserve.
| Level | Meaning | Verified scope |
|---|---|---|
| Supported | Covered by compiler tests and usable without a semantic qualification. |
|
| Adapted | Accepted with a documented semantic difference or as a FractalPark extension. |
|
| Unsupported | Not preserved by the current compiler or file workflow; rejected rather than silently rewritten. |
|
This is a tested compatibility baseline, not a claim of full Fractint compatibility. When the compiler changes, this matrix and its tests must change together.
These capability counts come from the versioned manifest: 588 target entries comprise 579 strict-v2 passes and 9 documented waivers; 117 separate entries are excluded with stable reasons.
Parameters: p1, p2, p3, p4, p5 · Function slots: fn1, fn2, fn3, fn4
Capability manifest v1 · strict semantics v2
A FractalPark FRM formula has one named declaration and three explicit sections. Together they define the state transition for every pixel.
Runs once for a pixel. Set the initial orbit value and any helper variables here.
Runs once per iteration. Update z and any state that the next iteration needs.
Returns the condition for continuing the orbit. When it becomes false, the point has escaped.
The section names are structural, not comments: omitting or misspelling one produces a diagnostic.
The language stays intentionally small: expressions describe complex arithmetic, statements update orbit state, and control flow selects among updates.
FractalPark does not paste FRM text into a shader. It passes source through a staged compiler so syntax, meaning, generated code, and diagnostics stay connected.
The exact text from the editor, paste, or local file is the authoritative input.
The lexer recognizes names, numbers, operators, section markers, comments, and directives while retaining source locations.
The parser builds a structured formula tree and reports malformed declarations, expressions, and control-flow blocks.
The validator checks names, types, sections, and supported semantics before a canonical formula is created.
Code generation emits shader functions and records mappings from generated GLSL back to FRM source.
A successful compile becomes the same formula-plugin contract used by the renderer and shader assembly system.
The shared compiler contract keeps Explore, the standalone Editor, saved custom formulas, examples, and tests on one implementation path.
These examples advance from the smallest quadratic formula to parameters and stateful feedback. Each source block is taken directly from the shared example registry and compiled during tests.
Lesson 1
The smallest escape-time formula, useful for learning the init / loop / bailout structure first.
Focus: the declaration and the init / loop / bailout structure. Change the exponent or escape threshold only after this version compiles.
StarterBrot {
init:
z = 0
loop:
z = z^2 + c
bailout:
|z| < 4
}Lesson 2
Demonstrates p1 / p2 parameter slots and the difference between cabs and |z|.
Focus: p1 and p2 parameter slots, a complex literal, and cabs(z) as an explicit magnitude function.
ParameterDrift {
init:
z = 0
loop:
z = z^2 + c + p1 * 0.15 + p2 * (0.05, -0.02)
bailout:
cabs(z) < 8
}Lesson 3
Uses zPrev as feedback memory and pairs well with orbitEcho coloring for orbit envelopes.
Focus: zPrev as the previous orbit state. Feedback adds memory without introducing a second manually managed state variable.
OrbitEcho {
init:
z = pixel
loop:
z = sqr(z) + zPrev * (0.30, -0.12) + pixel * (0.85, 0.0)
bailout:
|z| < 48
}The FRM Editor opens these same compile-checked examples by stable ID. Formula source stays in the current tab until you save it to your cloud library, and is never embedded in the URL.
Compilation stops at the earliest unsafe stage and reports source-oriented messages. A rejected construct is never rewritten into something that merely looks similar.
Unexpected characters and unsupported identifiers are reported with their line and column.
Malformed sections, expressions, or control-flow blocks are diagnosed before semantic validation.
Unknown variables, invalid assignments, type mismatches, and unsupported semantics prevent code generation.
Generated GLSL retains mappings that can point a shader compilation failure back to the originating FRM location.
When fixing an error, start with the first reported message: later diagnostics can be consequences of the same missing token or invalid expression.
A formula you write is private until you choose otherwise. There are three ways it can travel — each explicit, none silent.
Private by default
Formulas live in your cloud library, visible only to you. Artworks you save carry a copy of the formula source inside the draft, so they always open the way you left them.
Download the .frm file
Your formula is plain text. Download it from My Formulas any time and keep your own copy — no export request, no waiting.
Publish an artwork, share the source
Publishing an artwork that uses your formula makes the formula source public under the MIT License: anyone may read, copy, and build on it. The community page shows the formula name from its metadata and offers the source as a download. This cannot be undone for that publication.
The full MIT License text lives at opensource.org.
Open Explore to compare built-in formula behavior, coloring, transforms, animation, and export controls before writing a custom formula.
Open ExploreUse the dedicated FRM Editor to compile, preview, import, and download formulas; sign in to save one to your cloud library before handing it off to Explore.
Historical context and implementation details are linked separately so the guide can distinguish the Fractint lineage from FractalPark's current compiler contract.