From 39630dc8b6c2241df9e0e6066e1bd858b864f7de Mon Sep 17 00:00:00 2001 From: sfan5 Date: Sat, 1 May 2021 21:53:56 +0200 Subject: build: address AVCodec, AVInputFormat, AVOutputFormat const warnings FFmpeg recently changed these to be const on their side. --- audio/decode/ad_lavc.c | 2 +- audio/decode/ad_spdif.c | 2 +- audio/filter/af_lavcac3enc.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'audio') diff --git a/audio/decode/ad_lavc.c b/audio/decode/ad_lavc.c index eaaf0729e9..228054e8d6 100644 --- a/audio/decode/ad_lavc.c +++ b/audio/decode/ad_lavc.c @@ -85,7 +85,7 @@ static bool init(struct mp_filter *da, struct mp_codec_params *codec, struct ad_lavc_params *opts = mp_get_config_group(ctx, da->global, &ad_lavc_conf); AVCodecContext *lavc_context; - AVCodec *lavc_codec; + const AVCodec *lavc_codec; ctx->codec_timebase = mp_get_codec_timebase(codec); diff --git a/audio/decode/ad_spdif.c b/audio/decode/ad_spdif.c index 0b1977769a..520803c4b0 100644 --- a/audio/decode/ad_spdif.c +++ b/audio/decode/ad_spdif.c @@ -116,7 +116,7 @@ static void determine_codec_params(struct mp_filter *da, AVPacket *pkt, if (profile != FF_PROFILE_UNKNOWN || spdif_ctx->codec_id != AV_CODEC_ID_DTS) return; - AVCodec *codec = avcodec_find_decoder(spdif_ctx->codec_id); + const AVCodec *codec = avcodec_find_decoder(spdif_ctx->codec_id); if (!codec) goto done; diff --git a/audio/filter/af_lavcac3enc.c b/audio/filter/af_lavcac3enc.c index 38f93a1c08..45e0aa64a2 100644 --- a/audio/filter/af_lavcac3enc.c +++ b/audio/filter/af_lavcac3enc.c @@ -68,7 +68,7 @@ struct priv { struct mp_aframe *in_frame; struct mp_aframe_pool *out_pool; - struct AVCodec *lavc_acodec; + const struct AVCodec *lavc_acodec; struct AVCodecContext *lavc_actx; int bit_rate; int out_samples; // upper bound on encoded output per AC3 frame -- cgit v1.2.3