From: Andreas Rheinhardt <andreas.rheinha...@gmail.com> Signed-off-by: Andreas Rheinhardt <andreas.rheinha...@gmail.com> --- doc/APIchanges | 4 ++++ libavformat/avformat.h | 2 +- libavformat/utils.c | 4 ++-- 3 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/doc/APIchanges b/doc/APIchanges index a823a4419c..d19b817660 100644 --- a/doc/APIchanges +++ b/doc/APIchanges @@ -17,6 +17,10 @@ API changes, most recent first: 2021-04-17 - xxxxxxxxxx - lavu 56.73.100 - frame.h detection_bbox.h Add AV_FRAME_DATA_DETECTION_BBOXES +2021-04-14 - xxxxxxxxxx - lavf yyyyyyyyy - avformat.h + av_find_best_stream now uses a const AVCodec ** parameter + for the returned decoder. + 2021-04-14 - xxxxxxxxxx - lavc yyyyyyyyy - codec.h avcodec_find_encoder_by_name(), avcodec_find_encoder(), avcodec_find_decoder_by_name() and avcodec_find_decoder() diff --git a/libavformat/avformat.h b/libavformat/avformat.h index 23bdaa207b..28069d45dc 100644 --- a/libavformat/avformat.h +++ b/libavformat/avformat.h @@ -2070,7 +2070,7 @@ int av_find_best_stream(AVFormatContext *ic, enum AVMediaType type, int wanted_stream_nb, int related_stream, - AVCodec **decoder_ret, + const AVCodec **decoder_ret, int flags); /** diff --git a/libavformat/utils.c b/libavformat/utils.c index 7078891dc0..2f66f539a6 100644 --- a/libavformat/utils.c +++ b/libavformat/utils.c @@ -4200,7 +4200,7 @@ AVProgram *av_find_program_from_stream(AVFormatContext *ic, AVProgram *last, int int av_find_best_stream(AVFormatContext *ic, enum AVMediaType type, int wanted_stream_nb, int related_stream, - AVCodec **decoder_ret, int flags) + const AVCodec **decoder_ret, int flags) { int i, nb_streams = ic->nb_streams; int ret = AVERROR_STREAM_NOT_FOUND; @@ -4260,7 +4260,7 @@ int av_find_best_stream(AVFormatContext *ic, enum AVMediaType type, } } if (decoder_ret) - *decoder_ret = (AVCodec*)best_decoder; + *decoder_ret = best_decoder; return ret; } -- 2.31.1 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".