diff options
author | Michael Niedermayer <michael@niedermayer.cc> | 2015-07-26 00:51:04 +0200 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2015-07-26 00:59:57 +0200 |
commit | bb619f41bea81e6ee9e208476a92fced4107a853 (patch) | |
tree | 5e23cf927a92de08b274de40a236d5ef7ea7172e /libavcodec | |
parent | 9f4bff834c47d2093ae35215c4aafa92c29d9d79 (diff) | |
parent | bf52f773913cf74bdf0d2c8c2cb4473fa1b7801e (diff) | |
download | ffmpeg-bb619f41bea81e6ee9e208476a92fced4107a853.tar.gz |
Merge commit 'bf52f773913cf74bdf0d2c8c2cb4473fa1b7801e'
* commit 'bf52f773913cf74bdf0d2c8c2cb4473fa1b7801e':
lavc: add Intel libmfx-based MPEG2 decoder.
Conflicts:
configure
libavcodec/qsvdec_mpeg2.c
Some cosmetics merged, rest is related to the removed parser code and
thus not merged
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/Makefile | 2 | ||||
-rw-r--r-- | libavcodec/allcodecs.c | 2 | ||||
-rw-r--r-- | libavcodec/qsvdec_mpeg2.c | 12 |
3 files changed, 8 insertions, 8 deletions
diff --git a/libavcodec/Makefile b/libavcodec/Makefile index 871155768d..cbdf139713 100644 --- a/libavcodec/Makefile +++ b/libavcodec/Makefile @@ -363,8 +363,8 @@ OBJS-$(CONFIG_MPEG1VIDEO_DECODER) += mpeg12dec.o mpeg12.o mpeg12data.o OBJS-$(CONFIG_MPEG1VIDEO_ENCODER) += mpeg12enc.o mpeg12.o OBJS-$(CONFIG_MPEG2VIDEO_DECODER) += mpeg12dec.o mpeg12.o mpeg12data.o OBJS-$(CONFIG_MPEG2VIDEO_ENCODER) += mpeg12enc.o mpeg12.o -OBJS-$(CONFIG_MPEG2_QSV_ENCODER) += qsvenc_mpeg2.o OBJS-$(CONFIG_MPEG2_QSV_DECODER) += qsvdec_mpeg2.o +OBJS-$(CONFIG_MPEG2_QSV_ENCODER) += qsvenc_mpeg2.o OBJS-$(CONFIG_MPEG4_DECODER) += xvididct.o OBJS-$(CONFIG_MPL2_DECODER) += mpl2dec.o ass.o OBJS-$(CONFIG_MSMPEG4V1_DECODER) += msmpeg4dec.o msmpeg4.o msmpeg4data.o diff --git a/libavcodec/allcodecs.c b/libavcodec/allcodecs.c index 808e3b72b7..d4831e400c 100644 --- a/libavcodec/allcodecs.c +++ b/libavcodec/allcodecs.c @@ -92,9 +92,9 @@ void avcodec_register_all(void) REGISTER_HWACCEL(MPEG2_XVMC, mpeg2_xvmc); REGISTER_HWACCEL(MPEG2_D3D11VA, mpeg2_d3d11va); REGISTER_HWACCEL(MPEG2_DXVA2, mpeg2_dxva2); + REGISTER_HWACCEL(MPEG2_QSV, mpeg2_qsv); REGISTER_HWACCEL(MPEG2_VAAPI, mpeg2_vaapi); REGISTER_HWACCEL(MPEG2_VDPAU, mpeg2_vdpau); - REGISTER_HWACCEL(MPEG2_QSV, mpeg2_qsv); REGISTER_HWACCEL(MPEG4_VAAPI, mpeg4_vaapi); REGISTER_HWACCEL(MPEG4_VDPAU, mpeg4_vdpau); REGISTER_HWACCEL(VC1_D3D11VA, vc1_d3d11va); diff --git a/libavcodec/qsvdec_mpeg2.c b/libavcodec/qsvdec_mpeg2.c index e920da7190..2764a209bb 100644 --- a/libavcodec/qsvdec_mpeg2.c +++ b/libavcodec/qsvdec_mpeg2.c @@ -27,14 +27,14 @@ #include "avcodec.h" #include "qsvdec.h" -typedef struct QSVMPVContext { +typedef struct QSVMPEG2Context { AVClass *class; QSVContext qsv; -} QSVMPVContext; +} QSVMPEG2Context; static av_cold int qsv_decode_close(AVCodecContext *avctx) { - QSVMPVContext *s = avctx->priv_data; + QSVMPEG2Context *s = avctx->priv_data; ff_qsv_decode_close(&s->qsv); @@ -49,7 +49,7 @@ static av_cold int qsv_decode_init(AVCodecContext *avctx) static int qsv_decode_frame(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt) { - QSVMPVContext *s = avctx->priv_data; + QSVMPEG2Context *s = avctx->priv_data; AVFrame *frame = data; return ff_qsv_decode(avctx, &s->qsv, frame, got_frame, avpkt); @@ -66,7 +66,7 @@ AVHWAccel ff_mpeg2_qsv_hwaccel = { .pix_fmt = AV_PIX_FMT_QSV, }; -#define OFFSET(x) offsetof(QSVMPVContext, x) +#define OFFSET(x) offsetof(QSVMPEG2Context, x) #define VD AV_OPT_FLAG_VIDEO_PARAM | AV_OPT_FLAG_DECODING_PARAM static const AVOption options[] = { { "async_depth", "Internal parallelization depth, the higher the value the higher the latency.", OFFSET(qsv.async_depth), AV_OPT_TYPE_INT, { .i64 = ASYNC_DEPTH_DEFAULT }, 0, INT_MAX, VD }, @@ -83,7 +83,7 @@ static const AVClass class = { AVCodec ff_mpeg2_qsv_decoder = { .name = "mpeg2_qsv", .long_name = NULL_IF_CONFIG_SMALL("MPEG-2 video (Intel Quick Sync Video acceleration)"), - .priv_data_size = sizeof(QSVMPVContext), + .priv_data_size = sizeof(QSVMPEG2Context), .type = AVMEDIA_TYPE_VIDEO, .id = AV_CODEC_ID_MPEG2VIDEO, .init = qsv_decode_init, |