From 45b381d0ac8fdc79aae68220c7dffd166b0b92d3 Mon Sep 17 00:00:00 2001 From: Wenzel Jakob Date: Mon, 30 Aug 2010 10:14:24 +0200 Subject: [PATCH] fixed infinite recursion possibility in the VPL generator --- src/librender/vpl.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/librender/vpl.cpp b/src/librender/vpl.cpp index 7a2523c4..e6245e92 100644 --- a/src/librender/vpl.cpp +++ b/src/librender/vpl.cpp @@ -54,7 +54,7 @@ size_t generateVPLs(const Scene *scene, size_t offset, size_t count, int maxDept /* Assuming that BSDF importance sampling is perfect, the following should equal the maximum albedo over all spectral samples */ - Float approxAlbedo = std::min((Float) 1, bsdfVal.max()); + Float approxAlbedo = std::min((Float) 0.9f, bsdfVal.max()); if (sampler->next1D() > approxAlbedo) break; else