MotionDetector_EnumGridDialogControls
TVideoGrabber.MotionDetector_EnumGridDialogControls |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Gives access to the controls of the grid dialog.
Declaration
function MotionDetector_EnumGridDialogControls(FirstControl: Boolean): TComponent;
Classes::TComponent *__fastcall MotionDetector_EnumGridDialogControls(bool FirstControl)
n/a
Description
This function enumerates the the controls of the grid dialog, including the dialog form.
This lets you e.g. customize the button names, the dialog size, etc...
- invoking MotionDetector_EnumGridDialogControls(True) returns the first control (in fact the dialog form), and resets the counter,
- invoking MotionDetector_EnumGridDialogControls(False) returns the next control, if any, or nil when the last control of the dialog has been reached.
E.g.:
procedure TForm1.Button1Click(Sender: TObject);
var
Control: TComponent;
begin
VideoGrabber1.MotionDetector_ShowGridDialog; // BEFORE...
Control := VideoGrabber1.MotionDetector_EnumGridDialogControls (True); // reset the counter and returns the first control (the dialog form)
while assigned (Control) do begin // for each control...
Memo1.Lines.Add (Control.Name + ': ' + Control.ClassName); // shows the control name and its type
if Control.Name = 'frmGridDialog' then begin
TForm(Control).Caption := 'this is my custom dialog title';
end
else if Control.Name = 'btnOK' then begin
TButton(Control).Caption := 'DONE';
end
else if Control.Name = 'btnCancel' then begin
TButton(Control).Caption := 'Discard';
end;
Control := VideoGrabber1.MotionDetector_EnumGridDialogControls (False); // returns the next control, or nil when the last control is reached
end;
VideoGrabber1.MotionDetector_ShowGridDialog; // AFTER.
end;
See Also
Color / Greyscale Grid structure / grid sensitivity Motion ratio Recording only when motion is detected Video noise TOnMotionDetected TOnMotionNotDetected MotionDetector_CellMotionRatio MotionDetector_CompareBlue MotionDetector_CompareGreen MotionDetector_CompareRed MotionDetector_Enabled MotionDetector_Get2DTextGrid MotionDetector_Get2DTextMotion MotionDetector_GetCellLocation MotionDetector_GetCellSensitivity MotionDetector_GetCellSize MotionDetector_GloballyIncOrDecSensitivity MotionDetector_GlobalMotionRatio MotionDetector_GreyScale MotionDetector_Grid MotionDetector_GridXCount MotionDetector_GridYCount MotionDetector_IsGridValid MotionDetector_MaxDetectionsPerSecond MotionDetector_ReduceCPULoad MotionDetector_ReduceVideoNoise MotionDetector_Reset MotionDetector_ResetGlobalSensitivity MotionDetector_SetCellSensitivity MotionDetector_SetGridSize MotionDetector_ShowGridDialog MotionDetector_Triggered MotionDetector_UseThisReferenceSample OnBacktimedFramesCountReached OnMotionDetected OnMotionNotDetected RecordingOnMotion_Enabled RecordingOnMotion_MotionThreshold RecordingOnMotion_NoMotionPauseDelayMs