本文整理汇总了C++中ISP_DBG函数的典型用法代码示例。如果您正苦于以下问题:C++ ISP_DBG函数的具体用法?C++ ISP_DBG怎么用?C++ ISP_DBG使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了ISP_DBG函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: util_bcc_cmd_debug
/** util_bcc_cmd_debug:
* @cmd: Pointer to statistic configuration.
*
* Print mce configuration.
*
* This function executes in ISP thread context
*
* Return none.
**/
static void util_bcc_cmd_debug(ISP_DemosaicDBCC_CmdType *cmd)
{
ISP_DBG(ISP_MOD_BCC, "%s: cmd->fminThreshold = %d \n", __func__, cmd->fminThreshold);
ISP_DBG(ISP_MOD_BCC, "%s: cmd->fmaxThreshold = %d \n", __func__, cmd->fmaxThreshold);
ISP_DBG(ISP_MOD_BCC, "%s: cmd->rOffsetHi = %d \n", __func__, cmd->rOffsetHi);
ISP_DBG(ISP_MOD_BCC, "%s: cmd->rOffsetLo = %d \n", __func__, cmd->rOffsetLo);
ISP_DBG(ISP_MOD_BCC, "%s: cmd->bOffsetHi = %d \n", __func__, cmd->bOffsetHi);
ISP_DBG(ISP_MOD_BCC, "%s: cmd->bOffsetLo = %d \n", __func__, cmd->bOffsetLo);
ISP_DBG(ISP_MOD_BCC, "%s: cmd->grOffsetHi = %d \n", __func__, cmd->grOffsetHi);
ISP_DBG(ISP_MOD_BCC, "%s: cmd->grOffsetLo = %d \n", __func__, cmd->grOffsetLo);
ISP_DBG(ISP_MOD_BCC, "%s: cmd->gbOffsetHi = %d \n", __func__, cmd->gbOffsetHi);
ISP_DBG(ISP_MOD_BCC, "%s: cmd->gbOffsetLo = %d \n", __func__, cmd->gbOffsetLo);
} /* util_bcc_cmd_debug */
示例2: sce_set_bestshot
/** sce_set_bestshot
* @mod: module instance data
* @pix_settings: pix data
* @in_param_size: parameter size
*
* Sets configures SCE module according bestshot mode.
**/
static int sce_set_bestshot(isp_sce_mod_t *mod,
isp_hw_pix_setting_params_t *pix_settings, uint32_t in_param_size)
{
int rc = 0;
isp_mod_set_enable_t tEnable;
if (in_param_size != sizeof(isp_hw_pix_setting_params_t)) {
CDBG_ERROR("%s: size mismatch, expecting = %d, received = %d", __func__,
sizeof(isp_mod_set_enable_t), in_param_size);
return -1;
}
ISP_DBG(ISP_MOD_SCE, "%s: Bestshot mode: %d", __func__, pix_settings->bestshot_mode);
switch (pix_settings->bestshot_mode) {
case CAM_SCENE_MODE_PORTRAIT:
case CAM_SCENE_MODE_PARTY:
case CAM_SCENE_MODE_THEATRE:
case CAM_SCENE_MODE_AUTO: {
tEnable.enable = TRUE;
rc = sce_enable(mod, &tEnable, sizeof(isp_mod_set_enable_t));
if (rc != 0) {
ISP_DBG(ISP_MOD_SCE, "%s: cannot enable SCE", __func__);
break;
}
rc = sce_trigger_enable(mod, &tEnable, sizeof(isp_mod_set_enable_t));
if (rc != 0) {
ISP_DBG(ISP_MOD_SCE, "%s: cannot enable trigger", __func__);
}
}
break;
default:
tEnable.enable = TRUE;
/* we have to restore the neutral skin factor */
mod->sce_adjust_factor = 0;
rc = sce_enable(mod, &tEnable, sizeof(isp_mod_set_enable_t));
if (rc != 0) {
ISP_DBG(ISP_MOD_SCE, "%s: cannot disable SCE", __func__);
break;
}
rc = sce_trigger_enable(mod, &tEnable, sizeof(isp_mod_set_enable_t));
if (rc != 0)
ISP_DBG(ISP_MOD_SCE, "%s: cannot disable trigger", __func__);
break;
}
return rc;
}
示例3: bcc_config
/** bcc_config
* @mod: bcc module control strcut
* @in_params: contains chromatix ptr
* @in_param_size: in params struct size
*
* bcc module configuration initial settings
*
* Return: 0 - success and negative value - failure
**/
static int bcc_config(isp_bcc_mod_t *mod,
isp_hw_pix_setting_params_t *in_params, uint32_t in_param_size)
{
int rc = 0;
chromatix_parms_type *chromatix_ptr =
(chromatix_parms_type *)in_params->chromatix_ptrs.chromatixPtr;
chromatix_BPC_type *chromatix_BPC =
&chromatix_ptr->chromatix_VFE.chromatix_BPC;
if (in_param_size != sizeof(isp_hw_pix_setting_params_t)) {
/* size mismatch */
CDBG_ERROR("%s: size mismatch, expecting = %d, received = %d",
__func__, sizeof(isp_hw_pix_setting_params_t), in_param_size);
return -1;
}
ISP_DBG(ISP_MOD_BCC, "%s: enter", __func__);
if (!mod->enable) {
ISP_DBG(ISP_MOD_BCC, "%s: Mod not Enable.", __func__);
return rc;
}
if ((chromatix_BPC->bcc_Fmin > chromatix_BPC->bcc_Fmax) ||
(chromatix_BPC->bcc_Fmin_lowlight > chromatix_BPC->bcc_Fmax_lowlight)) {
CDBG_ERROR("%s: Error min>max: %d/%d; %d/%d\n", __func__,
chromatix_BPC->bcc_Fmin, chromatix_BPC->bcc_Fmax,
chromatix_BPC->bcc_Fmin_lowlight, chromatix_BPC->bcc_Fmax_lowlight);
return -1;
}
/* set old cfg to invalid value to trigger the first trigger update */
mod->old_streaming_mode = CAM_STREAMING_MODE_MAX;
mod->p_params.p_input_offset =
&(chromatix_BPC->bcc_4_offset[BPC_NORMAL_LIGHT]);
mod->p_params.Fmin = chromatix_BPC->bcc_Fmin;
mod->p_params.Fmax = chromatix_BPC->bcc_Fmax;
util_bcc_cmd_config(mod);
mod->enable = TRUE;
mod->trigger_enable = TRUE;
mod->aec_ratio = 0;
mod->skip_trigger = FALSE;
mod->hw_update_pending = TRUE;
return rc;
} /* bcc_config */
示例4: bf_stats_do_hw_update
/** bf_stats_do_hw_update:
* @entry: Pointer to entry struct for bf stats
*
* Method called at SOF, writes the value in reg_cmd to HW register
*
*
* Return 0 on Success, negative on ERROR
**/
static int bf_stats_do_hw_update(isp_stats_entry_t *entry)
{
int rc = 0;
ISP_StatsBf_CfgCmdType *pcmd = entry->reg_cmd;
struct msm_vfe_cfg_cmd2 cfg_cmd;
struct msm_vfe_reg_cfg_cmd reg_cfg_cmd[1];
ISP_DBG(ISP_MOD_STATS, "%s: E, hw_update = %d\n", __func__, entry->hw_update_pending);
vfe_bf_stats_debug(pcmd);
if (entry->hw_update_pending) {
cfg_cmd.cfg_data = (void *)entry->reg_cmd;
cfg_cmd.cmd_len = sizeof(ISP_StatsBf_CfgCmdType);
cfg_cmd.cfg_cmd = (void *) reg_cfg_cmd;
cfg_cmd.num_cfg = 1;
reg_cfg_cmd[0].u.rw_info.cmd_data_offset = 0;
reg_cfg_cmd[0].cmd_type = VFE_WRITE;
reg_cfg_cmd[0].u.rw_info.reg_offset = BF_STATS_OFF;
reg_cfg_cmd[0].u.rw_info.len = BF_STATS_LEN * sizeof(uint32_t);
rc = ioctl(entry->fd, VIDIOC_MSM_VFE_REG_CFG, &cfg_cmd);
if (rc < 0){
CDBG_ERROR("%s: HW update error, rc = %d", __func__, rc);
return rc;
}
entry->hw_update_pending = 0;
}
return rc;
}
示例5: color_correct_set_bestshot
/** color_correct_set_bestshot:
* @mod: pointer to instance private data
* @in_params: input data
* @in_params_size: size of input data
*
* Set scene.
*
* This function executes in ISP thread context
*
* Return 0 on success.
**/
static int color_correct_set_bestshot(isp_color_correct_mod_t *mod,
isp_hw_pix_setting_params_t *in_params, uint32_t in_param_size)
{
cam_scene_mode_type mode = in_params->bestshot_mode;
mod->skip_trigger = FALSE;
if (in_param_size != sizeof(isp_hw_pix_setting_params_t)) {
/* size mismatch */
CDBG_ERROR("%s: size mismatch, expecting = %d, received = %d",
__func__, sizeof(isp_hw_pix_setting_params_t), in_param_size);
return -1;
}
ISP_DBG(ISP_MOD_COLOR_CORRECT, "%s: mode %d", __func__, mode);
switch (mode) {
case CAM_SCENE_MODE_NIGHT:
mod->final_table = mod->table.chromatix_yhi_ylo_color_correction;
break;
default:
mod->final_table = mod->table.chromatix_TL84_color_correction;
break;
}
mod->hw_update_pending = TRUE;
return 0;
} /* color_correct_set_bestshot */
示例6: linearization_config
/*===========================================================================
* FUNCTION - linearization_config -
*
* DESCRIPTION:
*==========================================================================*/
static int linearization_config(isp_linear_mod_t *linear_mod, isp_hw_pix_setting_params_t *pix_settings,
uint32_t in_param_size)
{
int rc = 0;
uint32_t i;
chromatix_VFE_common_type *pchromatix_common =
(chromatix_VFE_common_type *)pix_settings->chromatix_ptrs.chromatixComPtr;
chromatix_L_type *pchromatix_L =
&pchromatix_common->chromatix_L;
ISP_DBG(ISP_MOD_LINEARIZATION , "%s\n",__func__);
if (in_param_size != sizeof(isp_hw_pix_setting_params_t)) {
/* size mismatch */
CDBG_ERROR("%s: size mismatch, expecting = %d, received = %d",
__func__, sizeof(isp_hw_pix_setting_params_t), in_param_size);
return -1;
}
config_linearization_cmd(linear_mod,
&(pchromatix_L->linear_table_TL84_normal));
linear_mod->hw_update_pending = TRUE;
linear_mod->prev_cct_type = AWB_CCT_TYPE_TL84;
linear_mod->prev_lux = LINEAR_AEC_NORMAL;
linear_mod->old_streaming_mode = CAM_STREAMING_MODE_MAX;
linear_mod-> prev_lux_idx = 0;
linear_mod->hw_update_pending = TRUE;
return rc;
}
示例7: color_correct_set_effect
/** color_correct_set_effect:
* @mod: pointer to instance private data
* @in_params: input data
* @in_params_size: size of input data
*
* Set effect.
*
* This function executes in ISP thread context
*
* Return 0 on success.
**/
static int color_correct_set_effect(isp_color_correct_mod_t *mod,
isp_hw_pix_setting_params_t *in_params, uint32_t in_param_size)
{
int type;
float s;
if (in_param_size != sizeof(isp_hw_pix_setting_params_t)) {
/* size mismatch */
CDBG_ERROR("%s: size mismatch, expecting = %d, received = %d",
__func__, sizeof(isp_hw_pix_setting_params_t), in_param_size);
return -1;
}
if (!mod->enable) {
ISP_DBG(ISP_MOD_COLOR_CORRECT, "%s: CC not enabled", __func__);
return 0;
}
type = in_params->effects.effect_type_mask;
SET_UNITY_MATRIX(mod->effects_matrix, 3);
if (type & (1 << ISP_EFFECT_SATURATION)) {
s = 2.0 * in_params->effects.saturation;
if (F_EQUAL(in_params->effects.hue, 0))
util_color_correct_populate_matrix(mod->effects_matrix, s);
}
if (type & (1 << ISP_EFFECT_HUE)) {
s = 2.0 * in_params->effects.hue;
if (!F_EQUAL(in_params->effects.saturation, .5))
util_color_correct_populate_matrix(mod->effects_matrix, s);
}
mod->hw_update_pending = TRUE;
return 0;
} /*color_correct_set_effect*/
示例8: ihist_stats_trigger_enable
/** ihist_stats_trigger_enable:
* @entry: Pointer to entry struct of ihist stats
* @in_params: Input params
*
* Set the trigger enable
*
*
* Return 0 on Success, negative on ERROR
**/
static int ihist_stats_trigger_enable(isp_stats_entry_t *entry,
isp_mod_set_enable_t *in_params)
{
ISP_DBG(ISP_MOD_STATS, "%s: trigger_enable = %d\n", __func__, in_params->enable);
entry->trigger_enable = in_params->enable;
return 0;
}
示例9: sce_do_hw_update
/** sce_do_hw_update
*
* description: sce_do_hw_update
*
**/
static int sce_do_hw_update(isp_sce_mod_t *sce_mod)
{
int i, rc = 0;
struct msm_vfe_cfg_cmd2 cfg_cmd;
struct msm_vfe_reg_cfg_cmd reg_cfg_cmd[1];
ISP_DBG(ISP_MOD_SCE, "%s: E: hw_update = %d\n", __func__, sce_mod->hw_update_pending);
if (sce_mod->hw_update_pending) {
cfg_cmd.cfg_data = (void *) &sce_mod->sce_cmd;
cfg_cmd.cmd_len = sizeof(sce_mod->sce_cmd);
cfg_cmd.cfg_cmd = (void *) reg_cfg_cmd;
cfg_cmd.num_cfg = 1;
reg_cfg_cmd[0].u.rw_info.cmd_data_offset = 0;
reg_cfg_cmd[0].cmd_type = VFE_WRITE;
reg_cfg_cmd[0].u.rw_info.reg_offset = ISP_SCE40_OFF;
reg_cfg_cmd[0].u.rw_info.len = ISP_SCE40_LEN * sizeof(uint32_t);
//isp_sce_debug(&sce_mod);
rc = ioctl(sce_mod->fd, VIDIOC_MSM_VFE_REG_CFG, &cfg_cmd);
if (rc < 0){
CDBG_ERROR("%s: HW update error, rc = %d", __func__, rc);
return rc;
}
sce_mod->sce_cmd = sce_mod->applied_sce_cmd;
sce_mod->hw_update_pending = 0;
}
return rc;
}
示例10: isp44_util_get_awb_cct_type
/** isp44_util_get_awb_cct_type
*
* @trigger:
* @chromatix_ptr:
*
**/
static awb_cct_type isp44_util_get_awb_cct_type(cct_trigger_info* trigger,
void *chromatix_ptr)
{
chromatix_parms_type *p_chromatix = chromatix_ptr;
awb_cct_type cct_type = AWB_CCT_TYPE_TL84;
ISP_DBG(ISP_MOD_COM,"%s: CCT %f D65 %f %f A %f %f", __func__,
trigger->mired_color_temp,
trigger->trigger_d65.mired_end,
trigger->trigger_d65.mired_start,
trigger->trigger_A.mired_start,
trigger->trigger_A.mired_end);
if (trigger->mired_color_temp <= trigger->trigger_d65.mired_end) {
cct_type = AWB_CCT_TYPE_D65;
} else if ((trigger->mired_color_temp > trigger->trigger_d65.mired_end) &&
(trigger->mired_color_temp <= trigger->trigger_d65.mired_start)) {
cct_type = AWB_CCT_TYPE_D65_TL84;
} else if ((trigger->mired_color_temp >= trigger->trigger_A.mired_start) &&
(trigger->mired_color_temp < trigger->trigger_A.mired_end)) {
cct_type = AWB_CCT_TYPE_TL84_A;
} else if (trigger->mired_color_temp >= trigger->trigger_A.mired_end) {
cct_type = AWB_CCT_TYPE_A;
}
/* else its TL84*/
return cct_type;
} /*isp_util_get_awb_cct_type*/
示例11: color_xform_action
/** color_xform_action
* @mod_ctrl: xform module control struct
* @action_code : action code
* @data: not used
* @data_size: not used
*
* processing the hw action like update or reset
*
* Return: 0 - success and negative value - failure
**/
static int color_xform_action (void *mod_ctrl, uint32_t action_code, void *data,
uint32_t data_size)
{
int rc = 0;
isp_color_xform_mod_t *mod = mod_ctrl;
switch (action_code) {
case ISP_HW_MOD_ACTION_HW_UPDATE: {
rc = color_xform_do_hw_update(mod);
}
break;
case ISP_HW_MOD_ACTION_RESET: {
color_xform_reset(mod);
}
break;
default: {
/* no op */
ISP_DBG(ISP_MOD_COLOR_XFORM, "%s: action code = %d is not supported. nop",
__func__, action_code);
rc = 0;
}
break;
}
return rc;
} /* color_xform_action */
示例12: color_conversion_set_chromatix
/** color_conversion_set_chromatix:
*
* @mod:
* @in_params:
* @in_param_size:
*
* set chromatix info to modules
*
**/
static int color_conversion_set_chromatix(isp_color_conversion_mod_t *mod,
isp_hw_pix_setting_params_t *in_params, uint32_t in_param_size)
{
if (in_param_size != sizeof(isp_hw_pix_setting_params_t)) {
/* size mismatch */
CDBG_ERROR("%s: size mismatch, expecting = %d, received = %d",
__func__, sizeof(isp_hw_pix_setting_params_t), in_param_size);
return -1;
}
chromatix_parms_type *chromatix_ptr =
in_params->chromatix_ptrs.chromatixPtr;
chromatix_CV_type *chromatix_CV_ptr =
&chromatix_ptr->chromatix_VFE.chromatix_CV;
ISP_DBG(ISP_MOD_COLOR_CONV, "%s:", __func__);
SET_UNITY_MATRIX(mod->effects_matrix, 2);
mod->cv_data = chromatix_CV_ptr->TL84_color_conversion;
mod->p_cv = &chromatix_CV_ptr->TL84_color_conversion;
mod->hw_update_pending = TRUE;
return 0;
}
示例13: bf_stats_get_params
/** bf_stats_get_params:
* @ctrl: Pointer to entry (ctrl) struct
* @param_id: event id indicating what param to get
* @in_params: input params
* @in_param_size: Size of Input Params
* @out_params: output params
* @out_param_size: size of output params
*
* Get value of parameter given by param id
*
*
* Return 0 for Success, negative if ERROR
**/
static int bf_stats_get_params (void *ctrl, uint32_t param_id,
void *in_params, uint32_t in_param_size,
void *out_params, uint32_t out_param_size)
{
isp_stats_entry_t *entry = ctrl;
int rc = 0;
ISP_DBG(ISP_MOD_STATS, "%s: param_id = %d\n", __func__, param_id);
switch (param_id) {
case ISP_STATS_GET_ENABLE:
break;
case ISP_STATS_GET_STREAM_STATE:
break;
case ISP_STATS_GET_PARSED_STATS:
break;
case ISP_STATS_GET_STREAM_HANDLE:{
uint32_t *handle = (uint32_t *) (out_params);
*handle = entry->stream_handle;
break;
}
default:
break;
}
return rc;
}
示例14: isp_tintless_bg_pca_update_chromatix_params
/*===========================================================================
FUNCTION isp_tintless_update_chromatix_params
DESCRIPTION Update the tintless related chromatix tuning parameters.
===========================================================================*/
static tintless_return_t isp_tintless_bg_pca_update_chromatix_params(
void * const res, chromatix_color_tint_correction_type * p)
{
tintless_return_t rc;
tintless_cfg_t param;
tintless_lib_t * const tintless_lib = (tintless_lib_t *) res;
ISP_DBG(ISP_MOD_ROLLOFF,"%s: chromatix : strength %d",__func__,
p->tint_correction_strength);
if (tintless_lib == NULL || tintless_lib->init_func == NULL)
{
rc = TINTLESS_LIB_NOT_LOADED;
} else {
param.chromatix = p;
if (tintless_lib->updates & ( 1 << UPDATES_CHROMATIX_PARAMS)) {
rc = isp_tintless_config(tintless_lib, UPDATES_CHROMATIX_PARAMS, param);
CDBG_ERROR("%s: lib returned config err=%d", __func__, rc);
} else {
CDBG_ERROR("%s: chromatix parameter updates not needed", __func__);
rc = TINTLESS_UPDATES_NOT_SUPPORTED;
}
}
return rc;
} /* isp_tintless_update_chromatix_params */
示例15: color_conversion_config
/** color_conversion_config:
*
* @mod:
* @in_params:
* @in_param_size:
*
* configure initial settings
*
**/
static int color_conversion_config(isp_color_conversion_mod_t *mod, isp_hw_pix_setting_params_t *in_params, uint32_t in_param_size)
{
int rc = 0;
chromatix_parms_type *chromatix_ptr =
(chromatix_parms_type *)in_params->chromatix_ptrs.chromatixPtr;
chromatix_CV_type *chromatix_CV_ptr =
&chromatix_ptr->chromatix_VFE.chromatix_CV;
if (in_param_size != sizeof(isp_hw_pix_setting_params_t)) {
/* size mismatch */
CDBG_ERROR("%s: size mismatch, expecting = %d, received = %d",
__func__, sizeof(isp_hw_pix_setting_params_t), in_param_size);
return -1;
}
ISP_DBG(ISP_MOD_COLOR_CONV, "%s: enter", __func__);
if (!mod->enable) {
CDBG_HIGH("%s: Mod not Enable.", __func__);
return rc;
}
/* set old cfg to invalid value to trigger the first trigger update */
SET_UNITY_MATRIX(mod->effects_matrix, 2);
mod->cv_data = chromatix_CV_ptr->TL84_color_conversion;
mod->p_cv = &(chromatix_CV_ptr->TL84_color_conversion);
util_color_conversion_cmd_config(mod);
mod->hw_update_pending = TRUE;
return rc;
} /* color_conversion_config */