Re: [FFmpeg-devel] [PATCH, v3] lavc/pthread_frame: update context in child thread in multi-thread mode

2019-07-11 Thread Fu, Linjie
> -Original Message- > From: ffmpeg-devel [mailto:ffmpeg-devel-boun...@ffmpeg.org] On Behalf > Of Hendrik Leppkes > Sent: Friday, June 28, 2019 08:56 > To: FFmpeg development discussions and patches de...@ffmpeg.org> > Subject: Re: [FFmpeg-devel] [PATCH, v3] lavc/

Re: [FFmpeg-devel] [PATCH, v3] lavc/pthread_frame: update context in child thread in multi-thread mode

2019-06-27 Thread Fu, Linjie
> -Original Message- > From: ffmpeg-devel [mailto:ffmpeg-devel-boun...@ffmpeg.org] On Behalf > Of Carl Eugen Hoyos > Sent: Thursday, June 27, 2019 20:32 > To: FFmpeg development discussions and patches de...@ffmpeg.org> > Subject: Re: [FFmpeg-devel] [PATCH, v3] lavc/

Re: [FFmpeg-devel] [PATCH, v3] lavc/pthread_frame: update context in child thread in multi-thread mode

2019-06-27 Thread Hendrik Leppkes
On Thu, Jun 27, 2019 at 1:56 PM Linjie Fu wrote: > > Currently in ff_thread_decode_frame, context is updated from child thread > to user thread, and user thread releases the context in avcodec_close() > when decode finishes. > > However, when resolution/format changes, ff_get_format is called,

Re: [FFmpeg-devel] [PATCH, v3] lavc/pthread_frame: update context in child thread in multi-thread mode

2019-06-27 Thread Carl Eugen Hoyos
Am Do., 27. Juni 2019 um 13:56 Uhr schrieb Linjie Fu : > libavcodec/internal.h | 7 +++ > libavcodec/pthread_frame.c | 21 ++--- > 2 files changed, 25 insertions(+), 3 deletions(-) > > diff --git a/libavcodec/internal.h b/libavcodec/internal.h > index 5096ffa..a85

[FFmpeg-devel] [PATCH, v3] lavc/pthread_frame: update context in child thread in multi-thread mode

2019-06-27 Thread Linjie Fu
Currently in ff_thread_decode_frame, context is updated from child thread to user thread, and user thread releases the context in avcodec_close() when decode finishes. However, when resolution/format changes, ff_get_format is called, and hwaccel_uninit() and hwaccel_init will be used to destroy