You've already forked libopenshot
mirror of
https://github.com/OpenShot/libopenshot.git
synced 2026-03-02 08:53:52 -08:00
Merge pull request #520 from OpenShot/fix-fps-ffmpeg4
Fix FPS setting on FFmpeg 4
This commit is contained in:
@@ -1222,6 +1222,13 @@ AVStream *FFmpegWriter::add_video_stream() {
|
||||
st->avg_frame_rate = av_inv_q(c->time_base);
|
||||
st->time_base.num = info.video_timebase.num;
|
||||
st->time_base.den = info.video_timebase.den;
|
||||
#if (LIBAVFORMAT_VERSION_MAJOR >= 58)
|
||||
#pragma GCC diagnostic push
|
||||
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
||||
st->codec->time_base.num = info.video_timebase.num;
|
||||
st->codec->time_base.den = info.video_timebase.den;
|
||||
#pragma GCC diagnostic pop
|
||||
#endif
|
||||
|
||||
c->gop_size = 12; /* TODO: add this to "info"... emit one intra frame every twelve frames at most */
|
||||
c->max_b_frames = 10;
|
||||
|
||||
Reference in New Issue
Block a user