I’m writing an AVStream MInidriver
I need to expose the FPS I support.
currently I support 30 and 60 FPS.
in graph studio all range between 30 and 60 is exposed.
how can I enable only 30 and 60 and not the full range between them?
my KS_DATARANGE_VIDEO is defined as
const KS_DATARANGE_VIDEO
FormatRGB_480 =
{
// KSDATARANGE
{
sizeof(KS_DATARANGE_VIDEO), // FormatSize
0, // Flags
X_640 * Y_480 * 2, // SampleSize
0, // Reserved
STATICGUIDOF(KSDATAFORMAT_TYPE_VIDEO), // aka. MEDIATYPE_Video
SUBTYPE_RGB,
STATICGUIDOF(KSDATAFORMAT_SPECIFIER_VIDEOINFO) // aka. FORMAT_VideoInfo
},
TRUE, // BOOL, bFixedSizeSamples (all samples same size?)
TRUE, // BOOL, bTemporalCompression (all I frames?)
0, // Reserved (was StreamDescriptionFlags)
0, // Reserved (was MemoryAllocationFlags
// (KS_VIDEO_ALLOC_*))
// KS_VIDEO_STREAM_CONFIG_CAPS
{
STATICGUIDOF(KSDATAFORMAT_SPECIFIER_VIDEOINFO), // GUID
0, // AnalogVideoStandard
X_640, Y_480, // InputSize, (the inherent size of the incoming signal
// with every digitized pixel unique)
X_640, Y_480, // MinCroppingSize, smallest rcSrc cropping rect
allowed
X_640, Y_480, // MaxCroppingSize, largest rcSrc cropping rect allowed
8, // CropGranularityX, granularity of cropping size
1, // CropGranularityY
8, // CropAlignX, alignment of cropping rect
1, // CropAlignY;
X_640, Y_480, // MinOutputSize, smallest bitmap stream can produce
X_640, Y_480, // MaxOutputSize, largest bitmap stream can produce
8, // OutputGranularityX, granularity of output
bitmap size
1, // OutputGranularityY;
0, // StretchTapsX (0 no stretch, 1 pix dup, 2
interp…)
0, // StretchTapsY
0, // ShrinkTapsX
0, // ShrinkTapsY
MIN_FRAME_INTERVAL_FOR_30FPS, // MinFrameInterval, 100 nS
units
MAX_FRAME_INTERVAL_FOR_FPS, // MaxFrameInterval, 100 nS units
16 * FRAME_RATE_30FPS * X_640 * Y_480, // MinBitsPerSecond;
16 * FRAME_RATE_30FPS * X_640 * Y_480, // MaxBitsPerSecond;
},