Ask Your Question

Camera distorted on android 4.4.2

asked 2014-02-02 09:21:38 -0500

thaffe gravatar image

The Camera on my galaxy s2(Android 4.4.2) looks like this when i run the color blob sample code. The same code works on my galaxy tab 2.

Tried with writing the code from scratch and other sample codes. There are no errors on both devices, but the image looks like this on the S2

Does anybody know how to fix this?

image description

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted

answered 2014-04-25 15:43:58 -0500

ekings419 gravatar image

I recently had the same problem. I am using a Galaxy S2 as well, running Android 4.2.2 (from CyanogenMod). I had OpenCV 2.4.5 running okay. This problem showed up when I upgraded to OpenCV 2.4.7. After looking at the source code diff, I found the problem.

In (line 149),

    params.setRecordingHint(true); //This line is breaking the preview


If you change this to params.setRecordingHint(false), or remove it altogether, the preview works again.

edit flag offensive delete link more


Awesome! I had the exact same problem and this solved it for me, thank you!

eskil gravatar imageeskil ( 2014-05-20 07:17:10 -0500 )edit

Question Tools


Asked: 2014-02-02 09:21:38 -0500

Seen: 1,084 times

Last updated: Apr 25 '14