mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-01-21 23:03:13 +00:00
showwaves: fix PTS computation.
This commit is contained in:
parent
6d627eae3c
commit
6fd0b55ab2
@ -202,7 +202,10 @@ static void filter_samples(AVFilterLink *inlink, AVFilterBufferRef *insamples)
|
||||
outlink->w, outlink->h);
|
||||
outpicref->video->w = outlink->w;
|
||||
outpicref->video->h = outlink->h;
|
||||
outpicref->pts = insamples->pts;
|
||||
outpicref->pts = insamples->pts +
|
||||
av_rescale_q((p - (int16_t *)insamples->data[0]) / nb_channels,
|
||||
(AVRational){ 1, inlink->sample_rate },
|
||||
outlink->time_base);
|
||||
outlink->out_buf = outpicref;
|
||||
linesize = outpicref->linesize[0];
|
||||
memset(outpicref->data[0], 0, showwaves->h*linesize);
|
||||
|
Loading…
Reference in New Issue
Block a user