From 8c0162e7622fb60ea0971d27080bcd89caa5b20d Mon Sep 17 00:00:00 2001 From: Niklas Haas Date: Fri, 7 Jul 2017 21:00:21 +0200 Subject: vo_opengl: support tone-mapping-param for `clip` This just indicates a fixed linear coefficient to multiply into the signal, similar to the old option --target-brightness (but the inverse thereof). Good for testing purposes, which is why I added it. (This also corresponds somewhat to what zimg does) --- video/out/opengl/video_shaders.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'video') diff --git a/video/out/opengl/video_shaders.c b/video/out/opengl/video_shaders.c index d343111389..83b9f83143 100644 --- a/video/out/opengl/video_shaders.c +++ b/video/out/opengl/video_shaders.c @@ -538,7 +538,7 @@ static void pass_tone_map(struct gl_shader_cache *sc, float ref_peak, switch (algo) { case TONE_MAPPING_CLIP: - GLSL(luma = clamp(luma, 0.0, 1.0);) + GLSLF("luma = clamp(%f * luma, 0.0, 1.0);\n", isnan(param) ? 1.0 : param); break; case TONE_MAPPING_MOBIUS: { -- cgit v1.2.3