Showing the changes to libraries/render-utils/src/FramebufferCache.cpp (1 of 3 files). Show all
Unified · Split
| @@ -247,7 +247,8 @@ gpu::TexturePointer FramebufferCache::getDepthPyramidTexture() { · 246 unmodified lines | ||
| 247 | 247 | } |
| 248 | 248 | |
| 249 | 249 | void FramebufferCache::setAmbientOcclusionResolutionLevel(int level) { |
| 250 | − level = std::max(0, std::min(level, 4)); | |
| 250 | + const int MAX_AO_RESOLUTION_LEVEL = 4; | |
| 251 | + level = std::max(0, std::min(level, MAX_AO_RESOLUTION_LEVEL)); | |
| 251 | 252 | if (level != _AOResolutionLevel) { |
| 252 | 253 | _AOResolutionLevel = level; |
| 253 | 254 | resizeAmbientOcclusionBuffers(); |