mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-02 16:38:09 +02:00
pipe/video: Remove st_rps_bits and UseStRpsBits
Reviewed-By: Sil Vilerino <sivileri@microsoft.com> Reviewed-by: Ruijing Dong <ruijing.dong@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34836>
This commit is contained in:
parent
7d55b510e8
commit
4fca9d9699
6 changed files with 4 additions and 11 deletions
|
|
@ -416,7 +416,7 @@ d3d12_video_decoder_dxva_picparams_from_pipe_picparams_hevc(
|
|||
// NumDeltaPocsOfRefRpsIdx is not passed from VA to pipe, and VA doesn't have it defined in their va_dec_hevc header.
|
||||
// DXVA drivers should use wNumBitsForShortTermRPSInSlice (st_rps_bits in VA) to derive the slice header info instead
|
||||
dxvaStructure.ucNumDeltaPocsOfRefRpsIdx = static_cast<uint8_t>(pPipeDesc->NumDeltaPocsOfRefRpsIdx);
|
||||
dxvaStructure.wNumBitsForShortTermRPSInSlice = pps->st_rps_bits;
|
||||
dxvaStructure.wNumBitsForShortTermRPSInSlice = static_cast<uint16_t>(pPipeDesc->NumShortTermPictureSliceHeaderBits);
|
||||
|
||||
dxvaStructure.scaling_list_enabled_flag = sps->scaling_list_enabled_flag;
|
||||
dxvaStructure.amp_enabled_flag = sps->amp_enabled_flag;
|
||||
|
|
|
|||
|
|
@ -261,9 +261,9 @@ static rvcn_dec_message_hevc_t get_h265_msg(struct radeon_decoder *dec,
|
|||
result.sps_info_flags |= pic->pps->sps->separate_colour_plane_flag << 8;
|
||||
if (((struct si_screen *)dec->screen)->info.family == CHIP_CARRIZO)
|
||||
result.sps_info_flags |= 1 << 9;
|
||||
if (pic->UseStRpsBits == true && pic->pps->st_rps_bits != 0) {
|
||||
if (pic->NumShortTermPictureSliceHeaderBits != 0) {
|
||||
result.sps_info_flags |= 1 << 11;
|
||||
result.st_rps_bits = pic->pps->st_rps_bits;
|
||||
result.st_rps_bits = pic->NumShortTermPictureSliceHeaderBits;
|
||||
}
|
||||
|
||||
result.chroma_format = pic->pps->sps->chroma_format_idc;
|
||||
|
|
|
|||
|
|
@ -377,7 +377,6 @@ static int fill_h265_picture_desc(const struct pipe_picture_desc *desc,
|
|||
ITEM_SET(&vh265->pps, h265->pps, lists_modification_present_flag);
|
||||
ITEM_SET(&vh265->pps, h265->pps, log2_parallel_merge_level_minus2);
|
||||
ITEM_SET(&vh265->pps, h265->pps, slice_segment_header_extension_present_flag);
|
||||
ITEM_SET(&vh265->pps, h265->pps, st_rps_bits);
|
||||
|
||||
ITEM_SET(vh265, h265, IDRPicFlag);
|
||||
ITEM_SET(vh265, h265, RAPPicFlag);
|
||||
|
|
@ -401,7 +400,6 @@ static int fill_h265_picture_desc(const struct pipe_picture_desc *desc,
|
|||
ITEM_CPY(vh265, h265, RefPicSetStCurrAfter);
|
||||
ITEM_CPY(vh265, h265, RefPicSetLtCurr);
|
||||
ITEM_CPY(vh265, h265, RefPicList);
|
||||
ITEM_SET(vh265, h265, UseStRpsBits);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -213,9 +213,7 @@ void vlVaHandlePictureParameterBufferHEVC(vlVaDriver *drv, vlVaContext *context,
|
|||
vlVaSortRefPicSet(context, context->desc.h265.RefPicSetStCurrAfter, context->desc.h265.NumPocStCurrAfter, true);
|
||||
context->desc.h265.LtCurrDone = context->desc.h265.NumPocLtCurr < 2;
|
||||
|
||||
context->desc.h265.pps->st_rps_bits = hevc->st_rps_bits;
|
||||
context->desc.h265.NumShortTermPictureSliceHeaderBits = hevc->st_rps_bits;
|
||||
context->desc.h265.UseStRpsBits = true;
|
||||
|
||||
context->desc.h265.slice_parameter.slice_count = 0;
|
||||
context->desc.h265.slice_parameter.slice_info_present = false;
|
||||
|
|
@ -374,7 +372,7 @@ void vlVaDecoderHEVCBitstreamHeader(vlVaContext *context, vlVaBuffer *buf)
|
|||
if (nal_unit_type != PIPE_H265_NAL_IDR_W_RADL && nal_unit_type != PIPE_H265_NAL_IDR_N_LP) {
|
||||
vl_rbsp_u(&rbsp, sps->log2_max_pic_order_cnt_lsb_minus4 + 4); /* slice_pic_order_cnt_lsb */
|
||||
if (!vl_rbsp_u(&rbsp, 1)) { /* short_term_ref_pic_set_sps_flag */
|
||||
for (uint8_t i = 0; i < pps->st_rps_bits; i++)
|
||||
for (unsigned i = 0; i < pic->NumShortTermPictureSliceHeaderBits; i++)
|
||||
vl_rbsp_u(&rbsp, 1);
|
||||
} else if (sps->num_short_term_ref_pic_sets > 1) {
|
||||
vl_rbsp_u(&rbsp, util_logbase2_ceil(sps->num_short_term_ref_pic_sets)); /* short_term_ref_pic_set_idx */
|
||||
|
|
|
|||
|
|
@ -527,7 +527,6 @@ vlVdpDecoderRenderH265(struct pipe_h265_picture_desc *picture,
|
|||
memcpy(picture->RefPicSetStCurrBefore, picture_info->RefPicSetStCurrBefore, 8);
|
||||
memcpy(picture->RefPicSetStCurrAfter, picture_info->RefPicSetStCurrAfter, 8);
|
||||
memcpy(picture->RefPicSetLtCurr, picture_info->RefPicSetLtCurr, 8);
|
||||
picture->UseStRpsBits = false;
|
||||
|
||||
return VDP_STATUS_OK;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1669,7 +1669,6 @@ struct pipe_h265_pps
|
|||
uint8_t lists_modification_present_flag;
|
||||
uint8_t log2_parallel_merge_level_minus2;
|
||||
uint8_t slice_segment_header_extension_present_flag;
|
||||
uint16_t st_rps_bits;
|
||||
};
|
||||
|
||||
struct pipe_h265_picture_desc
|
||||
|
|
@ -1707,7 +1706,6 @@ struct pipe_h265_picture_desc
|
|||
uint8_t RefPicSetStCurrAfter[8];
|
||||
uint8_t RefPicSetLtCurr[8];
|
||||
uint8_t RefPicList[2][15];
|
||||
bool UseStRpsBits;
|
||||
bool LtCurrDone;
|
||||
|
||||
struct
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue