diff options
Diffstat (limited to 'isp')
| -rw-r--r-- | isp/controls.c | 25 | ||||
| -rw-r--r-- | isp/omap3isp.h | 2 | 
2 files changed, 27 insertions, 0 deletions
| diff --git a/isp/controls.c b/isp/controls.c index c7ceee2..4dc943f 100644 --- a/isp/controls.c +++ b/isp/controls.c @@ -153,6 +153,31 @@ static void matrix_float_to_s12q8(__u16 out[3][3], const struct matrix *in)  }  /* ----------------------------------------------------------------------------- + * CCDC parameters configuration + */ + +int omap3_isp_ccdc_set_black_level(struct omap3_isp_device *isp, unsigned int value) +{ +	struct omap3isp_ccdc_update_config config; +	struct omap3isp_ccdc_bclamp bclamp; +	int ret; + +	memset(&config, 0, sizeof config); +	config.update = OMAP3ISP_CCDC_BLCLAMP; +	config.flag = 0; +	config.bclamp = &bclamp; + +	memset(&bclamp, 0, sizeof bclamp); +	bclamp.dcsubval = value; + +	ret = ioctl(isp->ccdc->fd, VIDIOC_OMAP3ISP_CCDC_CFG, &config); +	if (ret < 0) +		return -errno; + +	return ret; +} + +/* -----------------------------------------------------------------------------   * Preview engine parameters configuration   */ diff --git a/isp/omap3isp.h b/isp/omap3isp.h index 368fd72..6635437 100644 --- a/isp/omap3isp.h +++ b/isp/omap3isp.h @@ -74,6 +74,8 @@ int omap3_isp_snapshot_capture(struct omap3_isp_device *isp);  int omap3_isp_snapshot_put_buffer(struct omap3_isp_device *isp,  				  struct v4l2_video_buffer *buffer); +int omap3_isp_ccdc_set_black_level(struct omap3_isp_device *isp, unsigned int value); +  int omap3_isp_preview_set_contrast(struct omap3_isp_device *isp, unsigned int value);  int omap3_isp_preview_set_saturation(struct omap3_isp_device *isp, float value); | 
