Trap Pattern*

Preview
Performance Cost 🟡 Medium
Space 2D UV Space
Implementation Native Compiled C++
Devices (Cycles) CPU / GPU (1:1)

At its core, an orbit trap is an elegant coloring strategy originally developed for fractal rendering. The concept is beautifully simple yet remarkably expressive: as you iterate a function, each point traces out a path—an “orbit”—through mathematical space. Instead of simply checking whether this orbit escapes to infinity (as in traditional fractal rendering), we place geometric “traps” at strategic locations and measure how close the orbit gets to these shapes.

The implementation is based on research from “Orbit Trap Rendering Methods for Generating Artistic Images with Crystallographic Symmetries” by Lu et al., which combines chaotic functions with crystallographic symmetry groups to create patterns with mathematical precision and artistic appeal.

Usage & Behavior

Default Crystalline
Smooth It Enabled
High Trap Radius
High Complexity (Seed Var)

This node is a specialized "Art Generator." Unlike for example standard noise which creates random clouds, Trap Pattern creates Structure. It works by tiling 4-fold rotational symmetries (P4 Group). The visual style is heavily influenced by the Trap Radius (which controls the thickness of the shapes) and the Seeds (which randomize the mathematical constants used in the transformation).

Trap Pattern (Crystallographic Orbit Trap) generates intricate crystalline patterns by combining P4 planar symmetry groups with orbit trap rendering techniques. Based on research into the procedural generation of artistic patterns (2022), it simulates a mathematical system where points are iteratively transformed and "trapped" by geometric shapes. This results in complex, kaleidoscope-like mosaics, stained glass effects, and fractal tilings that are computationally efficient yet visually dense.

Best Used For: Stained glass, abstract mosaics, crystallized surfaces, alien tech panels (!), ornate floor tiles, and psychedelic visuals.

Key Features

  • P4 Symmetry: Applies wallpaper group transformations for perfect 4-fold tiling.
  • Orbit Trap Logic: Captures iterating points to generate color regions.
  • Granular Randomization: 5 separate seeds for Color, Position, Radius, and Pattern.

Deep Dive: What is an Orbit Trap?

Imagine dropping a marble into a kaleidoscope. The marble bounces around, changing position based on mathematical rules (Symmetry). Scattered inside this space are "Traps" (invisible circles).

  • The Iteration: The point's position is updated repeatedly using Fourier basis harmonics (cos/sin).
  • The Trap: If the point falls inside a trap circle, we stop tracking it.
  • The Color: The pixel is colored based on how far the point was from the center of the trap when it got caught.

This technique maps log-space distances to exponential color interpolation, creating the smooth yet sharp gradients typical of fractal art.

Parameters

Smooth It (bool, default: true)
Toggles between hard-edged, distinct geometric segments (False) and smooth, blended gradients (True). Use "False" for a mosaic/tile look, and "True" for a liquid/glass look.
Coords Vector
The input texture coordinates.
Scale Vector (default: 12.0, 12.0, 12.0)
Controls the density of the crystalline grid.
Trap Radius Min / Max (default: 2.0 / 5.0)
Defines the size range of the "Traps."
- Larger values: Create thicker, more dominant shapes that fill the space.
- Smaller values: Create thin, wire-like structures and voids.
Parameter Scale (default: 1.0)
Scales the internal coefficients of the symmetry function. Adjusting this changes the "tightness" or curvature of the pattern.

Randomization Seeds

This node offers granular control over randomness. Change these seeds to vary specific aspects of the pattern without changing the overall structure.
Global Seed (default: 0.0)
The master randomizer. Changing this completely reshuffles the entire pattern.
When set to anything else than 0 (default) .. Color, Radius, Position and Pattern will not have any effect.
Pattern / Radius / Position Seed
Fine-tuning seeds.
- Pattern: Changes the symmetry/shape logic.
- Radius: Changes the size distribution of the shapes.
- Position: Shifts the center points of the traps.
Color Seed (default: 1.0)
Randomizes the color mapping logic (if using internal coloring).

Quick Recipes

Geometric starting points.

Stained Glass

  • Smooth It False
  • Trap Radius High
  • Scale 8.0
Large, hard-edged shapes create distinct colored regions like glass panes.

Wireframe Crystal

  • Smooth It True
  • Trap Radius Min 0.5
  • Trap Radius Max 1.0
Very small trap radii result in thin, glowing lines resembling a crystal lattice.

Psychedelic Rug

  • Global Seed (Animate)
  • Scale 20.0
  • Param Scale 2.0
High density and animated seeds create a morphing, detailed tapestry.
Technical Note: Based on "Procedural Generation of Artistic Patterns Using a Modified Orbit Trap Method" (2022). The implementation is GPU-optimized to be compute-bound rather than memory-bound, making it ~10x faster than traditional table-lookup approaches by calculating color mapping on the fly.
↑ Back to Top

Leave a Reply