mmp / pbrt-v3

Source code for pbrt, the renderer described in the third edition of "Physically Based Rendering: From Theory To Implementation", by Matt Pharr, Wenzel Jakob, and Greg Humphreys.
http://pbrt.org
BSD 2-Clause "Simplified" License
4.88k stars 1.19k forks source link

Fixed a minor bug in the warning message of sobol sampler. #147

Closed rcythr closed 7 years ago

rcythr commented 7 years ago

In sobol.h the local variable samplesPerPixel shadows the member variable with the same name. The warning then prints the local variable instead of the rounded-up member variable.

For example:

W0729 11:00:38.111961 3391042496 error.cpp:87] scene.pbrt(45): Non power-of-two sample count rounded up to 200 for SobolSampler.

This patch fixes the issue by referencing the member variable.

mmp commented 7 years ago

Thanks!