summaryrefslogtreecommitdiff
path: root/src/gen75_mfc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gen75_mfc.c')
-rw-r--r--src/gen75_mfc.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/gen75_mfc.c b/src/gen75_mfc.c
index 1051dd5..2ff35af 100644
--- a/src/gen75_mfc.c
+++ b/src/gen75_mfc.c
@@ -1172,7 +1172,8 @@ gen75_mfc_avc_pipeline_slice_programing(VADriverContextP ctx,
if (rate_control_mode == VA_RC_CBR) {
qp = mfc_context->bit_rate_control_context[slice_type].QpPrimeY;
- pSliceParameter->slice_qp_delta = qp - pPicParameter->pic_init_qp;
+ if (encode_state->slice_header_index[slice_index] == 0)
+ pSliceParameter->slice_qp_delta = qp - pPicParameter->pic_init_qp;
}
/* only support for 8-bit pixel bit-depth */
@@ -1510,7 +1511,8 @@ gen75_mfc_avc_batchbuffer_slice(VADriverContextP ctx,
if (rate_control_mode == VA_RC_CBR) {
qp = mfc_context->bit_rate_control_context[slice_type].QpPrimeY;
- pSliceParameter->slice_qp_delta = qp - pPicParameter->pic_init_qp;
+ if (encode_state->slice_header_index[slice_index] == 0)
+ pSliceParameter->slice_qp_delta = qp - pPicParameter->pic_init_qp;
}
/* only support for 8-bit pixel bit-depth */