GetVideoCompressionSettings
function GetVideoCompressionSettings (out DataRate: LongInt; out KeyFrameRate: LongInt; out PFramesPerKeyFrame: LongInt; out WindowSize: LongInt; out Quality: Double; out CanQuality: Boolean; out CanCrunch: Boolean; out CanKeyFrame: Boolean; out CanBFrame: Boolean; out CanWindow: Boolean): Boolean;
bool __fastcall GetVideoCompressionSettings(/* out */ System::LongInt &DataRate, /* out */ System::LongInt &KeyFrameRate, /* out */ System::LongInt &PFramesPerKeyFrame, /* out */ System::LongInt &WindowSize, /* out */ double &Quality, /* out */ bool &CanQuality, /* out */ bool &CanCrunch, /* out */ bool &CanKeyFrame, /* out */ bool &CanBFrame, /* out */ bool &CanWindow);
public bool GetVideoCompressionSettings(out int DataRate, out int KeyFrameRate, out int PFramesPerKeyFrame, out int WindowSize, out double Quality, out bool CanQuality, out bool CanCrunch, out bool CanKeyFrame, out bool CanBFrame, out bool CanWindow);
Public Function GetVideoCompressionSettings(ByRef DataRate As Integer, ByRef KeyFrameRate As Integer, ByRef PFramesPerKeyFrame As Integer, ByRef WindowSize As Integer, ByRef Quality As Double, ByRef CanQuality As Boolean, ByRef CanCrunch As Boolean, ByRef CanKeyFrame As Boolean, ByRef CanBFrame As Boolean, ByRef CanWindow As Boolean) As Boolean
BOOL GetVideoCompressionSettings (int *DataRate, int *KeyFrameRate, int *PFramesPerKeyFrame, int *WindowSize, double *Quality, BOOL *CanQuality, BOOL *CanCrunch, BOOL *CanKeyFrame, BOOL *CanBFrame, BOOL *CanWindow);
Retrieves the video compression settings supported by some codecs. Returns true if the current video compressor supports this interface. See SetVideoCompressionSettings.
The values returned are those of the video compressor (its defaults, or the settings saved with ShowDialog (dlg_VideoCompressor)), not the VideoCompression_xxx properties, and can be passed to SetVideoCompressionSettings. For the Media Foundation encoder entries, DataRate 0, Quality -1 and KeyFrameRate 0 mean not set (automatic bit rate, rate control other than constant quality, key frame every 2 seconds).
Parameters:
-
DataRate: data rate in bits per second, 0 = default.
-
KeyFrameRate: number of frames per key frame. For example, if the rate is 15, a key frame occurs every 15 frames.
-
PFramesPerKeyFrame: P frames are used only in MPEG compression. E.g. if a key frame occurs once every 10 frames and there are three P frames per key frame, the P frames are spaced evenly between the key frames, and the remaining six frames are bi-directional (B) frames.
-
WindowSize: number of frames over which the compressor maintains the average data rate. E.g. with a data rate of 100K/sec and a frame rate of 10 frames per second, if the window size is 1, every frame is 10K or less; if the window size is 5, every five consecutive frames average 10K per frame, but individual frames may exceed this size.
-
Quality: value between 0.0 and 1.0, where 1.0 indicates the best quality and 0.0 the worst quality. If the value is negative, the filter uses the default quality.
-
CanQuality: the compressor supports the Quality parameter.
-
CanCrunch: the compressor can compress video to a specified data rate (see DataRate).
-
CanKeyFrame: the compressor supports the KeyFrameRate parameter.
-
CanBFrame: the compressor supports the PFramesPerKeyFrame parameter.
-
CanWindow: the compressor supports the WindowSize parameter.