[FFmpeg-cvslog] avfilter/vf_lut: make it possible to clip pixel values that are out of valid range
Paul B Mahol
git at videolan.org
Mon Feb 13 23:54:32 EET 2017
ffmpeg | branch: master | Paul B Mahol <onemda at gmail.com> | Mon Feb 13 22:49:41 2017 +0100| [aa234698e92fa856013a1391fac3526b06c4d533] | committer: Paul B Mahol
avfilter/vf_lut: make it possible to clip pixel values that are out of valid range
Previous behavior was not useful at all as such pixels where all mapped to 0.
Signed-off-by: Paul B Mahol <onemda at gmail.com>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=aa234698e92fa856013a1391fac3526b06c4d533
---
libavfilter/vf_lut.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavfilter/vf_lut.c b/libavfilter/vf_lut.c
index 2472673..d005afa 100644
--- a/libavfilter/vf_lut.c
+++ b/libavfilter/vf_lut.c
@@ -310,7 +310,7 @@ static int config_props(AVFilterLink *inlink)
s->var_values[VAR_MAXVAL] = max[color];
s->var_values[VAR_MINVAL] = min[color];
- for (val = 0; val < (1 << desc->comp[0].depth); val++) {
+ for (val = 0; val < FF_ARRAY_ELEMS(s->lut[comp]); val++) {
s->var_values[VAR_VAL] = val;
s->var_values[VAR_CLIPVAL] = av_clip(val, min[color], max[color]);
s->var_values[VAR_NEGVAL] =
More information about the ffmpeg-cvslog
mailing list