Lines Matching refs:ps_codec

187 WORD32 ih264e_input_queue_update(codec_t *ps_codec,  in ih264e_input_queue_update()  argument
202 ps_codec->i4_last_inp_buff_received = 1; in ih264e_input_queue_update()
206 && !ps_codec->i4_last_inp_buff_received) in ih264e_input_queue_update()
222 ps_codec->s_rate_control.pps_rate_control_api, in ih264e_input_queue_update()
223 ps_codec->s_rate_control.pps_pd_frm_rate, in ih264e_input_queue_update()
224 ps_codec->s_rate_control.pps_time_stamp, in ih264e_input_queue_update()
225 ps_codec->s_rate_control.pps_frame_time); in ih264e_input_queue_update()
237 ps_inp_buf = &(ps_codec->as_inp_list[ps_codec->i4_pic_cnt in ih264e_input_queue_update()
263 i4_force_idr = (ps_codec->force_curr_frame_type == IV_IDR_FRAME); in ih264e_input_queue_update()
264 i4_force_idr |= !(ps_codec->i4_pic_cnt % ps_codec->s_cfg.u4_idr_frm_interval); in ih264e_input_queue_update()
266 i4_force_i = (ps_codec->force_curr_frame_type == IV_I_FRAME); in ih264e_input_queue_update()
268 ps_codec->i4_pending_idr_flag |= i4_force_idr; in ih264e_input_queue_update()
270 if ((ps_codec->i4_pic_cnt > 0) && (i4_force_idr || i4_force_i)) in ih264e_input_queue_update()
272 irc_force_I_frame(ps_codec->s_rate_control.pps_rate_control_api); in ih264e_input_queue_update()
274 ps_codec->force_curr_frame_type = IV_NA_FRAME; in ih264e_input_queue_update()
277 irc_add_picture_to_stack(ps_codec->s_rate_control.pps_rate_control_api, in ih264e_input_queue_update()
278 ps_codec->i4_pic_cnt); in ih264e_input_queue_update()
282 if (ps_codec->i4_encode_api_call_cnt in ih264e_input_queue_update()
283 < (WORD32)(ps_codec->s_cfg.u4_num_bframes)) in ih264e_input_queue_update()
295 ps_codec->s_rate_control.pps_rate_control_api, (WORD32 *)(&u4_pic_id), in ih264e_input_queue_update()
301 ps_codec->pic_type = PIC_I; in ih264e_input_queue_update()
304 ps_codec->pic_type = PIC_P; in ih264e_input_queue_update()
307 ps_codec->pic_type = PIC_B; in ih264e_input_queue_update()
310 ps_codec->pic_type = PIC_NA; in ih264e_input_queue_update()
316 if (ps_codec->pic_type == PIC_I) in ih264e_input_queue_update()
318 ps_codec->pic_type = ps_codec->i4_pending_idr_flag ? in ih264e_input_queue_update()
319 PIC_IDR : ps_codec->pic_type; in ih264e_input_queue_update()
320 ps_codec->i4_pending_idr_flag = 0; in ih264e_input_queue_update()
325 ps_codec->s_rate_control.pps_rate_control_api, e_pictype, in ih264e_input_queue_update()
327 ps_codec->u4_frame_qp = gau1_mpeg2_to_h264_qmap[u1_frame_qp]; in ih264e_input_queue_update()
333 ps_codec->i4_poc = u4_pic_id; in ih264e_input_queue_update()
341 ctxt_sel = ps_codec->i4_encode_api_call_cnt % MAX_CTXT_SETS; in ih264e_input_queue_update()
342 ps_codec->s_rate_control.pre_encode_skip[ctxt_sel] = i4_skip; in ih264e_input_queue_update()
345 ps_inp_buf = &(ps_codec->as_inp_list[u4_pic_id % MAX_NUM_BFRAMES]); in ih264e_input_queue_update()
402 if (ps_enc_buff->u4_is_last && (ps_codec->pic_type == PIC_P) in ih264e_input_queue_update()
403 && ps_codec->s_cfg.u4_num_bframes && (ps_codec->i4_poc > 1)) in ih264e_input_queue_update()
411 ps_inp_list = &ps_codec->as_inp_list[0]; in ih264e_input_queue_update()
427 ps_swap_buff = &(ps_codec->as_inp_list[u4_lst_bframe]); in ih264e_input_queue_update()
439 ps_codec->pic_type = PIC_NA; in ih264e_input_queue_update()
776 IH264E_ERROR_T ih264e_pic_buf_mgr_add_bufs(codec_t *ps_codec) in ih264e_pic_buf_mgr_add_bufs() argument
782 WORD32 max_num_bufs = ps_codec->i4_ref_buf_cnt; in ih264e_pic_buf_mgr_add_bufs()
785 WORD32 pic_buf_size_allocated = ps_codec->i4_total_pic_buf_size in ih264e_pic_buf_mgr_add_bufs()
789 UWORD8 *pu1_buf = (UWORD8 *) ps_codec->ps_pic_buf; in ih264e_pic_buf_mgr_add_bufs()
790 pic_buf_t *ps_pic_buf = (pic_buf_t *) ps_codec->ps_pic_buf; in ih264e_pic_buf_mgr_add_bufs()
801 WORD32 luma_samples = (ps_codec->i4_rec_strd) in ih264e_pic_buf_mgr_add_bufs()
802 * (ps_codec->s_cfg.u4_ht + PAD_HT); in ih264e_pic_buf_mgr_add_bufs()
815 ps_codec->i4_error_code = IH264E_INSUFFICIENT_MEM_PICBUF; in ih264e_pic_buf_mgr_add_bufs()
819 ps_pic_buf->pu1_luma = pu1_buf + ps_codec->i4_rec_strd * PAD_TOP in ih264e_pic_buf_mgr_add_bufs()
824 + ps_codec->i4_rec_strd * (PAD_TOP / 2)+ PAD_LEFT; in ih264e_pic_buf_mgr_add_bufs()
827 buf_ret = ih264_buf_mgr_add((buf_mgr_t *) ps_codec->pv_ref_buf_mgr, in ih264e_pic_buf_mgr_add_bufs()
832 ps_codec->i4_error_code = IH264E_BUF_MGR_ERROR; in ih264e_pic_buf_mgr_add_bufs()
861 IH264E_ERROR_T ih264e_mv_buf_mgr_add_bufs(codec_t *ps_codec) in ih264e_mv_buf_mgr_add_bufs() argument
880 WORD32 num_luma_samples = ALIGN16(ps_codec->s_cfg.u4_wd) in ih264e_mv_buf_mgr_add_bufs()
881 * ALIGN16(ps_codec->s_cfg.u4_ht); in ih264e_mv_buf_mgr_add_bufs()
891 max_dpb_size = ps_codec->i4_ref_buf_cnt; in ih264e_mv_buf_mgr_add_bufs()
894 ps_codec->ps_mv_buf = ps_codec->pv_mv_bank_buf_base; in ih264e_mv_buf_mgr_add_bufs()
895 pu1_buf = ps_codec->pv_mv_bank_buf_base; in ih264e_mv_buf_mgr_add_bufs()
901 mv_bank_size_allocated = ps_codec->i4_total_mv_bank_size in ih264e_mv_buf_mgr_add_bufs()
910 ps_mv_buf = ps_codec->pv_mv_bank_buf_base; in ih264e_mv_buf_mgr_add_bufs()
918 ps_codec->i4_error_code = IH264E_INSUFFICIENT_MEM_MVBANK; in ih264e_mv_buf_mgr_add_bufs()
934 ret = ih264_buf_mgr_add((buf_mgr_t *) ps_codec->pv_mv_buf_mgr, in ih264e_mv_buf_mgr_add_bufs()
939 ps_codec->i4_error_code = IH264E_BUF_MGR_ERROR; in ih264e_mv_buf_mgr_add_bufs()
1052 if (ps_proc->ps_codec->s_cfg.u4_enable_satqd) in ih264e_init_quant_params()
1097 IH264E_ERROR_T ih264e_init_air_map(codec_t *ps_codec) in ih264e_init_air_map() argument
1100 UWORD16 *pu2_intr_rfrsh_map = ps_codec->pu2_intr_rfrsh_map; in ih264e_init_air_map()
1103 IVE_AIR_MODE_T air_mode = ps_codec->s_cfg.e_air_mode; in ih264e_init_air_map()
1106 UWORD32 air_period = ps_codec->s_cfg.u4_air_refresh_period; in ih264e_init_air_map()
1109 UWORD32 u4_mb_cnt = ps_codec->s_cfg.i4_wd_mbs * ps_codec->s_cfg.i4_ht_mbs; in ih264e_init_air_map()
1164 IH264E_ERROR_T ih264e_codec_init(codec_t *ps_codec) in ih264e_codec_init() argument
1170 if (ps_codec->s_cfg.u4_enc_speed_preset != IVE_CONFIG) in ih264e_codec_init()
1172 if (ps_codec->s_cfg.u4_enc_speed_preset == IVE_SLOWEST) in ih264e_codec_init()
1175 ps_codec->s_cfg.u4_me_speed_preset = DMND_SRCH; in ih264e_codec_init()
1176 ps_codec->s_cfg.u4_enable_fast_sad = 0; in ih264e_codec_init()
1179 ps_codec->s_cfg.u4_enable_intra_4x4 = 1; in ih264e_codec_init()
1180 ps_codec->luma_energy_compaction[1] = in ih264e_codec_init()
1184 ps_codec->s_cfg.u4_enable_hpel = 1; in ih264e_codec_init()
1187 ps_codec->s_cfg.u4_disable_deblock_level = DISABLE_DEBLK_LEVEL_0; in ih264e_codec_init()
1190 ps_codec->u4_inter_gate = 0; in ih264e_codec_init()
1192 else if (ps_codec->s_cfg.u4_enc_speed_preset == IVE_NORMAL) in ih264e_codec_init()
1195 ps_codec->s_cfg.u4_me_speed_preset = DMND_SRCH; in ih264e_codec_init()
1196 ps_codec->s_cfg.u4_enable_fast_sad = 0; in ih264e_codec_init()
1199 ps_codec->s_cfg.u4_enable_intra_4x4 = 1; in ih264e_codec_init()
1202 ps_codec->s_cfg.u4_enable_hpel = 1; in ih264e_codec_init()
1205 ps_codec->s_cfg.u4_disable_deblock_level = DISABLE_DEBLK_LEVEL_0; in ih264e_codec_init()
1208 ps_codec->u4_inter_gate = 0; in ih264e_codec_init()
1210 else if (ps_codec->s_cfg.u4_enc_speed_preset == IVE_FAST) in ih264e_codec_init()
1213 ps_codec->s_cfg.u4_me_speed_preset = DMND_SRCH; in ih264e_codec_init()
1214 ps_codec->s_cfg.u4_enable_fast_sad = 0; in ih264e_codec_init()
1217 ps_codec->s_cfg.u4_enable_intra_4x4 = 0; in ih264e_codec_init()
1220 ps_codec->s_cfg.u4_enable_hpel = 1; in ih264e_codec_init()
1223 ps_codec->s_cfg.u4_disable_deblock_level = DISABLE_DEBLK_LEVEL_0; in ih264e_codec_init()
1226 ps_codec->u4_inter_gate = 1; in ih264e_codec_init()
1228 else if (ps_codec->s_cfg.u4_enc_speed_preset == IVE_HIGH_SPEED) in ih264e_codec_init()
1231 ps_codec->s_cfg.u4_me_speed_preset = DMND_SRCH; in ih264e_codec_init()
1232 ps_codec->s_cfg.u4_enable_fast_sad = 0; in ih264e_codec_init()
1235 ps_codec->s_cfg.u4_enable_intra_4x4 = 0; in ih264e_codec_init()
1238 ps_codec->s_cfg.u4_enable_hpel = 0; in ih264e_codec_init()
1241 ps_codec->s_cfg.u4_disable_deblock_level = DISABLE_DEBLK_LEVEL_4; in ih264e_codec_init()
1244 ps_codec->u4_inter_gate = 0; in ih264e_codec_init()
1246 else if (ps_codec->s_cfg.u4_enc_speed_preset == IVE_FASTEST) in ih264e_codec_init()
1249 ps_codec->s_cfg.u4_me_speed_preset = DMND_SRCH; in ih264e_codec_init()
1252 ps_codec->s_cfg.u4_enable_intra_4x4 = 0; in ih264e_codec_init()
1255 ps_codec->s_cfg.u4_enable_hpel = 0; in ih264e_codec_init()
1258 ps_codec->s_cfg.u4_disable_deblock_level = DISABLE_DEBLK_LEVEL_4; in ih264e_codec_init()
1261 ps_codec->u4_inter_gate = 1; in ih264e_codec_init()
1268 if (IVE_AIR_MODE_NONE != ps_codec->s_cfg.e_air_mode) in ih264e_codec_init()
1270 ih264e_init_air_map(ps_codec); in ih264e_codec_init()
1272 ps_codec->i4_air_pic_cnt = -1; in ih264e_codec_init()
1286 au1_init_qp[0] = gau1_h264_to_mpeg2_qmap[ps_codec->s_cfg.u4_i_qp]; in ih264e_codec_init()
1287 au1_init_qp[1] = gau1_h264_to_mpeg2_qmap[ps_codec->s_cfg.u4_p_qp]; in ih264e_codec_init()
1288 au1_init_qp[2] = gau1_h264_to_mpeg2_qmap[ps_codec->s_cfg.u4_b_qp]; in ih264e_codec_init()
1292 gau1_h264_to_mpeg2_qmap[ps_codec->s_cfg.u4_i_qp_min]; in ih264e_codec_init()
1294 gau1_h264_to_mpeg2_qmap[ps_codec->s_cfg.u4_i_qp_max]; in ih264e_codec_init()
1297 gau1_h264_to_mpeg2_qmap[ps_codec->s_cfg.u4_p_qp_min]; in ih264e_codec_init()
1299 gau1_h264_to_mpeg2_qmap[ps_codec->s_cfg.u4_p_qp_max]; in ih264e_codec_init()
1302 gau1_h264_to_mpeg2_qmap[ps_codec->s_cfg.u4_b_qp_min]; in ih264e_codec_init()
1304 gau1_h264_to_mpeg2_qmap[ps_codec->s_cfg.u4_b_qp_max]; in ih264e_codec_init()
1307 switch (ps_codec->s_cfg.e_rc_mode) in ih264e_codec_init()
1310 ps_codec->s_rate_control.e_rc_type = VBR_STORAGE; in ih264e_codec_init()
1313 ps_codec->s_rate_control.e_rc_type = CBR_NLDRC; in ih264e_codec_init()
1316 ps_codec->s_rate_control.e_rc_type = CBR_LDRC; in ih264e_codec_init()
1319 ps_codec->s_rate_control.e_rc_type = CONST_QP; in ih264e_codec_init()
1326 ih264e_rc_init(ps_codec->s_rate_control.pps_rate_control_api, in ih264e_codec_init()
1327 ps_codec->s_rate_control.pps_frame_time, in ih264e_codec_init()
1328 ps_codec->s_rate_control.pps_time_stamp, in ih264e_codec_init()
1329 ps_codec->s_rate_control.pps_pd_frm_rate, in ih264e_codec_init()
1330 ps_codec->s_cfg.u4_max_framerate, in ih264e_codec_init()
1331 ps_codec->s_cfg.u4_src_frame_rate, in ih264e_codec_init()
1332 ps_codec->s_cfg.u4_tgt_frame_rate, in ih264e_codec_init()
1333 ps_codec->s_rate_control.e_rc_type, in ih264e_codec_init()
1334 ps_codec->s_cfg.u4_target_bitrate, in ih264e_codec_init()
1335 ps_codec->s_cfg.u4_max_bitrate, in ih264e_codec_init()
1336 ps_codec->s_cfg.u4_vbv_buffer_delay, in ih264e_codec_init()
1337 ps_codec->s_cfg.u4_i_frm_interval, in ih264e_codec_init()
1338 ps_codec->s_cfg.u4_num_bframes + 1, au1_init_qp, in ih264e_codec_init()
1339 ps_codec->s_cfg.u4_num_bframes + 2 , au1_min_max_qp, in ih264e_codec_init()
1340 MAX(ps_codec->s_cfg.u4_max_level, in ih264e_codec_init()
1341 … (UWORD32)ih264e_get_min_level(ps_codec->s_cfg.u4_max_wd, ps_codec->s_cfg.u4_max_ht))); in ih264e_codec_init()
1345 ps_codec->i4_rec_strd = ALIGN16(ps_codec->s_cfg.u4_max_wd) + PAD_WD; in ih264e_codec_init()
1348 ps_codec->i4_ref_buf_cnt = ps_codec->s_cfg.u4_max_ref_cnt in ih264e_codec_init()
1349 + ps_codec->s_cfg.u4_max_reorder_cnt; in ih264e_codec_init()
1350 ps_codec->i4_ref_buf_cnt += MAX_CTXT_SETS; in ih264e_codec_init()
1356 ps_codec->i4_last_inp_buff_received = 0; in ih264e_codec_init()
1359 ps_codec->i4_pending_idr_flag = 0; in ih264e_codec_init()
1392 IH264E_ERROR_T ih264e_pic_init(codec_t *ps_codec, inp_buf_t *ps_inp_buf) in ih264e_pic_init() argument
1417 WORD32 ctxt_sel = ps_codec->i4_encode_api_call_cnt % MAX_CTXT_SETS; in ih264e_pic_init()
1420 PIC_TYPE_T *pic_type = &ps_codec->pic_type; in ih264e_pic_init()
1424 (ps_codec->s_cfg.u4_enc_speed_preset == IVE_FASTEST) ? in ih264e_pic_init()
1428 UWORD32 u4_enable_fast_sad = ps_codec->s_cfg.u4_enable_fast_sad; in ih264e_pic_init()
1436 ps_codec->i4_slice_type = ISLICE; in ih264e_pic_init()
1440 ps_codec->i4_slice_type = PSLICE; in ih264e_pic_init()
1444 ps_codec->i4_slice_type = BSLICE; in ih264e_pic_init()
1454 ps_codec->u4_is_curr_frm_ref = 0; in ih264e_pic_init()
1457 ps_codec->u4_is_curr_frm_ref = (*pic_type != PIC_B); in ih264e_pic_init()
1460 if (ps_codec->s_cfg.u4_enable_alt_ref && (*pic_type == PIC_P) in ih264e_pic_init()
1461 && (ps_codec->i4_pic_cnt in ih264e_pic_init()
1462 % (ps_codec->s_cfg.u4_enable_alt_ref + 1))) in ih264e_pic_init()
1464 ps_codec->u4_is_curr_frm_ref = 0; in ih264e_pic_init()
1474 ps_codec->u4_is_idr = 0; in ih264e_pic_init()
1479 ps_codec->u4_is_idr = 1; in ih264e_pic_init()
1482 ps_codec->i4_frame_num = 0; in ih264e_pic_init()
1485 ps_codec->i4_idr_pic_id++; in ih264e_pic_init()
1493 ps_codec->i4_disable_deblk_pic = 1; in ih264e_pic_init()
1495 if (ps_codec->s_cfg.u4_disable_deblock_level == DISABLE_DEBLK_LEVEL_0) in ih264e_pic_init()
1498 ps_codec->i4_disable_deblk_pic = 0; in ih264e_pic_init()
1500 else if (ps_codec->s_cfg.u4_disable_deblock_level == DISABLE_DEBLK_LEVEL_2) in ih264e_pic_init()
1503 if (ps_codec->i4_disable_deblk_pic_cnt == DISABLE_DEBLOCK_INTERVAL in ih264e_pic_init()
1504 || ps_codec->i4_slice_type == ISLICE) in ih264e_pic_init()
1506 ps_codec->i4_disable_deblk_pic = 0; in ih264e_pic_init()
1509 else if (ps_codec->s_cfg.u4_disable_deblock_level == DISABLE_DEBLK_LEVEL_3) in ih264e_pic_init()
1511 if (ps_codec->i4_slice_type == ISLICE) in ih264e_pic_init()
1513 ps_codec->i4_disable_deblk_pic = 0; in ih264e_pic_init()
1517 if (ps_codec->i4_disable_deblk_pic) in ih264e_pic_init()
1519 ps_codec->i4_disable_deblk_pic_cnt++; in ih264e_pic_init()
1523 ps_codec->i4_disable_deblk_pic_cnt = 0; in ih264e_pic_init()
1527 if (ps_codec->i4_disable_deblk_pic == 0) in ih264e_pic_init()
1529 if (ps_codec->s_cfg.e_slice_mode != IVE_SLICE_MODE_NONE) in ih264e_pic_init()
1531 ps_codec->i4_disable_deblk_pic = 2; in ih264e_pic_init()
1536 ps_codec->i4_error_code = IH264E_SUCCESS; in ih264e_pic_init()
1539 if (ps_codec->i4_gen_header) in ih264e_pic_init()
1548 ps_codec->i4_pps_id %= MAX_PPS_CNT; in ih264e_pic_init()
1551 ps_codec->i4_sps_id %= MAX_SPS_CNT; in ih264e_pic_init()
1554 ps_sps = ps_codec->ps_sps_base + ps_codec->i4_sps_id; in ih264e_pic_init()
1555 ih264e_populate_sps(ps_codec, ps_sps); in ih264e_pic_init()
1558 ps_pps = ps_codec->ps_pps_base + ps_codec->i4_pps_id; in ih264e_pic_init()
1559 ih264e_populate_pps(ps_codec, ps_pps); in ih264e_pic_init()
1595 for (i = 0; i < ps_codec->i4_ref_buf_cnt; i++) in ih264e_pic_init()
1597 if (ps_codec->as_ref_set[i].i4_pic_cnt == -1) in ih264e_pic_init()
1601 ps_codec->pv_ref_buf_mgr, in ih264e_pic_init()
1602 ps_codec->as_ref_set[i].ps_pic_buf->i4_buf_id); in ih264e_pic_init()
1607 if ((max_pic_cnt[0] < ps_codec->as_ref_set[i].i4_pic_cnt) in ih264e_pic_init()
1610 if (max_pic_cnt[1] < ps_codec->as_ref_set[i].i4_pic_cnt) in ih264e_pic_init()
1618 max_pic_cnt[1] = ps_codec->as_ref_set[i].i4_pic_cnt; in ih264e_pic_init()
1619 aps_ref_pic[1] = ps_codec->as_ref_set[i].ps_pic_buf; in ih264e_pic_init()
1620 aps_mv_buf[1] = ps_codec->as_ref_set[i].ps_mv_buf; in ih264e_pic_init()
1621 ps_mv_buf_to_free[1] = ps_codec->as_ref_set[i].ps_mv_buf; in ih264e_pic_init()
1626 max_pic_cnt[0] = ps_codec->as_ref_set[i].i4_pic_cnt; in ih264e_pic_init()
1627 aps_ref_pic[0] = ps_codec->as_ref_set[i].ps_pic_buf; in ih264e_pic_init()
1628 aps_mv_buf[0] = ps_codec->as_ref_set[i].ps_mv_buf; in ih264e_pic_init()
1629 ps_mv_buf_to_free[0] = ps_codec->as_ref_set[i].ps_mv_buf; in ih264e_pic_init()
1643 ih264_buf_mgr_release(ps_codec->pv_mv_buf_mgr, in ih264e_pic_init()
1647 ih264_buf_mgr_release(ps_codec->pv_ref_buf_mgr, in ih264e_pic_init()
1666 for (i = 0; i < ps_codec->i4_ref_buf_cnt; i++) in ih264e_pic_init()
1668 if (ps_codec->as_ref_set[i].i4_pic_cnt == -1) in ih264e_pic_init()
1675 ps_codec->pv_ref_buf_mgr, in ih264e_pic_init()
1676 ps_codec->as_ref_set[i].ps_pic_buf->i4_buf_id); in ih264e_pic_init()
1680 ps_codec->as_ref_set[i].i4_pic_cnt = -1; in ih264e_pic_init()
1681 ps_codec->as_ref_set[i].i4_poc = 32768; in ih264e_pic_init()
1698 (buf_mgr_t *) ps_codec->pv_mv_buf_mgr, in ih264e_pic_init()
1703 ps_codec->i4_error_code = IH264E_NO_FREE_MVBANK; in ih264e_pic_init()
1708 if (ps_codec->u4_is_curr_frm_ref) in ih264e_pic_init()
1710 ih264_buf_mgr_set_status(ps_codec->pv_mv_buf_mgr, in ih264e_pic_init()
1718 ps_mv_buf->i4_abs_poc = ps_codec->i4_abs_pic_order_cnt; in ih264e_pic_init()
1730 (buf_mgr_t *) ps_codec->pv_ref_buf_mgr, in ih264e_pic_init()
1735 ps_codec->i4_error_code = IH264E_NO_FREE_PICBUF; in ih264e_pic_init()
1740 if (ps_codec->u4_is_curr_frm_ref) in ih264e_pic_init()
1742 ih264_buf_mgr_set_status(ps_codec->pv_ref_buf_mgr, cur_pic_buf_id, in ih264e_pic_init()
1747 if (1 == ps_codec->s_cfg.u4_enable_recon) in ih264e_pic_init()
1749 ih264_buf_mgr_set_status(ps_codec->pv_ref_buf_mgr, cur_pic_buf_id, in ih264e_pic_init()
1757 ps_cur_pic->i4_abs_poc = ps_codec->i4_poc; in ih264e_pic_init()
1758 ps_cur_pic->i4_poc_lsb = ps_codec->i4_pic_order_cnt_lsb; in ih264e_pic_init()
1774 ps_codec->as_ref_set[ref_set_id].i4_pic_cnt = ps_codec->i4_pic_cnt; in ih264e_pic_init()
1775 ps_codec->as_ref_set[ref_set_id].i4_poc = ps_codec->i4_poc; in ih264e_pic_init()
1776 ps_codec->as_ref_set[ref_set_id].ps_mv_buf = ps_mv_buf; in ih264e_pic_init()
1777 ps_codec->as_ref_set[ref_set_id].ps_pic_buf = ps_cur_pic; in ih264e_pic_init()
1795 ps_proc = &ps_codec->as_process[i]; in ih264e_pic_init()
1798 if (ps_codec->s_cfg.e_inp_color_fmt == IV_YUV_422ILE) in ih264e_pic_init()
1800 ps_proc->pu1_src_buf_luma_base = ps_codec->pu1_y_csc_buf_base; in ih264e_pic_init()
1809 if (ps_codec->s_cfg.e_inp_color_fmt == IV_YUV_422ILE in ih264e_pic_init()
1810 || ps_codec->s_cfg.e_inp_color_fmt == IV_YUV_420P) in ih264e_pic_init()
1813 ps_codec->pu1_uv_csc_buf_base; in ih264e_pic_init()
1828 ps_proc->i4_rec_strd = ps_codec->i4_rec_strd; in ih264e_pic_init()
1831 ps_proc->i4_frame_num = ps_codec->i4_frame_num; in ih264e_pic_init()
1834 ps_proc->u4_is_idr = ps_codec->u4_is_idr; in ih264e_pic_init()
1837 ps_proc->u4_idr_pic_id = ps_codec->i4_idr_pic_id; in ih264e_pic_init()
1840 ps_proc->i4_slice_type = ps_codec->i4_slice_type; in ih264e_pic_init()
1843 ps_proc->i4_wd_mbs = ps_codec->s_cfg.i4_wd_mbs; in ih264e_pic_init()
1846 ps_proc->i4_ht_mbs = ps_codec->s_cfg.i4_ht_mbs; in ih264e_pic_init()
1867 ps_proc->u4_frame_qp = ps_codec->u4_frame_qp; in ih264e_pic_init()
1868 ps_proc->u4_mb_qp = ps_codec->u4_frame_qp; in ih264e_pic_init()
1896 if (IVE_AIR_MODE_NONE != ps_codec->s_cfg.e_air_mode) in ih264e_pic_init()
1898 ps_codec->i4_air_pic_cnt = (ps_codec->i4_air_pic_cnt + 1) in ih264e_pic_init()
1899 % ps_codec->s_cfg.u4_air_refresh_period; in ih264e_pic_init()
1901 if (!ps_codec->i4_air_pic_cnt) in ih264e_pic_init()
1909 ps_proc->u4_disable_deblock_level = ps_codec->i4_disable_deblk_pic; in ih264e_pic_init()
1913 if (ps_codec->s_cfg.e_slice_mode == IVE_SLICE_MODE_NONE) in ih264e_pic_init()
1918 else if (ps_codec->s_cfg.e_slice_mode == IVE_SLICE_MODE_BLOCKS) in ih264e_pic_init()
1928 if (i4_mb_y +(WORD32)ps_codec->s_cfg.u4_slice_param < ps_proc->i4_ht_mbs) in ih264e_pic_init()
1930 cnt = ps_codec->s_cfg.u4_slice_param * ps_proc->i4_wd_mbs; in ih264e_pic_init()
1931 i4_mb_y += ps_codec->s_cfg.u4_slice_param; in ih264e_pic_init()
1960 if (ps_codec->pic_type == PIC_B) in ih264e_pic_init()
1990 ps_proc->i4_encode_api_call_cnt = ps_codec->i4_encode_api_call_cnt; in ih264e_pic_init()
1993 ps_proc->i4_pic_cnt = ps_codec->i4_pic_cnt; in ih264e_pic_init()
2011 ps_entropy->i4_gen_header = ps_codec->i4_gen_header; in ih264e_pic_init()
2014 ps_entropy->u4_sps_id = ps_codec->i4_sps_id; in ih264e_pic_init()
2017 ps_entropy->ps_sps_base = ps_codec->ps_sps_base; in ih264e_pic_init()
2020 ps_entropy->u4_pps_id = ps_codec->i4_pps_id; in ih264e_pic_init()
2023 ps_entropy->ps_pps_base = ps_codec->ps_pps_base; in ih264e_pic_init()
2032 ps_entropy->i4_abs_pic_order_cnt = ps_proc->ps_codec->i4_poc; in ih264e_pic_init()
2057 ps_codec->s_cfg.u4_entropy_coding_mode; in ih264e_pic_init()
2069 ps_proc->s_entropy.i4_pic_cnt = ps_codec->i4_pic_cnt; in ih264e_pic_init()
2102 ps_codec->s_cfg.u4_srch_rng_x; in ih264e_pic_init()
2106 ps_codec->s_cfg.u4_srch_rng_y; in ih264e_pic_init()
2109 ps_me_ctxt->i4_rec_strd = ps_codec->i4_rec_strd; in ih264e_pic_init()
2124 ps_me_ctxt->u4_enable_hpel = ps_codec->s_cfg.u4_enable_hpel; in ih264e_pic_init()
2131 ps_codec->s_cfg.u4_me_speed_preset; in ih264e_pic_init()
2134 ps_me_ctxt->u1_mb_qp = ps_codec->u4_frame_qp; in ih264e_pic_init()
2136 if ((i == j) && (0 == ps_codec->i4_poc)) in ih264e_pic_init()
2148 ps_codec->i4_gen_header = 0; in ih264e_pic_init()
2165 s_job.i2_mb_cnt = ps_codec->s_cfg.i4_wd_mbs; in ih264e_pic_init()
2173 for (i = 0; i < (WORD32)ps_codec->s_cfg.i4_ht_mbs; i++) in ih264e_pic_init()
2179 ret = ih264_list_queue(ps_codec->pv_proc_jobq, &s_job, 1); in ih264e_pic_init()
2182 ps_codec->i4_error_code = ret; in ih264e_pic_init()
2190 ih264_list_terminate(ps_codec->pv_proc_jobq); in ih264e_pic_init()