diff options
author | Jan Ekström <jeebjp@gmail.com> | 2023-03-14 23:31:52 +0200 |
---|---|---|
committer | Jan Ekström <jeebjp@gmail.com> | 2023-03-14 23:59:47 +0200 |
commit | 1313f287e5508ddee514ef5242339cd5edb1bf9b (patch) | |
tree | 27d9929f85e4bebbbb3a2dee5bbf643d973b18d7 /common | |
parent | 9f5d7d59328bc6d73d06fe67431a3d4ad4ffc2ac (diff) | |
download | mpv-1313f287e5508ddee514ef5242339cd5edb1bf9b.tar.bz2 mpv-1313f287e5508ddee514ef5242339cd5edb1bf9b.tar.xz |
common/av_common: clean up mp_lavc_set_extradata
It no longer has any users, as the last ones (subtitle decoders)
were switched to mp_set_avctx_codec_headers.
Diffstat (limited to 'common')
-rw-r--r-- | common/av_common.c | 14 | ||||
-rw-r--r-- | common/av_common.h | 1 |
2 files changed, 0 insertions, 15 deletions
diff --git a/common/av_common.c b/common/av_common.c index 89a647593f..5d07349af0 100644 --- a/common/av_common.c +++ b/common/av_common.c @@ -40,20 +40,6 @@ #include "av_common.h" #include "codecs.h" -int mp_lavc_set_extradata(AVCodecContext *avctx, void *ptr, int size) -{ - if (size) { - av_free(avctx->extradata); - avctx->extradata_size = 0; - avctx->extradata = av_mallocz(size + AV_INPUT_BUFFER_PADDING_SIZE); - if (!avctx->extradata) - return -1; - avctx->extradata_size = size; - memcpy(avctx->extradata, ptr, size); - } - return 0; -} - enum AVMediaType mp_to_av_stream_type(int type) { switch (type) { diff --git a/common/av_common.h b/common/av_common.h index 2c97ad19cc..1f05e14fab 100644 --- a/common/av_common.h +++ b/common/av_common.h @@ -31,7 +31,6 @@ struct mp_codec_params; struct AVDictionary; struct mp_log; -int mp_lavc_set_extradata(AVCodecContext *avctx, void *ptr, int size); enum AVMediaType mp_to_av_stream_type(int type); AVCodecParameters *mp_codec_params_to_av(const struct mp_codec_params *c); int mp_set_avctx_codec_headers(AVCodecContext *avctx, const struct mp_codec_params *c); |