Reputation: 21152
I need to use DirectShow (C++) for recording a webcam and saving the data to a file.
I really don't know how DirectShow works, this is a "stage" (working experience), but at school we didn't study it.
I think the best way to implement this could be:
Now there are two problems:
I won't use OpenCV because sometime it doesn't work properly (It doesn't find the camera). Are there any high level wrapper that could help?
EDIT: the program won't have a window, it will run in background called by a dll.
Upvotes: 1
Views: 1924
Reputation: 69724
Where can I find a good reference book or how do I start?
DirectShow introduction material
The saved video shouldn't be too big, does DirectShow provide a way to compress it?
Yes it provides capabilities to attach codecs, that needs to be installed in the system. These are typically third party codecs (for reasons beyond the scope of brief answer). You might want to record into Windows Media files to not depend on third party codecs. SWee more on MSDN: Choosing a Compression Filter.
Upvotes: 2