Celeritas 0.7.0-dev.80+develop.2dd9b831b
|
Sample a valid facet normal by wrapping a roughness calculator. More...
#include <SurfacePhysicsUtils.hh>
Public Member Functions | |
template<class... Args> | |
CELER_FUNCTION | EnteringSurfaceNormalSampler (Real3 const &dir, Real3 const &normal, Args &&... args) |
template<class Engine > | |
CELER_FUNCTION Real3 | operator() (Engine &rng) |
Sample a valid facet normal by wrapping a roughness calculator.
Some facet normal calculators might not produce surface normals valid for optical physics surface crossings (see is_entering_surface
). This functor will construct and repeatedly sample the distribution until the track is exiting the sampled facet normal.