From c5ea5f7a2c5ab4b84f6690b7dd183de3c84f88bb Mon Sep 17 00:00:00 2001 From: Mizux Date: Mon, 21 Jul 2014 09:50:39 +0200 Subject: [PATCH] Fix some getter --- v4l2capture.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/v4l2capture.c b/v4l2capture.c index ce522dc..0b266aa 100644 --- a/v4l2capture.c +++ b/v4l2capture.c @@ -483,7 +483,7 @@ static PyObject *Video_device_get_exposure_auto(Video_device *self) struct v4l2_control ctrl; CLEAR(ctrl); ctrl.id = V4L2_CID_EXPOSURE_AUTO; - if(my_ioctl(self->fd, VIDIOC_S_CTRL, &ctrl)){ + if(my_ioctl(self->fd, VIDIOC_G_CTRL, &ctrl)){ return NULL; } return Py_BuildValue("i",ctrl.value); @@ -520,7 +520,7 @@ static PyObject *Video_device_get_focus_auto(Video_device *self) struct v4l2_control ctrl; CLEAR(ctrl); ctrl.id = V4L2_CID_FOCUS_AUTO; - if(my_ioctl(self->fd, VIDIOC_S_CTRL, &ctrl)){ + if(my_ioctl(self->fd, VIDIOC_G_CTRL, &ctrl)){ return NULL; } return Py_BuildValue("i",ctrl.value);