IMFCaptureSource::AddEffect method (mfcaptureengine.h)
Adds an effect to a capture stream.
Syntax
HRESULT AddEffect(
[in] DWORD dwSourceStreamIndex,
[in] IUnknown *pUnknown
);
Parameters
[in] dwSourceStreamIndex
The capture stream. The value can be any of the following.
Value | Meaning |
---|---|
|
The zero-based index of a stream. To get the number of streams, call IMFCaptureSource::GetDeviceStreamCount. |
|
The first image stream. |
|
The first video stream. |
|
The first audio stream. |
[in] pUnknown
A pointer to one of the following:
- A Media Foundation transform (MFT) that exposes the IMFTransform interface.
- An MFT activation object that exposes the IMFActivate interface.
Return value
This method can return one of these values.
Return code | Description |
---|---|
|
Success. |
|
No compatible media type could be found. |
|
The dwSourceStreamIndex parameter is invalid. |
Remarks
The effect must be implemented as a Media Foundation Transform (MFT). The pUnknown parameter can point to an instance of the MFT, or to an activation object for the MFT. For more information, see Activation Objects.
The effect is applied to the stream before the data reaches the capture sinks.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows 8 [desktop apps only] |
Minimum supported server | Windows Server 2012 [desktop apps only] |
Target Platform | Windows |
Header | mfcaptureengine.h |