Using an AmbientOcclusionIntegrator (or another SurfaceIntegrator which Li method does not return physical radiance values) in open scenes with light sources results in some dual behavior:
Spectrum SamplerRenderer::Li(...) const {
...
if (scene->Intersect(ray, isect))
Li = surfaceIntegrator->Li(...); // Could be any spectrum
else {
// Handle ray that doesn't intersect any geometry
for (uint32_t i = 0; i < scene->lights.size(); ++i)
Li += scene->lights[i]->Le(ray); // Always physical radiance spectrum
}
...
}
This dual behavior is illustrated in the image below:
The easiest way to fix this is to let the user take care of it by not adding light sources in the .pbrt file. Or refactor the else part to a new abstract method in the SurfaceIntegrator hierarchy.
Using an
AmbientOcclusionIntegrator
(or anotherSurfaceIntegrator
whichLi
method does not return physical radiance values) in open scenes with light sources results in some dual behavior:This dual behavior is illustrated in the image below:![am_bunny1-1_grid_test_s4](https://cloud.githubusercontent.com/assets/2464019/13699790/f310c838-e77c-11e5-8c13-eb1a1fc6d552.png)
The easiest way to fix this is to let the user take care of it by not adding light sources in the
.pbrt
file. Or refactor theelse
part to a new abstract method in theSurfaceIntegrator
hierarchy.