1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-11-21 10:55:51 +02:00

avfilter/avf_avectorscope: fix zoom 0 mode with nonlinear scale

This commit is contained in:
Paul B Mahol 2021-09-19 13:47:59 +02:00
parent 7747ab7ded
commit 0b150e4f61

View File

@ -303,6 +303,18 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *insamples)
av_assert2(0);
}
switch (s->scale) {
case SQRT:
max = sqrtf(max);
break;
case CBRT:
max = cbrtf(max);
break;
case LOG:
max = logf(1 + max) / logf(2);
break;
}
zoom = 1. / max;
}