IAMVideoControl::GetMaxAvailableFrameRate method (strmif.h)

[The feature associated with this page, DirectShow, is a legacy feature. It has been superseded by MediaPlayer, IMFMediaEngine, and Audio/Video Capture in Media Foundation. Those features have been optimized for Windows 10 and Windows 11. Microsoft strongly recommends that new code use MediaPlayer, IMFMediaEngine and Audio/Video Capture in Media Foundation instead of DirectShow, when possible. Microsoft suggests that existing code that uses the legacy APIs be rewritten to use the new APIs if possible.]

The GetMaxAvailableFrameRate method retrieves the maximum frame rate currently available, based on bus bandwidth usage for connections, such as USB and IEEE 1394, where the maximum frame rate may be limited by bandwidth availability.

Syntax

HRESULT GetMaxAvailableFrameRate(
  [in]  IPin     *pPin,
  [in]  long     iIndex,
  [in]  SIZE     Dimensions,
  [out] LONGLONG *MaxAvailableFrameRate
);

Parameters

[in] pPin

Pointer to the pin to retrieve the maximum frame rate from.

[in] iIndex

Index of the format to query for maximum frame rate. This index corresponds to the order in which formats are enumerated by IAMStreamConfig::GetStreamCaps. The value must range between zero and the number of supported VIDEO_STREAM_CONFIG_CAPS structures returned by IAMStreamConfig::GetNumberOfCapabilities) minus one.

[in] Dimensions

Frame image size (width and height) in pixels.

[out] MaxAvailableFrameRate

Pointer to the maximum available frame rate. The frame rate is expressed as frame duration in 100-nanosecond units.

Return value

Returns an HRESULT value that depends on the implementation of the interface.

Requirements

Requirement Value
Minimum supported client Windows 2000 Professional [desktop apps only]
Minimum supported server Windows 2000 Server [desktop apps only]
Target Platform Windows
Header strmif.h (include Dshow.h)
Library Strmiids.lib

See also

Error and Success Codes

IAMVideoControl Interface

VIDEO_STREAM_CONFIG_CAPS Structure