three-gpu-pathtracer icon indicating copy to clipboard operation
three-gpu-pathtracer copied to clipboard

Add material shader wrapper implementation for procedural surface properties / SDF support

Open gkjohnson opened this issue 2 years ago • 1 comments

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

gkjohnson avatar Apr 02 '22 20:04 gkjohnson

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

gkjohnson avatar Mar 18 '23 03:03 gkjohnson