ISpatialAudioMetadataClient::GetSpatialAudioMetadataItemsBufferLength method

Gets the length of the buffer required to store the specified number of spatial audio metadata items. Use this method to determine the correct buffer size to use when attaching caller-provided memory through the ISpatialAudioMetadataItemsBuffer interface.

Syntax


HRESULT GetSpatialAudioMetadataItemsBufferLength(
  [in]  UINT16 maxItemCount,
  [out] UINT32 *bufferLength
);

Parameters

maxItemCount [in]

The maximum number of metadata items to be stored in an ISpatialAudioMetadataItems object.

bufferLength [out]

The length of the buffer required to store the number of spatial audio metadata items specified in the maxItemCount parameter.

Return value

If the method succeeds, it returns S_OK. If it fails, possible return codes include, but are not limited to, the values shown in the following table.

Return codeDescription
E_INVALIDARG

The provided pointer is not valid.

The value of maxItemCount or frameCount is 0.

 

See also

ISpatialAudioMetadataClient

 

 

Show: