diff options
| author | android-build-team Robot <android-build-team-robot@google.com> | 2021-01-13 23:48:50 +0000 |
|---|---|---|
| committer | android-build-team Robot <android-build-team-robot@google.com> | 2021-01-13 23:48:50 +0000 |
| commit | c79b671a447399f56c1dce5dcc90907584329c52 (patch) | |
| tree | 285e64e74e80a1bde811cad45280c74ed616f028 /encoder | |
| parent | 7247e6e4017e540e6b2a99f728362ee997af58b0 (diff) | |
| parent | 75eb07f0dbf1769bf8e4871018ae4556ad699f7a (diff) | |
| download | platform_external_libhevc-android11-mainline-conscrypt-release.tar.gz platform_external_libhevc-android11-mainline-conscrypt-release.tar.bz2 platform_external_libhevc-android11-mainline-conscrypt-release.zip | |
Snap for 7080740 from 75eb07f0dbf1769bf8e4871018ae4556ad699f7a to mainline-conscrypt-releaseandroid-mainline-11.0.0_r31android-mainline-11.0.0_r20android11-mainline-conscrypt-release
Change-Id: Id00c6ca2bde49667117ac6d4122f27cf6fed16d6
Diffstat (limited to 'encoder')
| -rw-r--r-- | encoder/ihevce_lap_interface.c | 2 | ||||
| -rw-r--r-- | encoder/ihevce_rc_interface.c | 24 |
2 files changed, 16 insertions, 10 deletions
diff --git a/encoder/ihevce_lap_interface.c b/encoder/ihevce_lap_interface.c index 4ace17a..9112e1d 100644 --- a/encoder/ihevce_lap_interface.c +++ b/encoder/ihevce_lap_interface.c @@ -1710,7 +1710,7 @@ void ihevce_pre_rel_lapout_update(lap_struct_t *ps_lap_struct, ihevce_lap_enc_bu } ps_lap_struct->pv_prev_inp_buf = (void *)ps_lap_out_buf; - ps_lap_out_buf->s_lap_out.i4_is_prev_pic_in_Tid0_same_scene = 0; + ps_lap_out_buf->s_lap_out.i4_is_prev_pic_in_Tid0_same_scene = 1; /*with force idr below check is not valid*/ #if(!FORCE_IDR_TEST) diff --git a/encoder/ihevce_rc_interface.c b/encoder/ihevce_rc_interface.c index 17ffa78..71be434 100644 --- a/encoder/ihevce_rc_interface.c +++ b/encoder/ihevce_rc_interface.c @@ -4929,13 +4929,11 @@ void ihevce_rc_store_retrive_update_info( &ps_rc_ctxt->as_rc_lap_out[i4_enc_frm_id_rc], ps_rc_lap_out, sizeof(rc_lap_out_params_t)); - //BUG_FIX related to the releasing of the next lap out buffers and retrieving of the data for the delayed update. { - rc_lap_out_params_t *ps_rc_lap_out_next_encode; - ps_rc_lap_out_next_encode = - (rc_lap_out_params_t *)((rc_lap_out_params_t *)ps_rc_lap_out) - ->ps_rc_lap_out_next_encode; + rc_lap_out_params_t *ps_rc_lap_out_curr = (rc_lap_out_params_t *)ps_rc_lap_out; + rc_lap_out_params_t *ps_rc_lap_out_next_encode = + (rc_lap_out_params_t *)ps_rc_lap_out_curr->ps_rc_lap_out_next_encode; if(NULL != ps_rc_lap_out_next_encode) { @@ -4946,12 +4944,20 @@ void ihevce_rc_store_retrive_update_info( } else { - ps_rc_ctxt->as_rc_lap_out[i4_enc_frm_id_rc].i4_next_pic_type = -1; + if(ps_rc_ctxt->u4_intra_frame_interval <= 1 || + (ps_rc_lap_out_curr->i4_rc_display_num && + (ps_rc_lap_out_curr->i4_rc_display_num % + (ps_rc_ctxt->u4_intra_frame_interval - 1)) == 0)) + { + ps_rc_ctxt->as_rc_lap_out[i4_enc_frm_id_rc].i4_next_pic_type = IV_I_FRAME; + } + else + { + ps_rc_ctxt->as_rc_lap_out[i4_enc_frm_id_rc].i4_next_pic_type = -1; + } ps_rc_ctxt->as_rc_lap_out[i4_enc_frm_id_rc].i4_next_scene_type = -1; } - - ps_rc_ctxt->as_rc_lap_out[i4_enc_frm_id_rc].ps_rc_lap_out_next_encode = - NULL; //RC_BUG_FIX + ps_rc_ctxt->as_rc_lap_out[i4_enc_frm_id_rc].ps_rc_lap_out_next_encode = NULL; } } else if(2 == i4_store_retrive) |
