1.合并原厂偏色修改
This commit is contained in:
parent
a582922f6e
commit
7b0be70d03
|
@ -1917,8 +1917,8 @@ DBG_WRN(">>>>>>>>>>>>>>> movie thread <<<<<<<<<<\r\n");
|
|||
/*.............sun chen@20240111 end.................*/
|
||||
|
||||
|
||||
//nvt_cmdsys_runcmd("ae dbg 0 256 1 ");
|
||||
|
||||
nvt_cmdsys_runcmd("ae dbg 0 256 1 ");
|
||||
nvt_cmdsys_runcmd("awb dbg 0 16 1 ");
|
||||
HD_VIDEO_FRAME frame_capture = {0};
|
||||
|
||||
VOS_TICK t1, t2;
|
||||
|
@ -2001,7 +2001,7 @@ DBG_WRN(">>>>>>>>>>>>>>> movie thread <<<<<<<<<<\r\n");
|
|||
|
||||
|
||||
memcpy((void*)&frame_capture, (void*)&frame, sizeof(HD_VIDEO_FRAME));
|
||||
|
||||
|
||||
break;
|
||||
}
|
||||
else{
|
||||
|
@ -2012,6 +2012,7 @@ DBG_WRN(">>>>>>>>>>>>>>> movie thread <<<<<<<<<<\r\n");
|
|||
|
||||
vos_perf_mark(&g_alg_end_time);
|
||||
}
|
||||
vos_util_delay_ms(33);
|
||||
|
||||
if ((g_moviefast_power_off_tsk_id = vos_task_create(MovieFast_PowerOffTsk, 0, "MovieFastPwrTsk", PRI_MOVIEFAST_CMDTSK, STKSIZE_MOVIEFAST_CMDTSK)) == 0) {
|
||||
DBG_ERR("MovieFast_PowerOffTsk create failed.\r\n");
|
||||
|
@ -2169,7 +2170,7 @@ DBG_WRN(">>>>>>>>>>>>>>> movie thread <<<<<<<<<<\r\n");
|
|||
// UINT32 elapse_time_ms = ((t2 - t1) / 1000);
|
||||
|
||||
CHKPNT;
|
||||
vos_util_delay_ms(300);
|
||||
vos_util_delay_ms(234);//(300);
|
||||
// if(elapse_time_ms < 300)
|
||||
// vos_util_delay_ms(300 - elapse_time_ms);
|
||||
|
||||
|
|
|
@ -1787,8 +1787,34 @@ THREAD_RETTYPE PhotoFast_FlowPreviewThread(void *arg)
|
|||
DBG_DUMP("period = %lu ms, max_cnt = %lu\n", period, max_cnt);
|
||||
|
||||
PhotoFast_SliceEncode2_Open(vprc_path, max_cnt);
|
||||
nvt_cmdsys_runcmd("ae set_speed 0 128 200 200 100");
|
||||
|
||||
/*.............sun chen@20240111 start.................*/
|
||||
//nvt_cmdsys_runcmd("ae set_speed 0 128 200 200 100");
|
||||
//nvt_cmdsys_runcmd("ae set_speed 0 128 900 900 800");
|
||||
//nvt_cmdsys_runcmd("ae set_pdctrl 0 32 0 32 0");
|
||||
{
|
||||
AET_EXTEND_PARAM ext_param = {0};
|
||||
ext_param.id = 0;
|
||||
ext_param.ext_param.dgain_th = 128;
|
||||
ext_param.ext_param.dgain_mode = 0;
|
||||
ext_param.ext_param.down_speed = 970;
|
||||
ext_param.ext_param.up_speed1 = 965;
|
||||
ext_param.ext_param.up_speed2 = 800;
|
||||
ext_param.ext_param.hdr_ev = 0;
|
||||
ext_param.ext_param.fast_ae = 1;
|
||||
vendor_isp_set_ae(AET_ITEM_EXT_PARAM, &ext_param);
|
||||
}
|
||||
// nvt_cmdsys_runcmd("ae dbg 0 256 1 ");
|
||||
//nvt_cmdsys_runcmd("ae dbg 0 16 1");
|
||||
|
||||
{
|
||||
AET_CONVERGENCE convergence = {0};
|
||||
convergence.id = 0;
|
||||
vendor_isp_get_ae(AET_ITEM_CONVERGENCE, &convergence);
|
||||
// DBG_DUMP("==============to : %d %d \r\n", convergence.convergence.range_conv.h, convergence.convergence.range_conv.l);
|
||||
convergence.convergence.skip_frame = 3;
|
||||
vendor_isp_set_ae(AET_ITEM_CONVERGENCE, &convergence);
|
||||
}
|
||||
/*.............sun chen@20240111 end.................*/
|
||||
#endif
|
||||
#if (FASTCAPTURE_AE_DEBUG == 1)
|
||||
if (g_vcap_frm_cnt == 1){
|
||||
|
@ -1797,7 +1823,8 @@ THREAD_RETTYPE PhotoFast_FlowPreviewThread(void *arg)
|
|||
// nvt_cmdsys_runcmd("vprc info");
|
||||
// nvt_cmdsys_runcmd("ctl_ipp dump_hdl_all");
|
||||
//ISPT_TOTAL_GAIN total;
|
||||
// nvt_cmdsys_runcmd("ae dbg 0 256 1 ");
|
||||
nvt_cmdsys_runcmd("ae dbg 0 256 1 ");
|
||||
nvt_cmdsys_runcmd("ae dbg 0 16 1 ");
|
||||
// isp_dbg_set_dbg_mode(0, 0x0202002 );
|
||||
|
||||
// nvt_cmdsys_runcmd("iq dbg 0 0 ");
|
||||
|
@ -1990,12 +2017,12 @@ THREAD_RETTYPE PhotoFast_FlowPreviewThread(void *arg)
|
|||
*
|
||||
* 2. third frame since ae preset
|
||||
******************************************************************************************/
|
||||
if(((g_vcap_frm_cnt >= PHOTOFAST_START_CAP_FRAME_CNT) || (g_ae_preset_flag == TRUE && g_vprc_frm_cnt >= (g_vprc_frm_cnt_ae_preset + 3))) && (start_cap == FALSE)){
|
||||
if(((g_vcap_frm_cnt >= PHOTOFAST_START_CAP_FRAME_CNT) || (g_ae_preset_flag == TRUE && g_vprc_frm_cnt >= (g_vprc_frm_cnt_ae_preset + 5))) && (start_cap == FALSE)){
|
||||
|
||||
if(g_vcap_frm_cnt >= PHOTOFAST_START_CAP_FRAME_CNT){
|
||||
DBG_DUMP("triggered by PHOTOFAST_START_CAP_FRAME_CNT\n");
|
||||
}
|
||||
else if(g_ae_preset_flag == TRUE && g_vprc_frm_cnt >= (g_vprc_frm_cnt_ae_preset + 3)){
|
||||
else if(g_ae_preset_flag == TRUE && g_vprc_frm_cnt >= (g_vprc_frm_cnt_ae_preset + 5)){
|
||||
DBG_DUMP("triggered by AE preset\n");
|
||||
}
|
||||
|
||||
|
@ -2388,14 +2415,17 @@ void Set_NIGHTMODE(UINT32 id, UINT8 isSnapVideo)
|
|||
}
|
||||
*/
|
||||
}
|
||||
|
||||
/*.............sun chen@20240111 start.................*/
|
||||
extern UINT32 jpgexifiso,jpgexifexp;
|
||||
void Set_AEMODE(UINT32 id)
|
||||
{
|
||||
AET_MANUAL ae_manual = {0};
|
||||
AWBT_STATUS status = {0};
|
||||
AWBT_STATUS awbstatus = {0};
|
||||
AWBT_MANUAL awbmanual = {0};
|
||||
ISPT_C_GAIN c_gain = {0};
|
||||
|
||||
HD_RESULT hd_ret;
|
||||
#if HUNTING_CAMERA_MCU == ENABLE
|
||||
#if 0//HUNTING_CAMERA_MCU == ENABLE
|
||||
UIMenuStoreInfo *puiPara = sf_ui_para_get();
|
||||
#endif
|
||||
|
||||
|
@ -2407,14 +2437,21 @@ void Set_AEMODE(UINT32 id)
|
|||
if (1)//SysGetFlag(FL_CONTINUE_SHOT) == CONTINUE_SHOT_BURST_5)
|
||||
{
|
||||
ae_status.id = 0;
|
||||
awbstatus.id = 0;
|
||||
vendor_isp_get_ae(AET_ITEM_STATUS, &ae_status);
|
||||
vendor_isp_get_awb(AWBT_ITEM_STATUS, &awbstatus);
|
||||
//DBG_ERR(">> aet status exp %d iso %d\r\n",ae_status_info.status_info.expotime[0],ae_status_info.status_info.iso_gain[0]);
|
||||
ae_manual.id = 0;
|
||||
awbmanual.id = 0;
|
||||
vendor_isp_get_ae(AET_ITEM_MANUAL, &ae_manual);
|
||||
vendor_isp_get_awb(AWBT_ITEM_MANUAL, &awbmanual);
|
||||
//DBG_ERR(">> aet manual exp %d iso %d\r\n",ae_manual.manual.expotime,ae_manual.manual.iso_gain);
|
||||
jpgexifiso = ae_status.status_info.iso_gain[0];
|
||||
jpgexifexp = ae_status.status_info.expotime[0];
|
||||
if (id == 1){
|
||||
ae_manual.manual.mode = 1;
|
||||
#if HUNTING_CAMERA_MCU == ENABLE
|
||||
awbmanual.manual.en = 1;
|
||||
#if 0//HUNTING_CAMERA_MCU == ENABLE
|
||||
if(puiPara->CamMode == SF_CAM_MODE_VIDEO2)
|
||||
{
|
||||
ae_manual.manual.expotime = 33333;
|
||||
|
@ -2437,6 +2474,12 @@ void Set_AEMODE(UINT32 id)
|
|||
ae_manual.manual.expotime = ae_status.status_info.expotime[0];
|
||||
ae_manual.manual.iso_gain = ae_status.status_info.iso_gain[0];
|
||||
#endif
|
||||
|
||||
awbmanual.manual.r_gain = awbstatus.status.cur_r_gain;
|
||||
awbmanual.manual.g_gain = awbstatus.status.cur_g_gain;
|
||||
awbmanual.manual.b_gain = awbstatus.status.cur_b_gain;
|
||||
|
||||
|
||||
/*ISPT_TOTAL_GAIN total;
|
||||
|
||||
total.id = 0;
|
||||
|
@ -2446,27 +2489,30 @@ void Set_AEMODE(UINT32 id)
|
|||
}
|
||||
else {
|
||||
ae_manual.manual.mode = 0;
|
||||
awbmanual.manual.en = 0;
|
||||
}
|
||||
//DBG_ERR(">> >>>>>>>>>aet manual mode %d\r\n",ae_manual.manual.mode);
|
||||
DBG_WRN(">> >>>>>>>>>aet manual mode %d\r\n",ae_manual.manual.mode);
|
||||
|
||||
vendor_isp_set_ae(AET_ITEM_MANUAL, &ae_manual);
|
||||
|
||||
vendor_isp_set_awb(AWBT_ITEM_MANUAL, &awbmanual);
|
||||
#if HUNTING_CAMERA_MCU == ENABLE
|
||||
if(sf_is_night_mode(0) ==FALSE){
|
||||
#else
|
||||
{
|
||||
#endif
|
||||
status.id = 0;
|
||||
vendor_isp_get_awb(AWBT_ITEM_STATUS, &status);
|
||||
//status.id = 0;
|
||||
//vendor_isp_get_awb(AWBT_ITEM_STATUS, &status);
|
||||
|
||||
c_gain.id = 0;
|
||||
|
||||
c_gain.gain[0] = status.status.cur_r_gain;
|
||||
c_gain.gain[1] = status.status.cur_g_gain;
|
||||
c_gain.gain[2] = status.status.cur_b_gain;
|
||||
c_gain.gain[0] = awbstatus.status.cur_r_gain;
|
||||
c_gain.gain[1] = awbstatus.status.cur_g_gain;
|
||||
c_gain.gain[2] = awbstatus.status.cur_b_gain;
|
||||
vendor_isp_set_common(ISPT_ITEM_C_GAIN, &c_gain);
|
||||
DBG_WRN(">>>>>>>>>>>>>>>>set c gain\r\n");
|
||||
}
|
||||
}
|
||||
/*.............sun chen@20240111 end.................*/
|
||||
if ((hd_ret = vendor_isp_uninit()) != HD_OK) {
|
||||
DBG_ERR("vendor_isp_uninit() fail(%d)\r\n", hd_ret);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user