IGraphConfig::PushThroughData method (strmif.h)
[The feature associated with this page, DirectShow, is a legacy feature. It has been superseded by MediaPlayer, IMFMediaEngine, and Audio/Video Capture in Media Foundation. Those features have been optimized for Windows 10 and Windows 11. Microsoft strongly recommends that new code use MediaPlayer, IMFMediaEngine and Audio/Video Capture in Media Foundation instead of DirectShow, when possible. Microsoft suggests that existing code that uses the legacy APIs be rewritten to use the new APIs if possible.]
The PushThroughData
method pushes data through the filter graph to the specified pin.
Syntax
HRESULT PushThroughData(
[in] IPin *pOutputPin,
[in] IPinConnection *pConnection,
[in] HANDLE hEventAbort
);
Parameters
[in] pOutputPin
Pointer to the IPin interface of an output pin in the filter graph.
[in] pConnection
Pointer to the IPinConnection interface of an input pin in the filter graph. This parameter can be NULL.
[in] hEventAbort
Handle to an event. If the caller is a filter calling on one of its data processing threads, this parameter should be a handle to an event that will be signaled when the filter is put into a stopped state. Otherwise, this parameter can be NULL. For more information, see Remarks.
Return value
Returns S_OK if successful. Otherwise, returns an error code that may be one of the following values, or others not listed.
Return code | Description |
---|---|
|
Failed to allocate necessary memory. |
|
Could not find a candidate input pin. |
|
Filter state changed during the operation. |
Remarks
This method pushes through any pending data, from a specified output pin down to a specified input pin. Optionally, you can leave the input pin unspecified and let the method search the filter graph for the best candidate. Do not call this method from the thread that is pushing data.
If a filter calls this method on one of its own data processing threads, it creates the potential for a deadlock. The method obtains a lock on the filter graph, which can block the filter from stopping on receiving a call to IMediaFilter::Stop. To prevent this situation, the method takes a handle to an event object provided by the filter. The filter should signal the event if it receives a call to its Stop method.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP [desktop apps only] |
Minimum supported server | Windows Server 2003 [desktop apps only] |
Target Platform | Windows |
Header | strmif.h (include Dshow.h) |
Library | Strmiids.lib |