Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Polling v. Event Driven Frame Grabbing From Video Camera

I working on an application in VS2010 c++ using MSFT LifeCam 3000HD.

Using OpenCV and the VideoInout library, I am able to grab frames from the camera by constantly polling the camera through the isFrameNew function.

All the examples I see use this polling method and the polling clearly uses a lot of CPU load.

Is there a way to add and event driven capability that will automatically call a function whenever a new frame is ready? I started looking into MSFT Media Foundation but that seems like a steep hill to climb when there might be something standard out there.

Could someone direct me to any code implementing an event driven approach as described above?

Thanks for any help.