diff options
author | Li Xiaowei <xiaowei.a.li@intel.com> | 2013-01-28 13:22:09 +0800 |
---|---|---|
committer | Xiang, Haihao <haihao.xiang@intel.com> | 2013-01-30 16:06:41 +0800 |
commit | 8bab2d909dc11a9044d8049f334cc60d23c0ee61 (patch) | |
tree | 8e60594bd18a4511643a364fe80069b042e60f1b | |
parent | b7cb38772e6f73d3c1b3465e0bc6c0009c2f5634 (diff) | |
download | vaapi-intel-driver-8bab2d909dc11a9044d8049f334cc60d23c0ee61.tar.gz vaapi-intel-driver-8bab2d909dc11a9044d8049f334cc60d23c0ee61.tar.bz2 vaapi-intel-driver-8bab2d909dc11a9044d8049f334cc60d23c0ee61.zip |
Correct the mv offset for mpeg2 encoding on HSW
Signed-off-by: Li Xiaowei <xiaowei.a.li@intel.com>
-rw-r--r-- | src/gen75_mfc.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/gen75_mfc.c b/src/gen75_mfc.c index 6262043..e7a3221 100644 --- a/src/gen75_mfc.c +++ b/src/gen75_mfc.c @@ -2067,11 +2067,11 @@ gen75_mfc_mpeg2_pak_object_inter(VADriverContextP ctx, if (batch == NULL) batch = encoder_context->base.batch; - mvptr = (short *)msg; - mvx0 = mpeg2_motion_vector(mvptr[MPEG2_INTER_MV_OFFSET + 0] / 2, x, width_in_mbs * 16, pic_param->f_code[0][0]); - mvy0 = mpeg2_motion_vector(mvptr[MPEG2_INTER_MV_OFFSET + 1] / 2, y, height_in_mbs * 16, pic_param->f_code[0][0]); - mvx1 = mpeg2_motion_vector(mvptr[MPEG2_INTER_MV_OFFSET + 2] / 2, x, width_in_mbs * 16, pic_param->f_code[1][0]); - mvy1 = mpeg2_motion_vector(mvptr[MPEG2_INTER_MV_OFFSET + 3] / 2, y, height_in_mbs * 16, pic_param->f_code[1][0]); + mvptr = (short *)(msg + MPEG2_INTER_MV_OFFSET); + mvx0 = mpeg2_motion_vector(mvptr[0] / 2, x, width_in_mbs * 16, pic_param->f_code[0][0]); + mvy0 = mpeg2_motion_vector(mvptr[1] / 2, y, height_in_mbs * 16, pic_param->f_code[0][0]); + mvx1 = mpeg2_motion_vector(mvptr[2] / 2, x, width_in_mbs * 16, pic_param->f_code[1][0]); + mvy1 = mpeg2_motion_vector(mvptr[3] / 2, y, height_in_mbs * 16, pic_param->f_code[1][0]); BEGIN_BCS_BATCH(batch, len_in_dwords); |