diff mpeg12.c @ 9033:bcf716c58be4 libavcodec

add ff_find_hwaccel() by Gwenole Beauchesne
author michael
date Tue, 24 Feb 2009 19:04:43 +0000
parents 90c99bda19f5
children 8e5fe9e56b93
line wrap: on
line diff
--- a/mpeg12.c	Tue Feb 24 18:51:16 2009 +0000
+++ b/mpeg12.c	Tue Feb 24 19:04:43 2009 +0000
@@ -1302,6 +1302,7 @@
         }//MPEG-2
 
         avctx->pix_fmt = mpeg_get_pixelformat(avctx);
+        avctx->hwaccel = ff_find_hwaccel(avctx->codec->id, avctx->pix_fmt);
         //until then pix_fmt may be changed right after codec init
         if( avctx->pix_fmt == PIX_FMT_XVMC_MPEG2_IDCT ||
             avctx->hwaccel ||
@@ -2071,6 +2072,7 @@
     s->low_delay= 1;
 
     avctx->pix_fmt = mpeg_get_pixelformat(avctx);
+    avctx->hwaccel = ff_find_hwaccel(avctx->codec->id, avctx->pix_fmt);
 
     if( avctx->pix_fmt == PIX_FMT_XVMC_MPEG2_IDCT ||
         s->avctx->codec->capabilities&CODEC_CAP_HWACCEL_VDPAU )