Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

In case anybody ever finds this useful, I found a (partial) solution: If your VideoCapture variable is called vc, this should work:

    vc.set(Highgui.CV_CAP_PROP_FRAME_WIDTH, desiredFrameWidth);
    vc.set(Highgui.CV_CAP_PROP_FRAME_HEIGHT, desiredFrameHeight);

Mind that the combination of width and height must be one of the supported picture formats for your camera, otherwise it will just get a black image. You can get those through Camera.Parameters.getSupportedPictureSizes().

However, setting a high resolution appears to exceed the YUV conversion buffer's capacity, so I'm still struggling with that.