mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-04 20:38:06 +02:00
radeonsi/vcn: Fix H264 slice header when encoding I frames
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27029>
(cherry picked from commit 865abfde63)
This commit is contained in:
parent
43a00ad0fa
commit
25ae9134dd
3 changed files with 7 additions and 3 deletions
|
|
@ -64,7 +64,7 @@
|
|||
"description": "radeonsi/vcn: Fix H264 slice header when encoding I frames",
|
||||
"nominated": true,
|
||||
"nomination_type": 0,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": null,
|
||||
"notes": null
|
||||
|
|
|
|||
|
|
@ -920,7 +920,8 @@ static void radeon_enc_slice_header(struct radeon_encoder *enc)
|
|||
radeon_enc_code_fixed_bits(enc, enc->enc_pic.pic_order_cnt % 32, 5);
|
||||
|
||||
/* ref_pic_list_modification() */
|
||||
if (enc->enc_pic.picture_type != PIPE_H2645_ENC_PICTURE_TYPE_IDR) {
|
||||
if (enc->enc_pic.picture_type != PIPE_H2645_ENC_PICTURE_TYPE_IDR &&
|
||||
enc->enc_pic.picture_type != PIPE_H2645_ENC_PICTURE_TYPE_I) {
|
||||
radeon_enc_code_fixed_bits(enc, 0x0, 1);
|
||||
|
||||
/* long-term reference */
|
||||
|
|
@ -962,6 +963,7 @@ static void radeon_enc_slice_header(struct radeon_encoder *enc)
|
|||
}
|
||||
|
||||
if ((enc->enc_pic.picture_type != PIPE_H2645_ENC_PICTURE_TYPE_IDR) &&
|
||||
(enc->enc_pic.picture_type != PIPE_H2645_ENC_PICTURE_TYPE_I) &&
|
||||
(enc->enc_pic.spec_misc.cabac_enable))
|
||||
radeon_enc_code_ue(enc, enc->enc_pic.spec_misc.cabac_init_idc);
|
||||
|
||||
|
|
|
|||
|
|
@ -301,7 +301,8 @@ static void radeon_enc_slice_header(struct radeon_encoder *enc)
|
|||
radeon_enc_code_fixed_bits(enc, 0x1, 1); /* direct_spatial_mv_pred_flag */
|
||||
|
||||
/* ref_pic_list_modification() */
|
||||
if (enc->enc_pic.picture_type != PIPE_H2645_ENC_PICTURE_TYPE_IDR) {
|
||||
if (enc->enc_pic.picture_type != PIPE_H2645_ENC_PICTURE_TYPE_IDR &&
|
||||
enc->enc_pic.picture_type != PIPE_H2645_ENC_PICTURE_TYPE_I) {
|
||||
radeon_enc_code_fixed_bits(enc, 0x0, 1);
|
||||
|
||||
/* long-term reference */
|
||||
|
|
@ -347,6 +348,7 @@ static void radeon_enc_slice_header(struct radeon_encoder *enc)
|
|||
}
|
||||
|
||||
if ((enc->enc_pic.picture_type != PIPE_H2645_ENC_PICTURE_TYPE_IDR) &&
|
||||
(enc->enc_pic.picture_type != PIPE_H2645_ENC_PICTURE_TYPE_I) &&
|
||||
(enc->enc_pic.spec_misc.cabac_enable))
|
||||
radeon_enc_code_ue(enc, enc->enc_pic.spec_misc.cabac_init_idc);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue