|Microsoft DirectX 9.0|
The SetOneShot method specifies whether the filter should stop the graph after receiving one sample.
HRESULT SetOneShot( BOOL OneShot );
Boolean value specifying whether the filter should stop the graph after receiving one sample. If TRUE, the filter graph stops when the Sample Grabber receives the first sample and signals EC_COMPLETE. If FALSE, the filter graph continues to run normally.
You can retrieve a sample at a particular time by calling this method with a value of TRUE, seeking to the desired time, and running the graph.
The Sample Grabber implements one-shot mode by calling IPin::EndOfStream on the downstream filter and returning S_FALSE from it's IMemInputPin::Receive method.