3D Fractal volume shader preset
3D Fractal is the heaviest built-in preset. Instead of sampling a soft fog field, it evaluates an iterative fractal kernel while marching a ray through the scene, then estimates a normal for lighting when the ray hits the surface.
This preset is useful for separating stronger desktop GPUs from entry devices because the inner fractal loop multiplies the cost of each ray step. It is closer to a stress test than a beginner tutorial, so use lower resolution or shorter runs on phones and integrated GPUs.
Performance factors
Nested iterations
Every ray step can run several fractal iterations, multiplying shader ALU cost.
Normal estimation
Surface lighting samples the field around the hit point, adding extra kernel evaluations.
Long runs
Sustained use can reveal thermal throttling on compact laptops and phones.
Editable parameters
MAXITER
Higher values add fractal detail and sharply increase shader cost.
Ray step distance
Smaller steps improve hit precision but require more loop iterations.
Lighting samples
Normal estimation improves shape readability but adds extra field evaluations.
Best fit
- High-end desktop and laptop GPU checks
- Shader ALU stress testing
- Understanding why fractal ray marching is expensive
Shader preview
#version 300 es
precision highp float;
out vec4 outColor;
in vec2 v_uv;
uniform float u_time;
uniform vec2 u_resolution;
#define PI 3.14159265358979324
#define MAXITER 5
#define MAXDIST 6.0
float fractalKernel(vec3 ver) {
vec3 a = ver;
float b, c, d, e;
for(int i = 0; i < MAXITER; i++) {
b = length(a);
if(b > MAXDIST) break;