WebGPU Forward+ renderer with thousands of dynamic lights in a Sponza scene

WEBGPU FORWARD+ RENDERER

WEBGPU · TYPESCRIPT · GPU LIGHT CULLING

A real-time renderer comparing naive forward, Forward+ and clustered deferred pipelines. Thousands of dynamic lights, compute-driven clustering, render bundles and bloom expose the performance tradeoffs behind modern WebGPU rendering.

REAL-TIME RENDERING · WEBGPU

WebGPU
Forward+

A real-time renderer built around clustered light assignment, with forward and deferred paths sharing one WebGPU scene pipeline.

WebGPU · WGSL · TypeScriptLighting · Compute · Post Process
Sponza scene rendered with Forward+ lighting
01 · RENDER PATHS

One scene.
Three paths.

The renderer separates scene preparation from lighting so the same camera, materials and geometry can move through direct forward shading, clustered Forward+, and clustered deferred shading.

Naive forward render
Naive forward · reference path
Forward plus render
Forward+ · clustered lights
Clustered deferred render
Clustered deferred · G-buffer path
02 · LIGHT ASSIGNMENT

Clusters before
shading.

A compute pass divides the camera frustum into screen-space tiles and depth slices. Lights are assigned once to the clusters they touch; the shading pass reads only the relevant list.

Cluster visualization view one
Cluster volume debug view
Cluster visualization view two
Light-list spatial partition
03 · SYSTEM

Renderer
anatomy.

The project is organized as a sequence of explicit GPU passes. Each stage owns a clear resource boundary, making the lighting paths easy to compare and extend.

01

Scene pass

Loads meshes and materials and prepares shared geometry buffers.

02

Cluster compute

Builds per-cluster light lists before surface shading begins.

03

Lighting paths

Switches between forward and deferred implementations.

04

Post process

Composes the lit frame through a fullscreen compute stage.