diff options
author | Zhao Yakui <yakui.zhao@intel.com> | 2013-05-09 13:52:31 +0800 |
---|---|---|
committer | Yakui Zhao <yakui.zhao@intel.com> | 2013-05-09 13:52:31 +0800 |
commit | 3e913422baae63a92c1e2b303adae1c7dec593a6 (patch) | |
tree | ce7111d6627453c39055275c6a975e0b3d3132d4 /src/gen6_mfc.c | |
parent | 2008184e0c1d50f420af8a0f53cdfc59602149cd (diff) | |
download | libva-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/gen6_mfc.c')
-rw-r--r-- | src/gen6_mfc.c | 27 |
1 files changed, 1 insertions, 26 deletions
diff --git a/src/gen6_mfc.c b/src/gen6_mfc.c index 81136ad..8515253 100644 --- a/src/gen6_mfc.c +++ b/src/gen6_mfc.c @@ -482,31 +482,6 @@ static void gen6_mfc_avc_fqm_state(VADriverContextP ctx, struct intel_encoder_co } static void -gen6_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 gen6_mfc_avc_insert_object(VADriverContextP ctx, struct intel_encoder_context *encoder_context, unsigned int *insert_data, int lenght_in_dws, int data_bits_in_last_dw, int skip_emul_byte_count, int is_last_header, int is_end_of_slice, int emulation_flag, @@ -636,7 +611,7 @@ static void gen6_mfc_avc_pipeline_picture_programing( VADriverContextP ctx, mfc_context->avc_qm_state(ctx, encoder_context); mfc_context->avc_fqm_state(ctx, encoder_context); gen6_mfc_avc_directmode_state(ctx, encoder_context); - gen6_mfc_avc_ref_idx_state(ctx, encoder_context); + intel_mfc_avc_ref_idx_state(ctx, encoder_context); } |