bump effective LOD (Level Of Detail) up during the capture phase to work arround things like trying to capture within a building with agressive optimization killing off the internals due to the smaller effective 'screen' being rendered.

This commit is contained in:
Azaezel 2018-12-03 11:15:17 -06:00
parent a2bd0e0fcd
commit 0d915b31ae

View file

@ -980,8 +980,10 @@ void ReflectionProbe::bake(String outputPath, S32 resolution, bool renderWithPro
MathUtils::makeFrustum(&left, &right, &top, &bottom, M_HALFPI_F, 1.0f, nearPlane);
Frustum frustum(false, left, right, top, bottom, nearPlane, farDist);
F32 detailAdjustBackup = TSShapeInstance::smDetailAdjust;
TSShapeInstance::smDetailAdjust *= getNextPow2(resolution);
renderFrame(&baseTarget, matView, frustum, mCaptureMask & EDITOR_RENDER_TYPEMASK, gCanvasClearColor);
TSShapeInstance::smDetailAdjust = detailAdjustBackup;
baseTarget->resolve();
}