aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/avcodec.h
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2021-01-25 12:03:44 +0100
committerAnton Khirnov <anton@khirnov.net>2021-01-26 17:05:58 +0100
commit9e30859cb60b915f237581e3ce91b0d31592edc0 (patch)
tree273bc816c6712a7a32a16b4354d5880412ea2575 /libavcodec/avcodec.h
parent25f4304ebbf96c7ae2952d72b04ad244f8d96334 (diff)
downloadffmpeg-9e30859cb60b915f237581e3ce91b0d31592edc0.tar.gz
lavc: shedule old encoding/decoding API for removal
It has been deprecated for 4 years and certain new codecs do not work with it. Also include AVCodecContext.refcounted_frames, as it has no effect with the new API.
Diffstat (limited to 'libavcodec/avcodec.h')
-rw-r--r--libavcodec/avcodec.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h
index eafc2e84e3..7dbf083a24 100644
--- a/libavcodec/avcodec.h
+++ b/libavcodec/avcodec.h
@@ -1345,6 +1345,7 @@ typedef struct AVCodecContext {
*/
int (*get_buffer2)(struct AVCodecContext *s, AVFrame *frame, int flags);
+#if FF_API_OLD_ENCDEC
/**
* If non-zero, the decoded audio and video frames returned from
* avcodec_decode_video2() and avcodec_decode_audio4() are reference-counted
@@ -1360,6 +1361,7 @@ typedef struct AVCodecContext {
*/
attribute_deprecated
int refcounted_frames;
+#endif
/* - encoding parameters */
float qcompress; ///< amount of qscale change between easy & hard scenes (0.0-1.0)
@@ -2959,6 +2961,7 @@ int avcodec_enum_to_chroma_pos(int *xpos, int *ypos, enum AVChromaLocation pos);
*/
enum AVChromaLocation avcodec_chroma_pos_to_enum(int xpos, int ypos);
+#if FF_API_OLD_ENCDEC
/**
* Decode the audio frame of size avpkt->size from avpkt->data into frame.
*
@@ -3065,6 +3068,7 @@ attribute_deprecated
int avcodec_decode_video2(AVCodecContext *avctx, AVFrame *picture,
int *got_picture_ptr,
const AVPacket *avpkt);
+#endif
/**
* Decode a subtitle message.
@@ -3602,6 +3606,7 @@ void av_parser_close(AVCodecParserContext *s);
* @{
*/
+#if FF_API_OLD_ENCDEC
/**
* Encode a frame of audio.
*
@@ -3684,6 +3689,7 @@ int avcodec_encode_audio2(AVCodecContext *avctx, AVPacket *avpkt,
attribute_deprecated
int avcodec_encode_video2(AVCodecContext *avctx, AVPacket *avpkt,
const AVFrame *frame, int *got_packet_ptr);
+#endif
int avcodec_encode_subtitle(AVCodecContext *avctx, uint8_t *buf, int buf_size,
const AVSubtitle *sub);