IMDSPStorage2::SetAttributes2 method (mswmdm.h)

The SetAttributes2 method extends IMDSPStorage::SetAttributes by enabling you to set audio and video formats and extended attributes of a storage object.

Syntax

HRESULT SetAttributes2(
  [in] DWORD            dwAttributes,
  [in] DWORD            dwAttributesEx,
  [in] _WAVEFORMATEX    *pAudioFormat,
  [in] _VIDEOINFOHEADER *pVideoFormat
);

Parameters

[in] dwAttributes

DWORD containing the attributes to be set as defined in the IWMDMStorage::SetAttributes method

[in] dwAttributesEx

DWORD containing the extended attributes. No extended attributes are currently defined.

[in] pAudioFormat

Pointer to a _WAVEFORMATEX structure that contains audio format information about the object. This parameter is optional and is ignored if the file is not audio.

[in] pVideoFormat

Pointer to a _VIDEOINFOHEADER structure that contains video format information about the object. This parameter is optional and is ignored if the file is not video.

Return value

The method returns an HRESULT. All the interface methods in Windows Media Device Manager can return any of the following classes of error codes:

  • Standard COM error codes
  • Windows error codes converted to HRESULT values
  • Windows Media Device Manager error codes
For an extensive list of possible error codes, see Error Codes.

Remarks

See Remarks for IWMDMStorage::SetAttributes.

This method is optional. For more information, see Mandatory and Optional Interfaces.

Requirements

Requirement Value
Target Platform Windows
Header mswmdm.h
Library Mssachlp.lib

See also

IMDSPStorage2 Interface

IMDSPStorage2::GetAttributes2

IMDSPStorage::SetAttributes

IWMDMStorage::SetAttributes