wpfwpf-mediakit

Webcam capture with WPF MediaKit


I'm using the WPF MediaKit from codeplex to show a webcam in my application, so far so good. But I want to capture an image from the webcam as well. I'm using the EnableSampleGrabbing property and I've hooked into the NewVideoSample event.

But the event never fires! I've downloaded the sourcecode and debuged all the way down to the ISampleGrabberCB.SampleCB method and it is never triggered. I suspect that this method should be triggered by the DirectShowLib dll that the MediaKit uses. I've also downloaded the latest version of this DLL.

Has anyone done this with success ? Or any other toolkit I can use ?

I'm using VS2010, .net 4.0 on Windows7 64bit.


Solution

  • Ok, I'll have to answer this myself.

    The problem was that I was using Freetalk skype webcam that has HW encoding of the signal. when I tried with a normal webcam it worked.