three-gpu-pathtracer
three-gpu-pathtracer copied to clipboard
Add material shader wrapper implementation for procedural surface properties / SDF support
Might require enabling material order to be more consistent / identifiable. Can also implement a version for procedural marching. Instead of just a function that returns a surface property from a model hit you can return a full set of hit information from a ray (ie distance, position, normal, etc) which would allow for procedural scenes and ray marching / SDF rendering.
Similar to unity surface shader and / or shadertoy
Functions
-
intersectScene
- outputs surface properties, material properties?
- Output skip, surface hit, or no hit
- how to support light hits? Require user to check for intersections? Or pass max distance into function?
-
bsdfSample
,bsdfResult
functions