Share via


Setting the Capture Frame Rate (Windows Embedded CE 6.0)

1/6/2010

Before you can set the frame rate for capturing video you must first determine the frame rates that a capture device supports. You can do this by first calling IAMStreamConfig::GetNumberOfCapabilities and then making successive calls to IAMStreamConfig::GetStreamCaps to enumerate the capabilities for a particular media type. Each set of capabilities is described in an AM_MEDIA_TYPE structure. For video data, the media format is FORMAT_VideoInfo2 so the AM_MEDIA_TYPE.pbFormat member points to a VIDEOINFOHEADER2 structure. The supported frame rate for the media type is contained in VIDEOINFOHEADER2.AvgTimePerFrame.

You can set one of the supported frame rates by preparing an AM_MEDIA_TYPE structure and then calling IAMStreamConfig::SetFormat.

See Also

Concepts

Video Capture Tasks