以前贴子里的东西,就是关于没有Preffered Media Type的办法,请看一下,我真的没办法了,我找了好多资料,但是我对COM不是很熟,谢谢了!
By default, the Sample Grabber has no preferred media types. Before you insert it into a filter graph, set the media type for the input pin by calling the ISampleGrabber::SetMediaType method. Setting a media type ensures that the filter graph manager inserts the Sample Grabber at the correct point in the graph.
The SetMediaType method takes a pointer to an AM_MEDIA_TYPE structure that describes the media type. Depending on the situation, you can set the subtype or format type to GUID_NULL, which indicates "unspecified."