From 131f2c2712479a44332866b442526abe97e0c316 Mon Sep 17 00:00:00 2001 From: Andreas Rheinhardt Date: Thu, 25 Feb 2021 14:42:59 +0100 Subject: [PATCH] avformat: Remove FFserver leftovers Signed-off-by: Andreas Rheinhardt Signed-off-by: James Almer --- libavformat/avformat.h | 18 ------------------ libavformat/utils.c | 22 ---------------------- libavformat/version.h | 3 --- 3 files changed, 43 deletions(-) diff --git a/libavformat/avformat.h b/libavformat/avformat.h index 166f1aa41cf..578ccbd87d1 100644 --- a/libavformat/avformat.h +++ b/libavformat/avformat.h @@ -1000,18 +1000,6 @@ typedef struct AVStream { */ AVRational r_frame_rate; -#if FF_API_LAVF_FFSERVER - /** - * String containing pairs of key and values describing recommended encoder configuration. - * Pairs are separated by ','. - * Keys are separated from values by '='. - * - * @deprecated unused - */ - attribute_deprecated - char *recommended_encoder_configuration; -#endif - /** * Codec parameters associated with this stream. Allocated and freed by * libavformat in avformat_new_stream() and avformat_free_context() @@ -1107,12 +1095,6 @@ 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); -#if FF_API_LAVF_FFSERVER -attribute_deprecated -char* av_stream_get_recommended_encoder_configuration(const AVStream *s); -attribute_deprecated -void av_stream_set_recommended_encoder_configuration(AVStream *s, char *configuration); -#endif #endif struct AVCodecParserContext *av_stream_get_parser(const AVStream *s); diff --git a/libavformat/utils.c b/libavformat/utils.c index ec48d1c08e4..7d944268d35 100644 --- a/libavformat/utils.c +++ b/libavformat/utils.c @@ -115,11 +115,6 @@ static int64_t wrap_timestamp(const AVStream *st, int64_t timestamp) #if FF_API_FORMAT_GET_SET MAKE_ACCESSORS(AVStream, stream, AVRational, r_frame_rate) -#if FF_API_LAVF_FFSERVER -FF_DISABLE_DEPRECATION_WARNINGS -MAKE_ACCESSORS(AVStream, stream, char *, recommended_encoder_configuration) -FF_ENABLE_DEPRECATION_WARNINGS -#endif MAKE_ACCESSORS(AVFormatContext, format, AVCodec *, video_codec) MAKE_ACCESSORS(AVFormatContext, format, AVCodec *, audio_codec) MAKE_ACCESSORS(AVFormatContext, format, AVCodec *, subtitle_codec) @@ -4392,18 +4387,6 @@ int ff_stream_encode_params_copy(AVStream *dst, const AVStream *src) } } -#if FF_API_LAVF_FFSERVER -FF_DISABLE_DEPRECATION_WARNINGS - av_freep(&dst->recommended_encoder_configuration); - if (src->recommended_encoder_configuration) { - const char *conf_str = src->recommended_encoder_configuration; - dst->recommended_encoder_configuration = av_strdup(conf_str); - if (!dst->recommended_encoder_configuration) - return AVERROR(ENOMEM); - } -FF_ENABLE_DEPRECATION_WARNINGS -#endif - return 0; } @@ -4448,11 +4431,6 @@ FF_DISABLE_DEPRECATION_WARNINGS FF_ENABLE_DEPRECATION_WARNINGS #endif av_freep(&st->priv_data); -#if FF_API_LAVF_FFSERVER -FF_DISABLE_DEPRECATION_WARNINGS - av_freep(&st->recommended_encoder_configuration); -FF_ENABLE_DEPRECATION_WARNINGS -#endif av_freep(pst); } diff --git a/libavformat/version.h b/libavformat/version.h index 1652cb08d81..4616d5fb142 100644 --- a/libavformat/version.h +++ b/libavformat/version.h @@ -82,9 +82,6 @@ #ifndef FF_API_OLD_AVIO_EOF_0 #define FF_API_OLD_AVIO_EOF_0 (LIBAVFORMAT_VERSION_MAJOR < 59) #endif -#ifndef FF_API_LAVF_FFSERVER -#define FF_API_LAVF_FFSERVER (LIBAVFORMAT_VERSION_MAJOR < 59) -#endif #ifndef FF_API_FORMAT_FILENAME #define FF_API_FORMAT_FILENAME (LIBAVFORMAT_VERSION_MAJOR < 59) #endif -- 2.39.2