1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

lavc/videotoolbox: deprecate write-only output_callback

This field has never been used for anything, so stop setting it and
deprecate it.
This commit is contained in:
Anton Khirnov 2022-09-15 15:53:12 +02:00
parent d7f4ad88a0
commit 8576c3c5d8
3 changed files with 6 additions and 2 deletions

View File

@ -51,5 +51,6 @@
#define FF_API_IDCT_NONE (LIBAVCODEC_VERSION_MAJOR < 60)
#define FF_API_SVTAV1_OPTS (LIBAVCODEC_VERSION_MAJOR < 60)
#define FF_API_AYUV_CODECID (LIBAVCODEC_VERSION_MAJOR < 60)
#define FF_API_VT_OUTPUT_CALLBACK (LIBAVCODEC_VERSION_MAJOR < 60)
#endif /* AVCODEC_VERSION_MAJOR_H */

View File

@ -1377,8 +1377,6 @@ static AVVideotoolboxContext *av_videotoolbox_alloc_context_with_pix_fmt(enum AV
AVVideotoolboxContext *ret = av_mallocz(sizeof(*ret));
if (ret) {
ret->output_callback = videotoolbox_decoder_callback;
OSType cv_pix_fmt_type = av_map_videotoolbox_format_from_pixfmt2(pix_fmt, full_range);
if (cv_pix_fmt_type == 0) {
cv_pix_fmt_type = kCVPixelFormatType_420YpCbCr8BiPlanarVideoRange;

View File

@ -37,6 +37,8 @@
#include "libavcodec/avcodec.h"
#include "libavutil/attributes.h"
/**
* This struct holds all the information that needs to be passed
* between the caller and libavcodec for initializing Videotoolbox decoding.
@ -50,11 +52,14 @@ typedef struct AVVideotoolboxContext {
*/
VTDecompressionSessionRef session;
#if FF_API_VT_OUTPUT_CALLBACK
/**
* The output callback that must be passed to the session.
* Set by av_videottoolbox_default_init()
*/
attribute_deprecated
VTDecompressionOutputCallback output_callback;
#endif
/**
* CVPixelBuffer Format Type that Videotoolbox will use for decoded frames.