IMpeg2Demultiplexer::CreateOutputPin
Microsoft DirectShow 9.0 |
IMpeg2Demultiplexer::CreateOutputPin
The CreateOutputPin method creates a new output pin on the Demux.
Syntax
HRESULT CreateOutputPin( AM_MEDIA_TYPE* pMediaType, LPWSTR pszPinName, IPin** ppIPin );
Parameters
pMediaType
[in] Pointer to an AM_MEDIA_TYPE structure that specifies the media type information for the new pin.
pszPinName
[in] Pointer to a wide character string that specifies a name for the new pin. The maximum length is 128 characters, including the NULL terminator.
ppIPin
[out] Address of a variable that receives a pointer to the pin's IPin interface.
Return Value
Returns an HRESULT value. Possible return values include the following.
Value | Description |
E_INVALIDARG | Invalid argument. |
S_OK | Success. |
VFW_E_DUPLICATE_NAME | Duplicate pin name. |
Remarks
Duplicate pin names are not allowed. To configure the pin, query the returned IPin interface for the IMPEG2StreamIdMap interface (for program streams) or for the IMPEG2PIDMap interface (for transport streams). Depending on which interface is queried for on the first output pin, the Demux configures itself for either transport or program stream mode. Once the Demux is configured, any calls to QueryInterface to retrieve the other interface will fail.
Requirements
Header: Declared in Strmif.h; include Dshow.h.
Library: Use Strmiids.lib.
See Also