diff --git a/code/application/source/cardv/SrcCode/UIApp/Photo/UIAppPhoto_Exe.c b/code/application/source/cardv/SrcCode/UIApp/Photo/UIAppPhoto_Exe.c index 5583ece76..e2ab80886 100755 --- a/code/application/source/cardv/SrcCode/UIApp/Photo/UIAppPhoto_Exe.c +++ b/code/application/source/cardv/SrcCode/UIApp/Photo/UIAppPhoto_Exe.c @@ -1708,7 +1708,7 @@ void PhotoExe_CommPoolInit(void) // #else // g_photo_mem_cfg.pool_info[id].blk_cnt = 8; // #endif - g_photo_mem_cfg.pool_info[id].blk_cnt = 4; + g_photo_mem_cfg.pool_info[id].blk_cnt = 6; g_photo_mem_cfg.pool_info[id].ddr_id = DDR_ID0; // config common pool (wifi) @@ -4466,8 +4466,11 @@ static INT32 PhotoExe_Preview_SliceEncode_Get_Curr_Dst_Slice_Info(PhotoExe_Slice else{ PHOTO_SLICE_ENC_DUMP("cap_size = %lu buf_size = %lu\n", cap_size, buf_size); - UINT32 lines = (buf_size / cap_size_w); - max_slice_num = cap_size_h / lines + (cap_size_h % lines ? 1 : 0); + // UINT32 lines = (buf_size / cap_size_w); + // max_slice_num = cap_size_h / lines + (cap_size_h % lines ? 1 : 0); + UINT32 lines = (buf_size / cap_size_w); + UINT32 slice_height = ALIGN_CEIL(lines, 16); + max_slice_num = (cap_size_h / slice_height) + (cap_size_h % slice_height ? 1 : 0); UINT32 tmp_src_h = src_frame.dim.h / 2; UINT32 tmp_dst_h = cap_size_h / 16; @@ -4537,8 +4540,11 @@ static INT32 PhotoExe_Preview_SliceEncode_Get_Max_Dst_Slice_Info(PhotoExe_SliceS else{ PHOTO_SLICE_ENC_DUMP("cap_size = %lu buf_size = %lu\n", tmp_cap_size.w * tmp_cap_size.h, buf_size); - UINT32 lines = (buf_size / tmp_cap_size.w); - max_slice_num = tmp_cap_size.h / lines + (tmp_cap_size.h % lines ? 1 : 0); + // UINT32 lines = (buf_size / tmp_cap_size.w); + // max_slice_num = tmp_cap_size.h / lines + (tmp_cap_size.h % lines ? 1 : 0); + UINT32 lines = (buf_size / tmp_cap_size.w); + UINT32 slice_height = ALIGN_CEIL(lines, 16); + max_slice_num = (tmp_cap_size.h / slice_height) + (tmp_cap_size.h % slice_height ? 1 : 0); UINT32 tmp_src_h = sensor_info->sSize.h / 2; UINT32 tmp_dst_h = tmp_cap_size.h / 16;