Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Problem when automatically calculating the intrinsic camera values for reduced camera resolutions

I have a problem automatically calculating the intrinsic camera values from the size of the frame and the fovY values the camera hardware tells me. It works fine for frames with full resolution and is nearly as good as a manually calibrated camera but if I set the resolution to 640x480 I get the following problem:

If I tell the OpenCV cam preview to use resolution 640x480 it provides frames in that resolution, the problem here is that the Android Camera class still tells me the same values for getHorizontalViewAngle() and getVerticalViewAngle() even if now the frames have a different aspect ratio and show not the same region as in the full resolution. So my problem is that instead of using the full frame from the sensor just in a smaller resolution the camera now gives me a cropped image but still the same values for fovY. is it possible to calculate the correct fovY based on the new resolution?