• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/ap/gpl/iserver/libav-0.8.8/libavcodec/

Lines Matching defs:pps

270 static void decode_scaling_matrices(H264Context *h, SPS *sps, PPS *pps, int is_sps,
288 if(is_sps || pps->transform_8x8_mode){
476 build_qp_table(PPS *pps, int t, int index, const int depth)
481 pps->chroma_qp_table[t][i] = ff_h264_chroma_qp[depth-8][av_clip(i + index, 0, max_qp)];
487 PPS *pps;
499 pps= av_mallocz(sizeof(PPS));
500 if(pps == NULL)
502 pps->sps_id= get_ue_golomb_31(&s->gb);
503 if((unsigned)pps->sps_id>=MAX_SPS_COUNT || h->sps_buffers[pps->sps_id] == NULL){
508 pps->cabac= get_bits1(&s->gb);
509 pps->pic_order_present= get_bits1(&s->gb);
510 pps->slice_group_count= get_ue_golomb(&s->gb) + 1;
511 if(pps->slice_group_count > 1 ){
512 pps->mb_slice_group_map_type= get_ue_golomb(&s->gb);
514 switch(pps->mb_slice_group_map_type){
548 pps->ref_count[0]= get_ue_golomb(&s->gb) + 1;
549 pps->ref_count[1]= get_ue_golomb(&s->gb) + 1;
550 if(pps->ref_count[0]-1 > 32-1 || pps->ref_count[1]-1 > 32-1){
551 av_log(h->s.avctx, AV_LOG_ERROR, "reference overflow (pps)\n");
555 pps->weighted_pred= get_bits1(&s->gb);
556 pps->weighted_bipred_idc= get_bits(&s->gb, 2);
557 pps->init_qp= get_se_golomb(&s->gb) + 26 + qp_bd_offset;
558 pps->init_qs= get_se_golomb(&s->gb) + 26 + qp_bd_offset;
559 pps->chroma_qp_index_offset[0]= get_se_golomb(&s->gb);
560 pps->deblocking_filter_parameters_present= get_bits1(&s->gb);
561 pps->constrained_intra_pred= get_bits1(&s->gb);
562 pps->redundant_pic_cnt_present = get_bits1(&s->gb);
564 pps->transform_8x8_mode= 0;
565 h->dequant_coeff_pps= -1; //contents of sps/pps can change even if id doesn't, so reinit
566 memcpy(pps->scaling_matrix4, h->sps_buffers[pps->sps_id]->scaling_matrix4, sizeof(pps->scaling_matrix4));
567 memcpy(pps->scaling_matrix8, h->sps_buffers[pps->sps_id]->scaling_matrix8, sizeof(pps->scaling_matrix8));
572 pps->transform_8x8_mode= get_bits1(&s->gb);
573 decode_scaling_matrices(h, h->sps_buffers[pps->sps_id], pps, 0, pps->scaling_matrix4, pps->scaling_matrix8);
574 pps->chroma_qp_index_offset[1]= get_se_golomb(&s->gb); //second_chroma_qp_index_offset
576 pps->chroma_qp_index_offset[1]= pps->chroma_qp_index_offset[0];
579 build_qp_table(pps, 0, pps->chroma_qp_index_offset[0], h->sps.bit_depth_luma);
580 build_qp_table(pps, 1, pps->chroma_qp_index_offset[1], h->sps.bit_depth_luma);
581 if(pps->chroma_qp_index_offset[0] != pps->chroma_qp_index_offset[1])
582 pps->chroma_qp_diff= 1;
585 av_log(h->s.avctx, AV_LOG_DEBUG, "pps:%u sps:%u %s slice_groups:%d ref:%d/%d %s qp:%d/%d/%d/%d %s %s %s %s\n",
586 pps_id, pps->sps_id,
587 pps->cabac ? "CABAC" : "CAVLC",
588 pps->slice_group_count,
589 pps->ref_count[0], pps->ref_count[1],
590 pps->weighted_pred ? "weighted" : "",
591 pps->init_qp, pps->init_qs, pps->chroma_qp_index_offset[0], pps->chroma_qp_index_offset[1],
592 pps->deblocking_filter_parameters_present ? "LPAR" : "",
593 pps->constrained_intra_pred ? "CONSTR" : "",
594 pps->redundant_pic_cnt_present ? "REDU" : "",
595 pps->transform_8x8_mode ? "8x8DCT" : ""
600 h->pps_buffers[pps_id]= pps;
603 av_free(pps);