mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-28 20:53:54 +02:00
fftools/ffmpeg_enc: set audio frame duration when encoding
This commit is contained in:
parent
9a44e0335c
commit
af286f17a1
@ -811,6 +811,8 @@ static void do_audio_out(OutputFile *of, OutputStream *ost,
|
||||
av_rescale_q(start_time, AV_TIME_BASE_Q, enc->time_base);
|
||||
}
|
||||
frame->time_base = enc->time_base;
|
||||
frame->duration = av_rescale_q(frame->nb_samples, (AVRational){1, frame->sample_rate},
|
||||
enc->time_base);
|
||||
|
||||
if (!check_recording_time(ost, frame->pts, frame->time_base))
|
||||
return;
|
||||
|
Loading…
Reference in New Issue
Block a user