diff options
author | Zhao, Yakui <yakui.zhao@intel.com> | 2014-05-26 08:40:15 +0800 |
---|---|---|
committer | Xiang, Haihao <haihao.xiang@intel.com> | 2014-06-16 11:53:35 +0800 |
commit | 89507c06c7ed03d829cf2526e621d844e174c90c (patch) | |
tree | 52816c0e5a076d7bae585a4ab8c54439d41e999f /src/gen8_mfc.c | |
parent | 558e904bc5c471795b09f6c2dcf65ba31590b19b (diff) | |
download | libva-intel-driver-89507c06c7ed03d829cf2526e621d844e174c90c.tar.gz libva-intel-driver-89507c06c7ed03d829cf2526e621d844e174c90c.tar.bz2 libva-intel-driver-89507c06c7ed03d829cf2526e621d844e174c90c.zip |
H264_encoding: Add the support of inserting the packed raw data passed from user
Under some encoding scenario, the user-space application hopes that the driver
can insert the passed packed rawdata into the coded clip. This is to allow the
insertion of packed rawdata passed from user. As the position of packed rawdata
is related with the slice. So the following restrictions are added:
1. the packed rawdata header type/data should be paired.
2. the packed rawdata data is inserted by following the passed order
3. the packed rawdata header type/data is split by using VAEncSliceParameterBuffer.
That is to say: The packed rawdata for slice 0 should be passed before the first
VAEncSliceParameterBuffer. After one VAEncSliceParameterBuffer is parsed,
the subseuquent packed rawdata is for another new slice. The subsequent
packed rawdata after the last VAEncSliceParameterBuffer is ignored.
4. it does not change the rule for the packed data of SPS/PPS/MISC type.
Signed-off-by: Zhao Yakui <yakui.zhao@intel.com>
(cherry picked from commit 974597ef64dc9a283d4787e1484a75d1610414f4)
Conflicts:
src/gen75_mfc.c
src/gen8_mfc.c
Diffstat (limited to 'src/gen8_mfc.c')
-rw-r--r-- | src/gen8_mfc.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/gen8_mfc.c b/src/gen8_mfc.c index df99603..2fc1fac 100644 --- a/src/gen8_mfc.c +++ b/src/gen8_mfc.c @@ -1056,6 +1056,8 @@ gen8_mfc_avc_pipeline_slice_programing(VADriverContextP ctx, if ( slice_index == 0) intel_mfc_avc_pipeline_header_programing(ctx, encode_state, encoder_context, slice_batch); + intel_avc_slice_insert_packed_data(ctx, encode_state, encoder_context, slice_index, slice_batch); + slice_header_length_in_bits = build_avc_slice_header(pSequenceParameter, pPicParameter, pSliceParameter, &slice_header); // slice hander @@ -1110,8 +1112,6 @@ gen8_mfc_avc_pipeline_slice_programing(VADriverContextP ctx, tail_data, 1, 8, 1, 1, 1, 0, slice_batch); } - - } static dri_bo * @@ -1441,6 +1441,8 @@ gen8_mfc_avc_batchbuffer_slice(VADriverContextP ctx, if (slice_index == 0) intel_mfc_avc_pipeline_header_programing(ctx, encode_state, encoder_context, slice_batch); + intel_avc_slice_insert_packed_data(ctx, encode_state, encoder_context, slice_index, slice_batch); + slice_header_length_in_bits = build_avc_slice_header(pSequenceParameter, pPicParameter, pSliceParameter, &slice_header); // slice hander |