lavc: deprecate the omx encoders

They have not been relevant for a long time, and support for this API is
also being dropped from other projects.
This commit is contained in:
Anton Khirnov 2024-10-26 11:23:49 +02:00
parent 9e68b26765
commit 13129f1af4
4 changed files with 11 additions and 1 deletions

View File

@ -5,6 +5,7 @@ version <next>:
- yasm support dropped, users need to use nasm - yasm support dropped, users need to use nasm
- VVC VAAPI decoder - VVC VAAPI decoder
- RealVideo 6.0 decoder - RealVideo 6.0 decoder
- OpenMAX encoders deprecated
version 7.1: version 7.1:
- Raw Captions with Time (RCWT) closed caption demuxer - Raw Captions with Time (RCWT) closed caption demuxer

4
configure vendored
View File

@ -7110,7 +7110,9 @@ enabled omx_rpi && { test_code cc OMX_Core.h OMX_IndexConfigBrcmVideoR
test_code cc OMX_Core.h OMX_IndexConfigBrcmVideoRequestIFrame; } || test_code cc OMX_Core.h OMX_IndexConfigBrcmVideoRequestIFrame; } ||
die "ERROR: OpenMAX IL headers from raspberrypi/firmware not found"; } && die "ERROR: OpenMAX IL headers from raspberrypi/firmware not found"; } &&
enable omx enable omx
enabled omx && require_headers OMX_Core.h enabled omx && require_headers OMX_Core.h && \
warn "The OpenMAX encoders are deprecated and will be removed in future versions"
enabled openssl && { { check_pkg_config openssl "openssl >= 3.0.0" openssl/ssl.h OPENSSL_init_ssl && enabled openssl && { { check_pkg_config openssl "openssl >= 3.0.0" openssl/ssl.h OPENSSL_init_ssl &&
{ enabled gplv3 || ! enabled gpl || enabled nonfree || die "ERROR: OpenSSL >=3.0.0 requires --enable-version3"; }; } || { enabled gplv3 || ! enabled gpl || enabled nonfree || die "ERROR: OpenSSL >=3.0.0 requires --enable-version3"; }; } ||
{ enabled gpl && ! enabled nonfree && die "ERROR: OpenSSL <3.0.0 is incompatible with the gpl"; } || { enabled gpl && ! enabled nonfree && die "ERROR: OpenSSL <3.0.0 is incompatible with the gpl"; } ||

View File

@ -648,6 +648,10 @@ static av_cold int omx_encode_init(AVCodecContext *avctx)
OMX_BUFFERHEADERTYPE *buffer; OMX_BUFFERHEADERTYPE *buffer;
OMX_ERRORTYPE err; OMX_ERRORTYPE err;
av_log(avctx, AV_LOG_WARNING,
"The %s encoder is deprecated and will be removed in future versions\n",
avctx->codec->name);
/* cleanup relies on the mutexes/conditions being initialized first. */ /* cleanup relies on the mutexes/conditions being initialized first. */
ret = ff_pthread_init(s, omx_codec_context_offsets); ret = ff_pthread_init(s, omx_codec_context_offsets);
if (ret < 0) if (ret < 0)

View File

@ -50,4 +50,7 @@
#define FF_API_QUALITY_FACTOR (LIBAVCODEC_VERSION_MAJOR < 62) #define FF_API_QUALITY_FACTOR (LIBAVCODEC_VERSION_MAJOR < 62)
#define FF_API_V408_CODECID (LIBAVCODEC_VERSION_MAJOR < 62) #define FF_API_V408_CODECID (LIBAVCODEC_VERSION_MAJOR < 62)
// reminder to remove the OMX encoder on next major bump
#define FF_CODEC_OMX (LIBAVCODEC_VERSION_MAJOR < 62)
#endif /* AVCODEC_VERSION_MAJOR_H */ #endif /* AVCODEC_VERSION_MAJOR_H */