Ask Your Question
1

Change focus of a V4l2 Cam

asked Dec 13 '12

Geppertm gravatar image

Hi there, i´m using Ubuntu 12.10 with all dependencies and libv4l2.I want to change the focus of a V4l2 Cam. I´m trieing it with the following code:

.
.
VideoCapture cam;
.
.
cam.set(CV_CAP_PROP_FOCUS ,d);

Capture frames works.

If I use Windows 7 the code works fine.

Preview: (hide)

2 answers

Sort by » oldest newest most voted
2

answered Nov 6 '13

Geppertm gravatar image

I´ve found out that this feature isn´t implemented for Linux. I´ve implemented the features. I´m going to commit this features as soon as possible.

Preview: (hide)

Comments

I am working on the ubuntu 12.04lts and need the focus control I was about to start this but if you have the change please post the difference here.

mpatalberta gravatar imagempatalberta (Dec 13 '13)edit

Hi, I´ve made a 7z File with the changes, you can find it here: http://www.altdorfer-jungs.de/2014/opencv.7z

the main changes are in cap_libv4l.cpp.

Geppertm gravatar imageGeppertm (Dec 13 '13)edit

I recommend you to contribute your improvements to OpenCV. See instruction here: http://code.opencv.org/projects/opencv/wiki/How_to_contribute

Is anyone still on this? Seems like there are more missing capabilties for v4l2. Also the link of Geppertm doesn't work anymore.

vliedel gravatar imagevliedel (Mar 6 '14)edit
0

answered Dec 13 '13

mpatalberta gravatar image

Thanks I will try them out.

Preview: (hide)

Question Tools

Stats

Asked: Dec 13 '12

Seen: 2,414 times

Last updated: Dec 13 '13