]> git.sesse.net Git - vlc/commitdiff
avcodec: hw accel with frame multithreading works since libavcodec 55.01.00
authorJanne Grunau <janne-vlc@jannau.net>
Wed, 27 Mar 2013 16:05:44 +0000 (17:05 +0100)
committerJean-Baptiste Kempf <jb@videolan.org>
Wed, 27 Mar 2013 17:03:37 +0000 (18:03 +0100)
This is mostly useful if the hw accelerator cannot handle the stream.
The software decoder fallback will then use frame multithreading if it
supports it.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
modules/codec/avcodec/video.c

index d8ce8a2b953c626afcf5d890d07e4d79c03ee262..2b87f35c71724e0c7707c128d461c20fc3f6c4d9 100644 (file)
@@ -341,7 +341,7 @@ int InitVideoDec( decoder_t *p_dec, AVCodecContext *p_context,
          i_codec_id == AV_CODEC_ID_H264 ||
          i_codec_id == AV_CODEC_ID_VC1 || i_codec_id == AV_CODEC_ID_WMV3) )
     {
-#ifdef HAVE_AVCODEC_MT
+#if defined(HAVE_AVCODEC_MT) && LIBAVCODEC_VERSION_INT < AV_VERSION_INT(55, 1, 0)
         if( p_sys->p_context->thread_type & FF_THREAD_FRAME )
         {
             msg_Warn( p_dec, "threaded frame decoding is not compatible with libavcodec-hw, disabled" );