summaryrefslogtreecommitdiff
path: root/src/gen75_mfc.c
diff options
context:
space:
mode:
authorZhao Yakui <yakui.zhao@intel.com>2013-05-09 13:52:31 +0800
committerYakui Zhao <yakui.zhao@intel.com>2013-05-09 13:52:31 +0800
commit3e913422baae63a92c1e2b303adae1c7dec593a6 (patch)
treece7111d6627453c39055275c6a975e0b3d3132d4 /src/gen75_mfc.c
parent2008184e0c1d50f420af8a0f53cdfc59602149cd (diff)
downloadlibva-intel-driver-3e913422baae63a92c1e2b303adae1c7dec593a6.tar.gz
libva-intel-driver-3e913422baae63a92c1e2b303adae1c7dec593a6.tar.bz2
libva-intel-driver-3e913422baae63a92c1e2b303adae1c7dec593a6.zip
Unify the AVC ref frame index setting on Snb/Ivy/HSW
This is to remove the duplicated code. Signed-off-by: Zhao Yakui <yakui.zhao@intel.com>
Diffstat (limited to 'src/gen75_mfc.c')
-rw-r--r--src/gen75_mfc.c27
1 files changed, 1 insertions, 26 deletions
diff --git a/src/gen75_mfc.c b/src/gen75_mfc.c
index c3c0e1e..fb83c13 100644
--- a/src/gen75_mfc.c
+++ b/src/gen75_mfc.c
@@ -746,31 +746,6 @@ gen75_mfc_avc_directmode_state(VADriverContextP ctx, struct intel_encoder_contex
ADVANCE_BCS_BATCH(batch);
}
-static void
-gen75_mfc_avc_ref_idx_state(VADriverContextP ctx, struct intel_encoder_context *encoder_context)
-{
- struct intel_batchbuffer *batch = encoder_context->base.batch;
- int i;
-
- BEGIN_BCS_BATCH(batch, 10);
- OUT_BCS_BATCH(batch, MFX_AVC_REF_IDX_STATE | 8);
- OUT_BCS_BATCH(batch, 0); //Select L0
- OUT_BCS_BATCH(batch, 0x80808020); //Only 1 reference
- for(i = 0; i < 7; i++) {
- OUT_BCS_BATCH(batch, 0x80808080);
- }
- ADVANCE_BCS_BATCH(batch);
-
- BEGIN_BCS_BATCH(batch, 10);
- OUT_BCS_BATCH(batch, MFX_AVC_REF_IDX_STATE | 8);
- OUT_BCS_BATCH(batch, 1); //Select L1
- OUT_BCS_BATCH(batch, 0x80808022); //Only 1 reference
- for(i = 0; i < 7; i++) {
- OUT_BCS_BATCH(batch, 0x80808080);
- }
- ADVANCE_BCS_BATCH(batch);
-}
-
static void
gen75_mfc_bsp_buf_base_addr_state_bplus(VADriverContextP ctx,
@@ -841,7 +816,7 @@ static void gen75_mfc_avc_pipeline_picture_programing( VADriverContextP ctx,
mfc_context->avc_qm_state(ctx, encoder_context);
mfc_context->avc_fqm_state(ctx, encoder_context);
gen75_mfc_avc_directmode_state(ctx, encoder_context);
- gen75_mfc_avc_ref_idx_state(ctx, encoder_context);
+ intel_mfc_avc_ref_idx_state(ctx, encoder_context);
}