Message ID | CAB0OVGrxOJVwXQ0HCL0d07xbyX_UUCDZrmesQ_B0OvW58Kp3=A@mail.gmail.com |
---|---|
State | Superseded |
Headers | show |
On 8/25/2019 1:27 PM, Carl Eugen Hoyos wrote: > Hi! > > Attached patch should fix ticket #7542. > > Please comment, Carl Eugen > > > 0001-lavfi-movie-Use-filter-thread-count-for-decoding-thr.patch > > From 21f3c281dbd9d97ac47ed611958a85881c4b7fba Mon Sep 17 00:00:00 2001 > From: Carl Eugen Hoyos <ceffmpeg@gmail.com> > Date: Sun, 25 Aug 2019 18:12:30 +0200 > Subject: [PATCH] lavfi/movie: Use filter thread count for decoding threads. > > Fixes ticket #7542. > --- > libavfilter/src_movie.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/libavfilter/src_movie.c b/libavfilter/src_movie.c > index bcabfcc4c2..78c73e78a4 100644 > --- a/libavfilter/src_movie.c > +++ b/libavfilter/src_movie.c > @@ -153,7 +153,7 @@ static AVStream *find_stream(void *log, AVFormatContext *avf, const char *spec) > return found; > } > > -static int open_stream(void *log, MovieStream *st) > +static int open_stream(AVFilterContext *ctx, MovieStream *st) log is now undeclared. Or rather, it still is for some reason (i guess the function parameter overloaded some global declaration), just not pointing to what you wanted it to. > { > AVCodec *codec; > int ret; > @@ -173,6 +173,7 @@ static int open_stream(void *log, MovieStream *st) > return ret; > > st->codec_ctx->refcounted_frames = 1; > + st->codec_ctx->thread_count = ff_filter_get_nb_threads(ctx); > > if ((ret = avcodec_open2(st->codec_ctx, codec, NULL)) < 0) { > av_log(log, AV_LOG_ERROR, "Failed to open codec\n"); > -- 2.22.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-request@ffmpeg.org with subject "unsubscribe". >
From 21f3c281dbd9d97ac47ed611958a85881c4b7fba Mon Sep 17 00:00:00 2001 From: Carl Eugen Hoyos <ceffmpeg@gmail.com> Date: Sun, 25 Aug 2019 18:12:30 +0200 Subject: [PATCH] lavfi/movie: Use filter thread count for decoding threads. Fixes ticket #7542. --- libavfilter/src_movie.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libavfilter/src_movie.c b/libavfilter/src_movie.c index bcabfcc4c2..78c73e78a4 100644 --- a/libavfilter/src_movie.c +++ b/libavfilter/src_movie.c @@ -153,7 +153,7 @@ static AVStream *find_stream(void *log, AVFormatContext *avf, const char *spec) return found; } -static int open_stream(void *log, MovieStream *st) +static int open_stream(AVFilterContext *ctx, MovieStream *st) { AVCodec *codec; int ret; @@ -173,6 +173,7 @@ static int open_stream(void *log, MovieStream *st) return ret; st->codec_ctx->refcounted_frames = 1; + st->codec_ctx->thread_count = ff_filter_get_nb_threads(ctx); if ((ret = avcodec_open2(st->codec_ctx, codec, NULL)) < 0) { av_log(log, AV_LOG_ERROR, "Failed to open codec\n"); -- 2.22.1