Share via


MFGetAttributeRatio Function

Retrieves an attribute whose value is a ratio.

Syntax

HRESULT MFGetAttributeRatio(
  __in   IMFAttributes *pAttributes,
  __in   REFGUID guidKey,
  __out  UINT32 *pnNumerator,
  __out  UINT32 *punDenominator
);

Parameter

  • pAttributes [in]
    Pointer to the IMFAttributes interface of the attribute store.

  • guidKey [in]
    GUID that identifies which value to retrieve. The attribute type must be MF_ATTRIBUTE_UINT64.

  • pnNumerator [out]
    Receives the numerator of the ratio.

  • punDenominator [out]
    Receives the denominator of the ratio.

Rückgabewert

Ist Funktion erfolgreich, wird "S_OK" zurückgegeben. Andernfalls wird ein HRESULT-Fehlercode zurückgegeben.

Hinweise

Some attributes specify a ratio as a packed UINT64 value. Use this function to get the numerator and denominator as separate 32-bit values.

Anforderungen

Mindestens unterstützter Client

Windows Vista

Mindestens unterstützter Server

Windows Server 2008

Header

Mfapi.h

Siehe auch

Media Foundation Functions

MFSetAttributeRatio