summaryrefslogtreecommitdiff
path: root/libavcodec/mpeg12dec.c
diff options
context:
space:
mode:
authorLuca Barbato <lu_zero@gentoo.org>2013-11-09 17:07:34 +0100
committerLuca Barbato <lu_zero@gentoo.org>2013-11-10 13:59:48 +0100
commit08303d774132775d49d4ba767092de5d426f089d (patch)
tree09339c4a5d2ddd495a75a7d6eea1b101066b2069 /libavcodec/mpeg12dec.c
parentd42db44cfe58493eb26d2d2f307ced4dd4ca1978 (diff)
hwaccel: Simplify ff_find_hwaccel
It is always called by passing fields from an AVCodecContext.
Diffstat (limited to 'libavcodec/mpeg12dec.c')
-rw-r--r--libavcodec/mpeg12dec.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/mpeg12dec.c b/libavcodec/mpeg12dec.c
index 53d1e0e400..1713cfb0af 100644
--- a/libavcodec/mpeg12dec.c
+++ b/libavcodec/mpeg12dec.c
@@ -1227,7 +1227,7 @@ static int mpeg_decode_postinit(AVCodecContext *avctx)
} // MPEG-2
avctx->pix_fmt = mpeg_get_pixelformat(avctx);
- avctx->hwaccel = ff_find_hwaccel(avctx->codec->id, avctx->pix_fmt);
+ avctx->hwaccel = ff_find_hwaccel(avctx);
// until then pix_fmt may be changed right after codec init
if (avctx->pix_fmt == AV_PIX_FMT_XVMC_MPEG2_IDCT ||
avctx->hwaccel)
@@ -1988,7 +1988,7 @@ static int vcr2_init_sequence(AVCodecContext *avctx)
s->low_delay = 1;
avctx->pix_fmt = mpeg_get_pixelformat(avctx);
- avctx->hwaccel = ff_find_hwaccel(avctx->codec->id, avctx->pix_fmt);
+ avctx->hwaccel = ff_find_hwaccel(avctx);
if (avctx->pix_fmt == AV_PIX_FMT_XVMC_MPEG2_IDCT || avctx->hwaccel)
if (avctx->idct_algo == FF_IDCT_AUTO)