[Bf-blender-cvs] [be636f72dcc] master: Cleanup: Remove LibAV support

Sebastian Parborg noreply at git.blender.org
Fri Feb 5 14:31:03 CET 2021


Commit: be636f72dcc1ca1bc815b246bb6661c0b7b11f82
Author: Sebastian Parborg
Date:   Fri Feb 5 14:28:52 2021 +0100
Branches: master
https://developer.blender.org/rBbe636f72dcc1ca1bc815b246bb6661c0b7b11f82

Cleanup: Remove LibAV support

Ubuntu and Debian dropped libav in 2015 in favor of ffmpeg.
Development stopped of libav in 2018, so it should be save to remove.

===================================================================

M	intern/ffmpeg/ffmpeg_compat.h

===================================================================

diff --git a/intern/ffmpeg/ffmpeg_compat.h b/intern/ffmpeg/ffmpeg_compat.h
index d6eb5f9db1d..727fd4b9601 100644
--- a/intern/ffmpeg/ffmpeg_compat.h
+++ b/intern/ffmpeg/ffmpeg_compat.h
@@ -49,16 +49,6 @@
 
 #include <libswscale/swscale.h>
 
-/* Stupid way to distinguish FFmpeg from Libav:
- * - FFmpeg's MICRO version starts from 100 and goes up, while
- * - Libav's micro is always below 100.
- */
-#if LIBAVCODEC_VERSION_MICRO >= 100
-#  define AV_USING_FFMPEG
-#else
-#  define AV_USING_LIBAV
-#endif
-
 #if (LIBAVFORMAT_VERSION_MAJOR > 52) || \
     ((LIBAVFORMAT_VERSION_MAJOR >= 52) && (LIBAVFORMAT_VERSION_MINOR >= 105))
 #  define FFMPEG_HAVE_AVIO 1
@@ -528,22 +518,6 @@ bool av_check_encoded_with_ffmpeg(AVFormatContext *ctx)
   return false;
 }
 
-/* Libav doesn't have av_guess_frame_rate().
- * It was introduced in FFmpeg's lavf 55.1.100. */
-#ifdef AV_USING_LIBAV
-AVRational av_guess_frame_rate(AVFormatContext *ctx, AVStream *stream, AVFrame *frame)
-{
-  (void)ctx;
-  (void)frame;
-#  if LIBAVCODEC_VERSION_INT < AV_VERSION_INT(54, 23, 1)
-  /* For until r_frame_rate was deprecated (in Libav) use it. */
-  return stream->r_frame_rate;
-#  else
-  return stream->avg_frame_rate;
-#  endif
-}
-#endif
-
 #if LIBAVUTIL_VERSION_INT < AV_VERSION_INT(51, 32, 0)
 #  define AV_OPT_SEARCH_FAKE_OBJ 0
 #endif



More information about the Bf-blender-cvs mailing list