Procedural Visual Systems in Unreal

Procedural Visual Systems Preview

Procedural Visual Systems is a modular Unreal Engine 5 playground for turning abstract algorithms into real-time, interactive simulations. Each system is built to be both technically precise and visually striking β€” using instanced meshes, glowing materials, and animation-driven logic. No plugins, no shortcuts β€” just raw C++ and runtime math, rendered live.

  • Ulam Spiral: Prime numbers mapped to grid spirals with growing instanced cubes.
  • Poisson Sampling: Evenly spaced spawns across a plane with no overlaps.
  • DLA Clustering: Walkers aggregate into branching crystal-like shapes.
  • Circle Packing: Space-filling, growing circles using real-time collision detection.
Systems & Classes
  • APrimeSpiralActor: Ulam Spiral logic with `IsPrime()` and position mapping
  • APoissonSpawner: Samples candidates and enforces spacing
  • ADLAClusterActor: Random walkers that aggregate via neighborhood checks
  • ACirclePackingManager: Collision-checked growth of animated mesh circles
Use Cases
  • πŸ”’ Ulam puzzles or encoding index-based logic
  • 🌲 Forests, NPC camps, and smart loot zones
  • 🧬 Crystal growth, infection spreading, or coral visuals
  • πŸ—ΊοΈ Spawn zones, abstract UIs, and dynamic territory visuals
Features
  • 🧠 Math-driven procedural logic
  • ⚑ Real-time execution with optimized instancing
  • 🌈 Glowing, scaling, animated feedback
  • πŸ” Modular β€” drop-in ready for any level
Challenges and Solutions
  • Challenge: Making abstract math visually engaging.
    Solution: Used glow, scale, and color-driven feedback to reflect algorithm state.
  • Challenge: Keeping performance high with real-time updates.
    Solution: Built systems using instancing and modular architecture.

Project Achievements
  • Created four distinct procedural systems visualized in real-time.
  • Used in internal tooling and prototyping workflows.
  • Provided clean base classes for student/intern onboarding.

Demo Logic Snippet

Sample logic for Ulam Spiral positioning:


FIntPoint GetUlamSpiralPosition(int32 Index)
{
    int32 x = 0, y = 0, dx = 0, dy = -1;
    for (int32 i = 0; i < Index; ++i)
    {
        if (x == y || (x < 0 && x == -y) || (x > 0 && x == 1 - y))
            FMath::Swap(dx, dy *= -1);
        x += dx; y += dy;
    }
    return FIntPoint(x, y);
}

This project explores real-time procedural generation using Unreal Engine 5. Each system is built with C++ and Blueprint, using instanced meshes and simulation-based logic. It's an experimental toolset designed to bridge beautiful math with practical level design.


Release Date july 22, 2025
Category Procedural Generation, Gameplay
Connect with me
Khaled Zakaria β€’ Game Developer β€’ Unreal engine Programmer β€’ Instructor β€’ Game Programmer β€’