I have been developing some video apps using USB webCam and the v4l2 API. The API gives lots of ioctl() calls to enumerate general capabilities, video standard, pixel color formats, etc. But there is not an ioctl() to enumerate all of the possible image sizes the USB webCam supports.
What is the preferred way to do this?
The API documentation says you can set a particular image size and the ioctl() will return its closest match. So I guess I could try every possible image size and see if the USB webCam rejects it. But that seems like a rather inefficient way to enumerate all possible supported image sizes when there are so many standard size formats (QCIF, CIF, 4CIF, 16CIF,VGA, DV, SVGA, XGA, UVGA, SXGA, UXGA, etc).
Thanks,
-Andres