Important: |
---|
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist. |
Retrieves the media type of the CMediaSampleobject.
HRESULT GetMediaType( AM_MEDIA_TYPE** ppMediaType );
Parameters
Return Values
Returns an HRESULTvalue. When a sample is received and there is no format change, this method returns S_FALSE.
Remarks
This member function implements the IMediaSample::GetMediaTypemethod. The member function makes a copy of the AM_MEDIA_TYPEstructure and creates a task memory block to maintain the reference. When you are done with the media type, free the memory block with the FreeMediaTypeutility function, and then free the entire media type with the Microsoft Win32 CoTaskMemFreefunction.