Lines Matching defs:ctrls

23 #include <media/v4l2-ctrls.h>
461 struct ov5640_ctrls ctrls;
478 ctrls.handler)->sd;
2326 bool auto_gain = sensor->ctrls.auto_gain->val == 1;
2327 bool auto_exp = sensor->ctrls.auto_exp->val == V4L2_EXPOSURE_AUTO;
2857 __v4l2_ctrl_modify_range(sensor->ctrls.vblank, OV5640_MIN_VBLANK,
2860 __v4l2_ctrl_s_ctrl(sensor->ctrls.vblank, vblank);
2884 __v4l2_ctrl_s_ctrl_int64(sensor->ctrls.pixel_rate,
2928 __v4l2_ctrl_s_ctrl_int64(sensor->ctrls.pixel_rate, pixel_rate);
2929 __v4l2_ctrl_s_ctrl(sensor->ctrls.link_freq, i);
2932 __v4l2_ctrl_modify_range(sensor->ctrls.hblank,
2939 exposure_val = clamp_t(s32, sensor->ctrls.exposure->val,
2940 sensor->ctrls.exposure->minimum,
2943 __v4l2_ctrl_modify_range(sensor->ctrls.exposure,
2944 sensor->ctrls.exposure->minimum,
3158 u16 red = (u16)sensor->ctrls.red_balance->val;
3159 u16 blue = (u16)sensor->ctrls.blue_balance->val;
3173 struct ov5640_ctrls *ctrls = &sensor->ctrls;
3177 if (ctrls->auto_exp->is_new) {
3183 if (!auto_exp && ctrls->exposure->is_new) {
3196 if (ctrls->exposure->val < max_exp)
3197 ret = ov5640_set_exposure(sensor, ctrls->exposure->val);
3205 struct ov5640_ctrls *ctrls = &sensor->ctrls;
3208 if (ctrls->auto_gain->is_new) {
3214 if (!auto_gain && ctrls->gain->is_new)
3215 ret = ov5640_set_gain(sensor, ctrls->gain->val);
3334 sensor->ctrls.gain->val = val;
3340 sensor->ctrls.exposure->val = val;
3366 __v4l2_ctrl_modify_range(sensor->ctrls.exposure,
3367 sensor->ctrls.exposure->minimum,
3368 exp_max, sensor->ctrls.exposure->step,
3435 struct ov5640_ctrls *ctrls = &sensor->ctrls;
3436 struct v4l2_ctrl_handler *hdl = &ctrls->handler;
3449 ctrls->pixel_rate = v4l2_ctrl_new_std(hdl, ops, V4L2_CID_PIXEL_RATE,
3454 ctrls->link_freq = v4l2_ctrl_new_int_menu(hdl, ops,
3462 ctrls->hblank = v4l2_ctrl_new_std(hdl, ops, V4L2_CID_HBLANK, hblank,
3466 ctrls->vblank = v4l2_ctrl_new_std(hdl, ops, V4L2_CID_VBLANK,
3471 ctrls->auto_wb = v4l2_ctrl_new_std(hdl, ops,
3474 ctrls->blue_balance = v4l2_ctrl_new_std(hdl, ops, V4L2_CID_BLUE_BALANCE,
3476 ctrls->red_balance = v4l2_ctrl_new_std(hdl, ops, V4L2_CID_RED_BALANCE,
3479 ctrls->auto_exp = v4l2_ctrl_new_std_menu(hdl, ops,
3483 ctrls->exposure = v4l2_ctrl_new_std(hdl, ops, V4L2_CID_EXPOSURE,
3486 ctrls->auto_gain = v4l2_ctrl_new_std(hdl, ops, V4L2_CID_AUTOGAIN,
3488 ctrls->gain = v4l2_ctrl_new_std(hdl, ops, V4L2_CID_ANALOGUE_GAIN,
3491 ctrls->saturation = v4l2_ctrl_new_std(hdl, ops, V4L2_CID_SATURATION,
3493 ctrls->hue = v4l2_ctrl_new_std(hdl, ops, V4L2_CID_HUE,
3495 ctrls->contrast = v4l2_ctrl_new_std(hdl, ops, V4L2_CID_CONTRAST,
3497 ctrls->test_pattern =
3501 ctrls->hflip = v4l2_ctrl_new_std(hdl, ops, V4L2_CID_HFLIP,
3503 ctrls->vflip = v4l2_ctrl_new_std(hdl, ops, V4L2_CID_VFLIP,
3506 ctrls->light_freq =
3528 ctrls->pixel_rate->flags |= V4L2_CTRL_FLAG_READ_ONLY;
3529 ctrls->link_freq->flags |= V4L2_CTRL_FLAG_READ_ONLY;
3530 ctrls->hblank->flags |= V4L2_CTRL_FLAG_READ_ONLY;
3531 ctrls->gain->flags |= V4L2_CTRL_FLAG_VOLATILE;
3532 ctrls->exposure->flags |= V4L2_CTRL_FLAG_VOLATILE;
3534 v4l2_ctrl_auto_cluster(3, &ctrls->auto_wb, 0, false);
3535 v4l2_ctrl_auto_cluster(2, &ctrls->auto_gain, 0, true);
3536 v4l2_ctrl_auto_cluster(2, &ctrls->auto_exp, 1, true);
3705 ret = v4l2_ctrl_handler_setup(&sensor->ctrls.handler);
3958 v4l2_ctrl_handler_free(&sensor->ctrls.handler);
3978 v4l2_ctrl_handler_free(&sensor->ctrls.handler);