Share via


CBasePin::SetMediaType

Sets the m_mt data member to the established media type.

virtual HRESULT SetMediaType(
  const CMediaType* pmt
);

Parameters

  • pmt
    Pointer to a media type object that was previously agreed on.

Return Values

Returns NOERROR by default implementation. The overriding member functions return an HRESULT value.

Remarks

This member function is called to establish the format for a pin connection. The CBasePin::CheckMediaType member function will have been called to check the connection format and, if it did not return an error value, this virtual member function will be called. The default implementation sets the m_mt protected data member to the value passed to this member function. Override to inform the derived class when the media type is set.

Requirements

DirectShow applications and DirectShow filters have different include file and link library requirements. See Setting Up the Build Environment for more information.

OS Versions: Windows CE 2.12 and later. Version 2.12 requires DXPAK 1.0 or later.
Header:

Last updated on Wednesday, April 13, 2005

© 2005 Microsoft Corporation. All rights reserved.