libobs,libobs-opengl,obs-ffmpeg-mux: Calm deprecation warnings on *nix

Calm libobs-opengl deprecation warnings on macOS.

Calm FFmpeg deprecation warning with LIBAVFORMAT_VERSION_MAJOR < 59.
This commit is contained in:
tytan652
2023-01-19 13:08:46 -05:00
committed by Ryan Foster
parent 541b3292e9
commit c648222332
4 changed files with 35 additions and 0 deletions
@@ -472,7 +472,10 @@ static void create_video_stream(struct ffmpeg_mux *ffm)
ffm->video_stream->time_base = context->time_base;
#if LIBAVFORMAT_VERSION_MAJOR < 59
// codec->time_base may still be used if LIBAVFORMAT_VERSION_MAJOR < 59
PRAGMA_WARN_PUSH
PRAGMA_WARN_DEPRECATION
ffm->video_stream->codec->time_base = context->time_base;
PRAGMA_WARN_POP
#endif
ffm->video_stream->avg_frame_rate = av_inv_q(context->time_base);