Enterprise PBR WebGL Path Tracer

June 7, 2026 ยท View on GitHub

Demo Viewer

Minimal Demo [ Code ]

Features

Development

Package layout:

  • packages/lib: renderer, loaders, shaders, public viewport API
  • packages/app: viewer UI, camera/controller helpers, and minimal integration example
# yarn is mandatory as this project uses yarn workspaces
yarn install

# Regenerate the slang-pbr material GLSL artifact; set SLANG_PBR_ROOT for a local checkout
yarn build:slang-materials

# Builds all packages
yarn build

# Validate assembled WebGL shader variants with glslangValidator
yarn validate:shaders

# Launch the demo viewer with HMR enabled -> auto update on code change during development
yarn run dev

# Launch the same dev server and open the minimal integration example
yarn run dev:example

Third-party

This project stands on a lot of excellent open source work. Thanks to the authors and maintainers of:

  • TinyBVH, by Jacco Bikker, for the compact high-performance BVH builder and traversal code that backs the WASM acceleration structure path.
  • tinybvh-wasm, for the reusable TinyBVH WebAssembly bridge and browser-facing BVH builder ABI.
  • glTF Transform, by Don McCurdy and contributors, for the glTF parsing, extension handling, and asset processing foundation.
  • meshoptimizer, by Arseny Kapoulkine, for mesh compression decoding support used by glTF assets.
  • Slang, from the shader-slang project and its research contributors, for the shader language/toolchain used to generate the material model code.
  • slang-pbr, for the reusable Enterprise PBR Slang material source used by the generated WebGL material model.
  • Tweakpane, by Hiroki Tani and contributors, for the compact viewer control UI.
  • simple-dropzone, for the browser drag-and-drop file loading used by the viewer.
  • Vite and tsup for the development server and package build workflow.
  • The Khronos glTF Sample Assets and related sample model repositories, for the scenes that make testing and demos practical.

License