" uniform sampler2D uAccumTexture;\n"
"#endif\n"
"\n"
- "//! Maximum radiance that can be added to the pixel. Decreases noise\n"
- "//! level, but introduces some bias.\n"
- "#define MAX_RADIANCE vec3 (50.f)\n"
+ "//! Maximum radiance that can be added to the pixel.\n"
+ "//! Decreases noise level, but introduces some bias.\n"
+ "uniform float uMaxRadiance = 50.f;\n"
"\n"
"// =======================================================================\n"
"// function : main\n"
" aColor.rgb = ZERO;\n"
" }\n"
"\n"
- " aColor.rgb = min (aColor.rgb, MAX_RADIANCE);\n"
+ " aColor.rgb = min (aColor.rgb, vec3 (uMaxRadiance));\n"
"\n"
"#ifdef ADAPTIVE_SAMPLING\n"
"\n"