Commit ab36432e authored by Laurent Aimar's avatar Laurent Aimar Committed by Jean-Baptiste Kempf

Set decoder_t::i_extra_picture_buffers in avcodec decoder.

It should fix #5753.
There can still be an issue with an insufficient input caching.
(cherry picked from commit 5539fea75b47b3c8c68c2f5e8a268904f4c019ff)
Signed-off-by: default avatarJean-Baptiste Kempf <jb@videolan.org>
parent fe74f928
......@@ -359,6 +359,11 @@ int InitVideoDec( decoder_t *p_dec, AVCodecContext *p_context,
p_sys->p_context->get_format = ffmpeg_GetFormat;
}
#endif
#ifdef HAVE_AVCODEC_MT
if( p_sys->p_context->thread_type & FF_THREAD_FRAME )
p_dec->i_extra_picture_buffers = 2 * p_sys->p_context->thread_count;
#endif
/* ***** misc init ***** */
p_sys->i_pts = VLC_TS_INVALID;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment