This is an automated email from the git hooks/post-receive script. Git pushed a commit to branch master in repository ffmpeg.
commit e967ae98f404aca912a80f014e6473276804235f Author: Andreas Rheinhardt <[email protected]> AuthorDate: Sun Mar 8 21:00:04 2026 +0100 Commit: Andreas Rheinhardt <[email protected]> CommitDate: Tue Jun 23 17:15:02 2026 +0200 avcodec: Remove FF_API_PARSER_PRIVATE Deprecated on 2025-11-01. It is removed right now despite this being fairly recently, because users never had a legitimate reason to touch these fields at all: After all, their meaning was entirely undocumented. Furthermore, the split callback is unset for any parser since commit e5af9203098a889f36b759652615046254d45102 from 2021. Signed-off-by: Andreas Rheinhardt <[email protected]> --- libavcodec/avcodec.h | 24 ------------------------ libavcodec/parser_internal.h | 22 ---------------------- libavcodec/parsers.c | 16 ---------------- libavcodec/version_major.h | 2 -- 4 files changed, 64 deletions(-) diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h index 5f7ee31f0d..f45e8d8baa 100644 --- a/libavcodec/avcodec.h +++ b/libavcodec/avcodec.h @@ -2762,30 +2762,6 @@ typedef struct AVCodecParserContext { typedef struct AVCodecParser { enum AVCodecID codec_ids[7]; /* several codec IDs are permitted */ -#if FF_API_PARSER_PRIVATE - /***************************************************************** - * All fields below this line are not part of the public API. They - * may not be used outside of libavcodec and can be changed and - * removed at will. - * New public fields should be added right above. - ***************************************************************** - */ - attribute_deprecated - int priv_data_size; - attribute_deprecated - int (*parser_init)(AVCodecParserContext *s); - /* This callback never returns an error, a negative value means that - * the frame start was in a previous packet. */ - attribute_deprecated - int (*parser_parse)(AVCodecParserContext *s, - AVCodecContext *avctx, - const uint8_t **poutbuf, int *poutbuf_size, - const uint8_t *buf, int buf_size); - attribute_deprecated - void (*parser_close)(AVCodecParserContext *s); - attribute_deprecated - int (*split)(AVCodecContext *avctx, const uint8_t *buf, int buf_size); -#endif } AVCodecParser; /** diff --git a/libavcodec/parser_internal.h b/libavcodec/parser_internal.h index aad1fe1146..d0e0c8beb5 100644 --- a/libavcodec/parser_internal.h +++ b/libavcodec/parser_internal.h @@ -23,23 +23,7 @@ #include "libavutil/macros.h" #include "avcodec.h" -#include "codec_id.h" -#if FF_API_PARSER_PRIVATE -typedef union FFCodecParser { - struct { - enum AVCodecID codec_ids[7]; /* several codec IDs are permitted */ - int priv_data_size; - int (*init)(AVCodecParserContext *s); - int (*parse)(AVCodecParserContext *s, - AVCodecContext *avctx, - const uint8_t **poutbuf, int *poutbuf_size, - const uint8_t *buf, int buf_size); - void (*close)(AVCodecParserContext *s); - int (*split)(AVCodecContext *avctx, const uint8_t *buf, int buf_size); - }; - AVCodecParser p; -#else typedef struct FFCodecParser { AVCodecParser p; unsigned priv_data_size; @@ -49,7 +33,6 @@ typedef struct FFCodecParser { const uint8_t **poutbuf, int *poutbuf_size, const uint8_t *buf, int buf_size); void (*close)(AVCodecParserContext *s); -#endif } FFCodecParser; static inline const FFCodecParser *ffcodecparser(const AVCodecParser *parser) @@ -68,12 +51,7 @@ static inline const FFCodecParser *ffcodecparser(const AVCodecParser *parser) #define FIRST_SEVEN(...) FF_MSVC_EXPAND(FIRST_SEVEN2(__VA_ARGS__)) #define TIMES_SEVEN(a) a,a,a,a,a,a,a -#if FF_API_PARSER_PRIVATE -#define PARSER_CODEC_LIST(...) CHECK_FOR_TOO_MANY_IDS(__VA_ARGS__) \ - .codec_ids = { FIRST_SEVEN(__VA_ARGS__, TIMES_SEVEN(AV_CODEC_ID_NONE)) } -#else #define PARSER_CODEC_LIST(...) CHECK_FOR_TOO_MANY_IDS(__VA_ARGS__) \ .p.codec_ids = { FIRST_SEVEN(__VA_ARGS__, TIMES_SEVEN(AV_CODEC_ID_NONE)) } -#endif #endif /* AVCODEC_PARSER_INTERNAL_H */ diff --git a/libavcodec/parsers.c b/libavcodec/parsers.c index 162b96cb69..b54442a0ea 100644 --- a/libavcodec/parsers.c +++ b/libavcodec/parsers.c @@ -21,22 +21,6 @@ #include "avcodec.h" #include "parser_internal.h" -#if FF_API_PARSER_PRIVATE -#include "libavutil/internal.h" -#include <assert.h> -#include <stddef.h> - -FF_DISABLE_DEPRECATION_WARNINGS -#define CHECK_OFFSET(field, public_prefix) static_assert(offsetof(FFCodecParser, field) == offsetof(FFCodecParser, p.public_prefix ## field), "Wrong offsets") -CHECK_OFFSET(codec_ids,); -CHECK_OFFSET(priv_data_size,); -CHECK_OFFSET(init, parser_); -CHECK_OFFSET(parse, parser_); -CHECK_OFFSET(close, parser_); -CHECK_OFFSET(split,); -FF_ENABLE_DEPRECATION_WARNINGS -#endif - extern const FFCodecParser ff_aac_parser; extern const FFCodecParser ff_aac_latm_parser; extern const FFCodecParser ff_ac3_parser; diff --git a/libavcodec/version_major.h b/libavcodec/version_major.h index 5537db72d3..d018680d9b 100644 --- a/libavcodec/version_major.h +++ b/libavcodec/version_major.h @@ -46,8 +46,6 @@ #define FF_API_NVDEC_OLD_PIX_FMTS (LIBAVCODEC_VERSION_MAJOR < 63) -#define FF_API_PARSER_PRIVATE (LIBAVCODEC_VERSION_MAJOR < 63) - #define FF_API_MJPEG_EXTERN_HUFF (LIBAVCODEC_VERSION_MAJOR < 63) #define FF_API_NVENC_H264_MAIN (LIBAVCODEC_VERSION_MAJOR < 63) _______________________________________________ ffmpeg-cvslog mailing list -- [email protected] To unsubscribe send an email to [email protected]
