Lines Matching refs:shdr

1133     H264SliceHeader* shdr) {  in ParseRefPicListModifications()  argument
1136 if (!shdr->IsISlice() && !shdr->IsSISlice()) { in ParseRefPicListModifications()
1137 READ_BOOL_OR_RETURN(&shdr->ref_pic_list_modification_flag_l0); in ParseRefPicListModifications()
1138 if (shdr->ref_pic_list_modification_flag_l0) { in ParseRefPicListModifications()
1139 res = ParseRefPicListModification(shdr->num_ref_idx_l0_active_minus1, in ParseRefPicListModifications()
1140 shdr->ref_list_l0_modifications); in ParseRefPicListModifications()
1146 if (shdr->IsBSlice()) { in ParseRefPicListModifications()
1147 READ_BOOL_OR_RETURN(&shdr->ref_pic_list_modification_flag_l1); in ParseRefPicListModifications()
1148 if (shdr->ref_pic_list_modification_flag_l1) { in ParseRefPicListModifications()
1149 res = ParseRefPicListModification(shdr->num_ref_idx_l1_active_minus1, in ParseRefPicListModifications()
1150 shdr->ref_list_l1_modifications); in ParseRefPicListModifications()
1204 H264SliceHeader* shdr) { in ParsePredWeightTable() argument
1205 READ_UE_OR_RETURN(&shdr->luma_log2_weight_denom); in ParsePredWeightTable()
1206 TRUE_OR_RETURN(shdr->luma_log2_weight_denom < 8); in ParsePredWeightTable()
1209 READ_UE_OR_RETURN(&shdr->chroma_log2_weight_denom); in ParsePredWeightTable()
1210 TRUE_OR_RETURN(shdr->chroma_log2_weight_denom < 8); in ParsePredWeightTable()
1213 shdr->num_ref_idx_l0_active_minus1, sps.chroma_array_type, in ParsePredWeightTable()
1214 shdr->luma_log2_weight_denom, shdr->chroma_log2_weight_denom, in ParsePredWeightTable()
1215 &shdr->pred_weight_table_l0); in ParsePredWeightTable()
1219 if (shdr->IsBSlice()) { in ParsePredWeightTable()
1221 shdr->num_ref_idx_l1_active_minus1, sps.chroma_array_type, in ParsePredWeightTable()
1222 shdr->luma_log2_weight_denom, shdr->chroma_log2_weight_denom, in ParsePredWeightTable()
1223 &shdr->pred_weight_table_l1); in ParsePredWeightTable()
1231 H264Parser::Result H264Parser::ParseDecRefPicMarking(H264SliceHeader* shdr) { in ParseDecRefPicMarking() argument
1234 if (shdr->idr_pic_flag) { in ParseDecRefPicMarking()
1235 READ_BOOL_OR_RETURN(&shdr->no_output_of_prior_pics_flag); in ParseDecRefPicMarking()
1236 READ_BOOL_OR_RETURN(&shdr->long_term_reference_flag); in ParseDecRefPicMarking()
1238 READ_BOOL_OR_RETURN(&shdr->adaptive_ref_pic_marking_mode_flag); in ParseDecRefPicMarking()
1241 if (shdr->adaptive_ref_pic_marking_mode_flag) { in ParseDecRefPicMarking()
1243 for (i = 0; i < arraysize(shdr->ref_pic_marking); ++i) { in ParseDecRefPicMarking()
1244 marking = &shdr->ref_pic_marking[i]; in ParseDecRefPicMarking()
1268 if (i == arraysize(shdr->ref_pic_marking)) { in ParseDecRefPicMarking()
1275 shdr->dec_ref_pic_marking_bit_size = bits_left_at_start - br_.NumBitsLeft(); in ParseDecRefPicMarking()
1280 H264SliceHeader* shdr) { in ParseSliceHeader() argument
1286 memset(shdr, 0, sizeof(*shdr)); in ParseSliceHeader()
1288 shdr->idr_pic_flag = (nalu.nal_unit_type == 5); in ParseSliceHeader()
1289 shdr->nal_ref_idc = nalu.nal_ref_idc; in ParseSliceHeader()
1290 shdr->nalu_data = nalu.data; in ParseSliceHeader()
1291 shdr->nalu_size = nalu.size; in ParseSliceHeader()
1293 READ_UE_OR_RETURN(&shdr->first_mb_in_slice); in ParseSliceHeader()
1294 READ_UE_OR_RETURN(&shdr->slice_type); in ParseSliceHeader()
1295 TRUE_OR_RETURN(shdr->slice_type < 10); in ParseSliceHeader()
1297 READ_UE_OR_RETURN(&shdr->pic_parameter_set_id); in ParseSliceHeader()
1299 pps = GetPPS(shdr->pic_parameter_set_id); in ParseSliceHeader()
1310 READ_BITS_OR_RETURN(sps->log2_max_frame_num_minus4 + 4, &shdr->frame_num); in ParseSliceHeader()
1312 READ_BOOL_OR_RETURN(&shdr->field_pic_flag); in ParseSliceHeader()
1313 if (shdr->field_pic_flag) { in ParseSliceHeader()
1319 if (shdr->idr_pic_flag) in ParseSliceHeader()
1320 READ_UE_OR_RETURN(&shdr->idr_pic_id); in ParseSliceHeader()
1325 &shdr->pic_order_cnt_lsb); in ParseSliceHeader()
1327 !shdr->field_pic_flag) in ParseSliceHeader()
1328 READ_SE_OR_RETURN(&shdr->delta_pic_order_cnt_bottom); in ParseSliceHeader()
1332 READ_SE_OR_RETURN(&shdr->delta_pic_order_cnt0); in ParseSliceHeader()
1334 !shdr->field_pic_flag) in ParseSliceHeader()
1335 READ_SE_OR_RETURN(&shdr->delta_pic_order_cnt1); in ParseSliceHeader()
1338 shdr->pic_order_cnt_bit_size = in ParseSliceHeader()
1342 READ_UE_OR_RETURN(&shdr->redundant_pic_cnt); in ParseSliceHeader()
1343 TRUE_OR_RETURN(shdr->redundant_pic_cnt < 128); in ParseSliceHeader()
1346 if (shdr->IsBSlice()) in ParseSliceHeader()
1347 READ_BOOL_OR_RETURN(&shdr->direct_spatial_mv_pred_flag); in ParseSliceHeader()
1349 if (shdr->IsPSlice() || shdr->IsSPSlice() || shdr->IsBSlice()) { in ParseSliceHeader()
1350 READ_BOOL_OR_RETURN(&shdr->num_ref_idx_active_override_flag); in ParseSliceHeader()
1351 if (shdr->num_ref_idx_active_override_flag) { in ParseSliceHeader()
1352 READ_UE_OR_RETURN(&shdr->num_ref_idx_l0_active_minus1); in ParseSliceHeader()
1353 if (shdr->IsBSlice()) in ParseSliceHeader()
1354 READ_UE_OR_RETURN(&shdr->num_ref_idx_l1_active_minus1); in ParseSliceHeader()
1356 shdr->num_ref_idx_l0_active_minus1 = in ParseSliceHeader()
1358 if (shdr->IsBSlice()) { in ParseSliceHeader()
1359 shdr->num_ref_idx_l1_active_minus1 = in ParseSliceHeader()
1364 if (shdr->field_pic_flag) { in ParseSliceHeader()
1365 TRUE_OR_RETURN(shdr->num_ref_idx_l0_active_minus1 < 32); in ParseSliceHeader()
1366 TRUE_OR_RETURN(shdr->num_ref_idx_l1_active_minus1 < 32); in ParseSliceHeader()
1368 TRUE_OR_RETURN(shdr->num_ref_idx_l0_active_minus1 < 16); in ParseSliceHeader()
1369 TRUE_OR_RETURN(shdr->num_ref_idx_l1_active_minus1 < 16); in ParseSliceHeader()
1375 res = ParseRefPicListModifications(shdr); in ParseSliceHeader()
1380 if ((pps->weighted_pred_flag && (shdr->IsPSlice() || shdr->IsSPSlice())) || in ParseSliceHeader()
1381 (pps->weighted_bipred_idc == 1 && shdr->IsBSlice())) { in ParseSliceHeader()
1382 res = ParsePredWeightTable(*sps, shdr); in ParseSliceHeader()
1388 res = ParseDecRefPicMarking(shdr); in ParseSliceHeader()
1393 if (pps->entropy_coding_mode_flag && !shdr->IsISlice() && in ParseSliceHeader()
1394 !shdr->IsSISlice()) { in ParseSliceHeader()
1395 READ_UE_OR_RETURN(&shdr->cabac_init_idc); in ParseSliceHeader()
1396 TRUE_OR_RETURN(shdr->cabac_init_idc < 3); in ParseSliceHeader()
1399 READ_SE_OR_RETURN(&shdr->slice_qp_delta); in ParseSliceHeader()
1401 if (shdr->IsSPSlice() || shdr->IsSISlice()) { in ParseSliceHeader()
1402 if (shdr->IsSPSlice()) in ParseSliceHeader()
1403 READ_BOOL_OR_RETURN(&shdr->sp_for_switch_flag); in ParseSliceHeader()
1404 READ_SE_OR_RETURN(&shdr->slice_qs_delta); in ParseSliceHeader()
1408 READ_UE_OR_RETURN(&shdr->disable_deblocking_filter_idc); in ParseSliceHeader()
1409 TRUE_OR_RETURN(shdr->disable_deblocking_filter_idc < 3); in ParseSliceHeader()
1411 if (shdr->disable_deblocking_filter_idc != 1) { in ParseSliceHeader()
1412 READ_SE_OR_RETURN(&shdr->slice_alpha_c0_offset_div2); in ParseSliceHeader()
1413 IN_RANGE_OR_RETURN(shdr->slice_alpha_c0_offset_div2, -6, 6); in ParseSliceHeader()
1415 READ_SE_OR_RETURN(&shdr->slice_beta_offset_div2); in ParseSliceHeader()
1416 IN_RANGE_OR_RETURN(shdr->slice_beta_offset_div2, -6, 6); in ParseSliceHeader()
1426 shdr->header_bit_size = (shdr->nalu_size - epb) * 8 - br_.NumBitsLeft(); in ParseSliceHeader()