Cameras and TWAIN
Q. Does Dosadi have any products or software for controlling cameras?
A. Not really. TWAIN has some ability to pull images from cameras, but offers minimal control.
Q. Can TWAIN be used to download photographs from cameras, capture video frames, or whole movie clips?
A. Movies and video streams: No. TWAIN deals only with still images, TWAIN doesn't do movies.
Photos and frame grabs: Yes, sort of. Any camera or webcam that appears in the WIA device list (the 'Scanners and Cameras' folder) will also appear as a TWAIN device. Some cameras even have native TWAIN drivers. These drivers are designed for user interaction, the application has minimal control over the process.
Q. Rats! I need broader compatibility or more control over the camera - if I can't use TWAIN, what should I use?
A. For still-image/stored image cameras, we recommend WIA - it is the only widely supported vendor-independent API for talking to digital cameras. For maximum control you need to use a proprietary API - Canon, Olympus and Nikon all offer SDKs.
For capturing frames from a video stream, you may also be able to use WIA. Lots of articles on the web, for example on Code Project: WIA Scripting and .NET, WebCam Fast Image Capture Service using WIA.
For more control over a video source, the primary API is DirectShow. It's COM. It's complicated. And it's badly documented even by Microsoft standards. (But hey, it's way powerful.) You don't have to use it directly: There are free wrappers such as DirectX.Capture and VidCapture and commercial video capture controls such as CapturePRO, IC Imaging Control and LEADTOOLS Multimedia.
Compared to DirectShow, Video for Windows (VfW) is about as complicated as a chocolate chip. This API dates from Win 3.1 but remains well-supported and provides simple video frame and stream capture. Google is your friend.
Q. We want to plug in a USB video camera, have a real-time preview window, and capture frames under program control.
A. TWAIN is not the best choice for this. Bite the bullet and try WIA or DirectShow.