NVIDIA/webgl-path-tracing

Name: webgl-path-tracing

Owner: NVIDIA Corporation

Description: Path tracing in GLSL using WebGL

Created: 2014-09-11 15:19:21.0

Updated: 2018-03-06 06:58:34.0

Pushed: 2014-09-11 15:30:59.0

Homepage: http://madebyevan.com/webgl-path-tracing/

Size: 402

Language: null

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

WebGL Path Tracing

Try it live (requires a browser with WebGL)

Path tracing is a realistic lighting algorithm that simulates light bouncing around a scene. This path tracer uses WebGL for realtime performance and supports diffuse, mirrored, and glossy surfaces. The path tracer is continually rendering, so the scene will start off grainy and become smoother over time.

The entire scene is dynamically compiled into a GLSL shader. Everything can be repositioned using the current shader, but any geometry or material change means a recompilation. To calculate a pixel color, a ray is shot into the scene and allowed to bounce around five times. At each bounce, the direct light incoming at that point (including shadows) is multiplied by all previous material colors and accumulated. Soft shadows are achieved by randomly jittering the light position per-pixel.


This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.