]> git.sesse.net Git - ffmpeg/commitdiff
avformat: Remove getters and setters
authorAndreas Rheinhardt <andreas.rheinhardt@gmail.com>
Thu, 25 Feb 2021 13:49:18 +0000 (14:49 +0100)
committerJames Almer <jamrial@gmail.com>
Tue, 27 Apr 2021 13:43:09 +0000 (10:43 -0300)
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
libavformat/avformat.h
libavformat/utils.c
libavformat/version.h

index 14063ac5e562ed7736bc2531b4cc9ce50bd2caf4..d629eaae5d71c31063b9be913da1833fabf651f1 100644 (file)
@@ -1086,17 +1086,6 @@ typedef struct AVStream {
     AVStreamInternal *internal;
 } AVStream;
 
-#if FF_API_FORMAT_GET_SET
-/**
- * Accessors for some AVStream fields. These used to be provided for ABI
- * compatibility, and do not need to be used anymore.
- */
-attribute_deprecated
-AVRational av_stream_get_r_frame_rate(const AVStream *s);
-attribute_deprecated
-void       av_stream_set_r_frame_rate(AVStream *s, AVRational r);
-#endif
-
 struct AVCodecParserContext *av_stream_get_parser(const AVStream *s);
 
 /**
@@ -1807,43 +1796,6 @@ typedef struct AVFormatContext {
     int max_probe_packets;
 } AVFormatContext;
 
-#if FF_API_FORMAT_GET_SET
-/**
- * Accessors for some AVFormatContext fields. These used to be provided for ABI
- * compatibility, and do not need to be used anymore.
- */
-attribute_deprecated
-int av_format_get_probe_score(const AVFormatContext *s);
-attribute_deprecated
-AVCodec * av_format_get_video_codec(const AVFormatContext *s);
-attribute_deprecated
-void      av_format_set_video_codec(AVFormatContext *s, AVCodec *c);
-attribute_deprecated
-AVCodec * av_format_get_audio_codec(const AVFormatContext *s);
-attribute_deprecated
-void      av_format_set_audio_codec(AVFormatContext *s, AVCodec *c);
-attribute_deprecated
-AVCodec * av_format_get_subtitle_codec(const AVFormatContext *s);
-attribute_deprecated
-void      av_format_set_subtitle_codec(AVFormatContext *s, AVCodec *c);
-attribute_deprecated
-AVCodec * av_format_get_data_codec(const AVFormatContext *s);
-attribute_deprecated
-void      av_format_set_data_codec(AVFormatContext *s, AVCodec *c);
-attribute_deprecated
-int       av_format_get_metadata_header_padding(const AVFormatContext *s);
-attribute_deprecated
-void      av_format_set_metadata_header_padding(AVFormatContext *s, int c);
-attribute_deprecated
-void *    av_format_get_opaque(const AVFormatContext *s);
-attribute_deprecated
-void      av_format_set_opaque(AVFormatContext *s, void *opaque);
-attribute_deprecated
-av_format_control_message av_format_get_control_message_cb(const AVFormatContext *s);
-attribute_deprecated
-void      av_format_set_control_message_cb(AVFormatContext *s, av_format_control_message callback);
-#endif
-
 /**
  * This function will cause global side data to be injected in the next packet
  * of each stream as well as after any subsequent seek.
index bb0351d7f57d2fe727bd3e1c533456b51aac0ad2..3643a836326a6a39a67429dfc3be4eaeb6aed773 100644 (file)
@@ -113,17 +113,6 @@ static int64_t wrap_timestamp(const AVStream *st, int64_t timestamp)
     return timestamp;
 }
 
-#if FF_API_FORMAT_GET_SET
-MAKE_ACCESSORS(AVStream, stream, AVRational, r_frame_rate)
-MAKE_ACCESSORS(AVFormatContext, format, AVCodec *, video_codec)
-MAKE_ACCESSORS(AVFormatContext, format, AVCodec *, audio_codec)
-MAKE_ACCESSORS(AVFormatContext, format, AVCodec *, subtitle_codec)
-MAKE_ACCESSORS(AVFormatContext, format, AVCodec *, data_codec)
-MAKE_ACCESSORS(AVFormatContext, format, int, metadata_header_padding)
-MAKE_ACCESSORS(AVFormatContext, format, void *, opaque)
-MAKE_ACCESSORS(AVFormatContext, format, av_format_control_message, control_message_cb)
-#endif
-
 int64_t av_stream_get_end_pts(const AVStream *st)
 {
     if (st->internal->priv_pts) {
@@ -221,13 +210,6 @@ static const AVCodec *find_probe_decoder(AVFormatContext *s, const AVStream *st,
     return codec;
 }
 
-#if FF_API_FORMAT_GET_SET
-int av_format_get_probe_score(const AVFormatContext *s)
-{
-    return s->probe_score;
-}
-#endif
-
 /* an arbitrarily chosen "sane" max packet size -- 50M */
 #define SANE_CHUNK_SIZE (50000000)
 
index 495d03c57fe2f0630724c3942820576e8c398d5a..e4f37ab0f2991224717edd98355b1818fd4e795b 100644 (file)
@@ -73,9 +73,6 @@
 #ifndef FF_API_OLD_ROTATE_API
 #define FF_API_OLD_ROTATE_API           (LIBAVFORMAT_VERSION_MAJOR < 59)
 #endif
-#ifndef FF_API_FORMAT_GET_SET
-#define FF_API_FORMAT_GET_SET           (LIBAVFORMAT_VERSION_MAJOR < 59)
-#endif
 #ifndef FF_API_OLD_AVIO_EOF_0
 #define FF_API_OLD_AVIO_EOF_0           (LIBAVFORMAT_VERSION_MAJOR < 59)
 #endif