IMFSampleGrabberSinkCallback interface
Callback interface to get media data from the sample-grabber sink.
Members
The IMFSampleGrabberSinkCallback interface inherits from IMFClockStateSink. IMFSampleGrabberSinkCallback also has these types of members:
Methods
The IMFSampleGrabberSinkCallback interface has these methods.
| Method | Description |
|---|---|
| OnProcessSample |
Called when the sample-grabber sink receives a new media sample. |
| OnSetPresentationClock |
Called when the presentation clock is set on the sample-grabber sink. |
| OnShutdown |
Called when the sample-grabber sink is shut down. |
Remarks
The sample-grabber sink enables an application to get data from the Media Foundation pipeline without implementing a custom media sink. To use the sample-grabber sink, the application must perform the following steps:
-
Implement the IMFSampleGrabberSinkCallback interface.
-
Call MFCreateSampleGrabberSinkActivate, passing in the IMFSampleGrabberSinkCallback interface pointer. This function returns an IMFActivate object.
-
Create a topology that includes an output node with the sink's IMFActivate object.
-
Pass this topology to the Media Session.
During playback, the sample-grabber sink calls methods on the application's callback.
You cannot use the sample-grabber sink to get protected content.
Requirements
|
Minimum supported client |
Windows Vista [desktop apps only] |
|---|---|
|
Minimum supported server |
Windows Server 2008 [desktop apps only] |
|
Header |
|
|
Library |
|
See also