From 1382035d4de5ada310c7f4fd00f1836b16ab74fb Mon Sep 17 00:00:00 2001 From: feos Date: Sat, 23 Apr 2022 19:23:53 +0300 Subject: [PATCH] explicitly set timebase for video stream (#6005) fixes #5965 --- src/core/dumping/ffmpeg_backend.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/core/dumping/ffmpeg_backend.cpp b/src/core/dumping/ffmpeg_backend.cpp index 292207b4b8..28c33639b0 100644 --- a/src/core/dumping/ffmpeg_backend.cpp +++ b/src/core/dumping/ffmpeg_backend.cpp @@ -156,6 +156,8 @@ bool FFmpegVideoStream::Init(FFmpegMuxer& muxer, const Layout::FramebufferLayout return false; } + stream->time_base = codec_context->time_base; + // Allocate frames current_frame.reset(av_frame_alloc()); scaled_frame.reset(av_frame_alloc());