CMediaSample::SetMediaType

Sets the media type for the CMediaSample object.

HRESULT SetMediaType(
AM_MEDIA_TYPE * pMediaType );

Parameters

  • pMediaType
    Pointer to a pointer to a media type structure to be set.

Return Values

Returns an HRESULT value.

Remarks

This member function implements the IMediaSample::SetMediaType method. It deletes the previous media type if one exists, makes a copy of the media type passed in, sets m_pMediaType to the copy of the media type, and sets the value of the m_dwFlags Sample_TypeChanged flag to TRUE.

 Last updated on Tuesday, July 13, 2004

© 1992-2000 Microsoft Corporation. All rights reserved.