Microsoft DirectX 9.0 |
The SetMediaType method sets the media type for the sample. This method implements the IMediaSample::SetMediaType method.
Syntax
HRESULT SetMediaType(
AM_MEDIA_TYPE *pMediaType
);
Parameters
pMediaType
Pointer to an AM_MEDIA_TYPE structure.
Return Value
Returns one of the HRESULT values shown in the following table.
Value | Description |
S_OK | Success |
E_OUTOFMEMORY | Insufficient memory |
Remarks
This method sets the CMediaSample::m_pMediaType member variable, which specifies the media type, and the CMediaSample::m_dwFlags member variable, which specifies whether the media type has changed.
This method makes a copy of the AM_MEDIA_TYPE structure.
See Also