提交 cbcef291 编写于 作者: D David Plowman 提交者: Zheng Zengkai

media: ov5647: change defaults to better match raw camera applications.

raspberrypi inclusion
category: feature
bugzilla: 50432

--------------------------------

Specifically:

* AWB is now off by default.

* AEC/AGC is also off by default.

* The default mode is changed to the 10-bit 2x2 binned mode.

AWB and AEC/AGC can be re-enabled using the usual V4L2 controls. The
original 8-bit mode will be respected if an application requests the
8-bit format.
Signed-off-by: NDavid Plowman <david.plowman@raspberrypi.com>
Signed-off-by: NNaushir Patuck <naush@raspberrypi.com>
Signed-off-by: NFang Yafen <yafen@iscas.ac.cn>
Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
上级 3a195858
...@@ -669,8 +669,8 @@ static struct ov5647_mode supported_modes_10bit[] = { ...@@ -669,8 +669,8 @@ static struct ov5647_mode supported_modes_10bit[] = {
}, },
}; };
/* Use original 8-bit VGA mode as default. */ /* Use 2x2 binned 10-bit mode as default. */
#define OV5647_DEFAULT_MODE (&supported_modes_8bit[0]) #define OV5647_DEFAULT_MODE (&supported_modes_10bit[2])
static int ov5647_write(struct v4l2_subdev *sd, u16 reg, u8 val) static int ov5647_write(struct v4l2_subdev *sd, u16 reg, u8 val)
{ {
...@@ -1367,18 +1367,18 @@ static int ov5647_probe(struct i2c_client *client) ...@@ -1367,18 +1367,18 @@ static int ov5647_probe(struct i2c_client *client)
0, /* min */ 0, /* min */
1, /* max */ 1, /* max */
1, /* step */ 1, /* step */
1); /* default */ 0); /* default */
v4l2_ctrl_new_std(&sensor->ctrls, &ov5647_ctrl_ops, v4l2_ctrl_new_std(&sensor->ctrls, &ov5647_ctrl_ops,
V4L2_CID_AUTO_WHITE_BALANCE, V4L2_CID_AUTO_WHITE_BALANCE,
0, /* min */ 0, /* min */
1, /* max */ 1, /* max */
1, /* step */ 1, /* step */
1); /* default */ 0); /* default */
v4l2_ctrl_new_std_menu(&sensor->ctrls, &ov5647_ctrl_ops, v4l2_ctrl_new_std_menu(&sensor->ctrls, &ov5647_ctrl_ops,
V4L2_CID_EXPOSURE_AUTO, V4L2_CID_EXPOSURE_AUTO,
V4L2_EXPOSURE_MANUAL, /* max */ V4L2_EXPOSURE_MANUAL, /* max */
0, /* skip_mask */ 0, /* skip_mask */
V4L2_EXPOSURE_AUTO); /* default */ V4L2_EXPOSURE_MANUAL); /* default */
ctrl = v4l2_ctrl_new_std(&sensor->ctrls, &ov5647_ctrl_ops, ctrl = v4l2_ctrl_new_std(&sensor->ctrls, &ov5647_ctrl_ops,
V4L2_CID_EXPOSURE, V4L2_CID_EXPOSURE,
4, /* min lines */ 4, /* min lines */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册