MCPcopy Create free account
hub / github.com/TheRealMJP/BakingLab / Occluded

Function Occluded

BakingLab/PathTracer.cpp:104–109  ·  view source on GitHub ↗

Returns true the the ray is occluded by a triangle

Source from the content-addressed store, hash-verified

102
103// Returns true the the ray is occluded by a triangle
104static bool Occluded(RTCScene scene, const Float3& position, const Float3& direction, float nearDist, float farDist)
105{
106 EmbreeRay ray(position, direction, nearDist, farDist);
107 rtcOccluded(scene, ray);
108 return ray.Hit();
109}
110
111// Calculates diffuse and specular from a spherical area light
112static Float3 SampleSphericalAreaLight(const Float3& position, const Float3& normal, RTCScene scene,

Callers 1

SampleSphericalAreaLightFunction · 0.85

Calls 1

HitMethod · 0.80

Tested by

no test coverage detected