Camera exposure returning -6.0 regardless of actual exposure

asked 2016-08-07 22:27:33 -0600

cvi gravatar image

updated 2016-08-07 22:44:50 -0600

The following code always prints -6.0 regardless of if the camera is pointing at something bright or something dark. Any ideas why it's doing this and how to fix it?

I tried the laptop-integrated Dell webcam and it always outputs 71761848.0

However, when I tried a Logitech camera the number did change (ranged from -10.0 to -3.0) depending how bright / dark the scene was.

cap = cv2.VideoCapture(0)
while(1):
    ret, image = cap.read()
    print(str(cap.get(cv2.CAP_PROP_EXPOSURE)))

This is on Windows 10 running OpenCV 3.1.

edit retag flag offensive close merge delete

Comments

3

This might be a stupid answer but... maybe your laptop camera doesn't adjust exposure based on the scene but your external camera does?

Mark Coker gravatar imageMark Coker ( 2016-08-07 23:53:14 -0600 )edit

I have got logitech webcam C130 and C230 range is -1 to -12.

see this post too

LBerger gravatar imageLBerger ( 2016-08-08 02:41:15 -0600 )edit

Also, be perfectly sure that your camera is supporting to set this value from software AND that the interface used to access your camera through OpenCV is supporting the getter. They are not implemented for every possible backend.

StevenPuttemans gravatar imageStevenPuttemans ( 2016-08-08 06:13:26 -0600 )edit