You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I am writing an SDF modeler and for the ray marching to be correct I need to know if the path tracer state is currently inside or outside an object.
Would that be somehow evident from the State struct ?
Thanks
The text was updated successfully, but these errors were encountered:
You can probably get that information from the surface normal. If state.normal and state.ffnormal are on the same side i.e. dot(state.normal, state.ffnormal) > 0 then the ray has hit the surface from the outside, otherwise the ray has hit the inner surface.
Hi, I am writing an SDF modeler and for the ray marching to be correct I need to know if the path tracer state is currently inside or outside an object.
Would that be somehow evident from the State struct ?
Thanks
The text was updated successfully, but these errors were encountered: