avfilter/avf_showspectrum: increase padding size for low sample rates
authorPaul B Mahol <onemda@gmail.com>
Fri, 5 Oct 2018 13:23:02 +0000 (15:23 +0200)
committerPaul B Mahol <onemda@gmail.com>
Fri, 5 Oct 2018 13:23:02 +0000 (15:23 +0200)
libavfilter/avf_showspectrum.c

index bbe42ba..f5e8561 100644 (file)
@@ -446,7 +446,7 @@ static int config_output(AVFilterLink *outlink)
     outlink->sample_aspect_ratio = (AVRational){1,1};
 
     if (s->legend) {
-        s->start_x = log10(inlink->sample_rate) * 25;
+        s->start_x = (log10(inlink->sample_rate) + 1) * 25;
         s->start_y = 64;
         outlink->w += s->start_x * 2;
         outlink->h += s->start_y * 2;