IWMEncAudienceObj.VideoFPS

Windows Media Encoder SDK banner art

The VideoFPS property specifies and retrieves the video frame rate.

Syntax

IWMEncAudienceObj.VideoFPS(iRenderSiteIndex) = Long
Long = IWMEncAudienceObj.VideoFPS(iRenderSiteIndex)

Parameters

iRenderSiteIndex

[in]  Integer containing the audience stream index. Because an audience can only contain one stream of each type, iRenderSiteIndex must be zero.

Property Value

A Long indicating the frame rate. When retrieving this value, divide by 1000 to get frames per second, and multiply by 1000 when setting this value.

Remarks

High-motion video generally looks smoother if you use a higher frame rate, however it requires more computer performance. The setting you specify represents the maximum frame rate. Depending on factors such as the video size and codec quality setting, the actual frame rate could be lower.

Example Code

' Create a WMEncProfile2 object.
  Dim Pro As WMEncProfile2
  Set Pro = New WMEncProfile2

' Load a custom profile. REPLACE THE FILE NAME.
  Pro.LoadFromFile "C:\Profiles\CustomProfile.prx"

' Create an IWMEncAudienceObj object, selecting the first audience (0)
' in the profile.
  Dim Audnc As IWMEncAudienceObj
  Set Audnc = Pro.Audience(0)

' Retrieve a value indicating the frame rate.
' Divide by 1000 to retrieve the rate in seconds.
  Dim lVidFrameRate As Long As Long
  lVidFrameRate = Audnc.VideoFPS(0) / 1000

Requirements

Reference: Windows Media Encoder

Library: wmenc.exe

See Also