From 33614ae6df63890f98ee6daa1bb901543b0a5f23 Mon Sep 17 00:00:00 2001 From: Matt Oliver Date: Sat, 26 Oct 2024 21:43:48 +1100 Subject: [PATCH] fftools: Fix linking with libbluray. --- fftools/ffmpeg.h | 2 +- fftools/ffmpeg_dec.c | 10 +++++----- fftools/ffmpeg_demux.c | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/fftools/ffmpeg.h b/fftools/ffmpeg.h index 6394cca1e77bc..e31aaec19b6c9 100644 --- a/fftools/ffmpeg.h +++ b/fftools/ffmpeg.h @@ -749,7 +749,7 @@ int dec_create(const OptionsContext *o, const char *arg, Scheduler *sch); * @retval ">=0" non-negative scheduler index on success * @retval "<0" an error code on failure */ -int dec_init(Decoder **pdec, Scheduler *sch, +int dec_open(Decoder **pdec, Scheduler *sch, AVDictionary **dec_opts, const DecoderOpts *o, AVFrame *param_out); void dec_free(Decoder **pdec); diff --git a/fftools/ffmpeg_dec.c b/fftools/ffmpeg_dec.c index ed411b6bf8760..85367969c0ea8 100644 --- a/fftools/ffmpeg_dec.c +++ b/fftools/ffmpeg_dec.c @@ -765,7 +765,7 @@ static int packet_decode(DecoderPriv *dp, AVPacket *pkt, AVFrame *frame) } } -static int dec_open(DecoderPriv *dp, AVDictionary **dec_opts, +static int dec_open2(DecoderPriv *dp, AVDictionary **dec_opts, const DecoderOpts *o, AVFrame *param_out); static int dec_standalone_open(DecoderPriv *dp, const AVPacket *pkt) @@ -800,7 +800,7 @@ static int dec_standalone_open(DecoderPriv *dp, const AVPacket *pkt) snprintf(name, sizeof(name), "dec%d", dp->index); o.name = name; - return dec_open(dp, &dp->standalone_init.opts, &o, NULL); + return dec_open2(dp, &dp->standalone_init.opts, &o, NULL); } static void dec_thread_set_name(const DecoderPriv *dp) @@ -1138,7 +1138,7 @@ static int hw_device_setup_for_decode(DecoderPriv *dp, return 0; } -static int dec_open(DecoderPriv *dp, AVDictionary **dec_opts, +static int dec_open2(DecoderPriv *dp, AVDictionary **dec_opts, const DecoderOpts *o, AVFrame *param_out) { const AVCodec *codec = o->codec; @@ -1250,7 +1250,7 @@ static int dec_open(DecoderPriv *dp, AVDictionary **dec_opts, return 0; } -int dec_init(Decoder **pdec, Scheduler *sch, +int dec_open(Decoder **pdec, Scheduler *sch, AVDictionary **dec_opts, const DecoderOpts *o, AVFrame *param_out) { @@ -1263,7 +1263,7 @@ int dec_init(Decoder **pdec, Scheduler *sch, if (ret < 0) return ret; - ret = dec_open(dp, dec_opts, o, param_out); + ret = dec_open2(dp, dec_opts, o, param_out); if (ret < 0) goto fail; diff --git a/fftools/ffmpeg_demux.c b/fftools/ffmpeg_demux.c index 47312c9fe123e..7ea59e91904ea 100644 --- a/fftools/ffmpeg_demux.c +++ b/fftools/ffmpeg_demux.c @@ -943,7 +943,7 @@ static int ist_use(InputStream *ist, int decoding_needed) if (!ds->decoded_params) return AVERROR(ENOMEM); - ret = dec_init(&ist->decoder, d->sch, + ret = dec_open(&ist->decoder, d->sch, &ds->decoder_opts, &ds->dec_opts, ds->decoded_params); if (ret < 0) return ret;