问题
How to grab frame from .mov file in c#.net by using DirectShow.net
回答1:
DirectShow and DirectShow.NET don't make it any special with .MOV
files. You typically create a filter graph with a Sample Grabber filter that you manage, and its callback gives you frames of video stream that passes through.
You might want to look at DxScan sample in DirectShow.NET, \Samples\Editing\DxScan. It grabs frames from a given movie file.
A sample application scanning a media file looking for black frames
Most of the work is done in ISampleGrabberCB.BufferCB. See the comments there. Also, the algorithm used to scan for black frames isn't as efficient as it could be. However, the samples gives you an idea of how this could be done.
来源:https://stackoverflow.com/questions/11102241/grab-frame-from-mov-file-using-directshow-net