SetTextOverlay_CustomVar
procedure SetTextOverlay_CustomVar (Index: LongInt; VarIndex: LongInt; VarText: string);
void __fastcall SetTextOverlay_CustomVar(System::LongInt Index, System::LongInt VarIndex, System::UnicodeString VarText);
public void SetTextOverlay_CustomVar(int Index, int VarIndex, string VarText);
Public Sub SetTextOverlay_CustomVar(Index As Integer, VarIndex As Integer, VarText As String)
void SetTextOverlay_CustomVar (int Index, int VarIndex, wchar_t *VarText);
Sets a custom variable displayed in the TextOverlay string for the specified text overlay
Remarks
Used to set the custom variable displayed in the TextOverlay string.
Setting custom variables is faster than rewriting the full text overlay string, because it saves TVideoGrabber having to parse it again.
Parameters:
Index: index of the overlay VarIndex: index of the custom variable that has been set with SetTextOverlay_String (from 0 to 9)
VarText: text of the custom variable
E.g., to initialize the 2 text overlay string, that will use custom variables:
...
VideoGrabber.SetTextOverlay_String (0, "my first text uses %custom0%")
VideoGrabber.SetTextOverlay_Left (0, 10)
VideoGrabber.SetTextOverlay_Top (0, 10)
VideoGrabber.SetTextOverlay_Enabled (0, true)
VideoGrabber.SetTextOverlay_String (1, "my second text uses %custom3% and %custom4%")
VideoGrabber.SetTextOverlay_Left (1, 20)
VideoGrabber.SetTextOverlay_Top (1, 100)
VideoGrabber.SetTextOverlay_Enabled (1, true)
VideoGrabber.StartPreview ...
then to update the custom variables of the 1st text overlay string:
...
VideoGrabber.SetTextOverlay_CustomVar (0, 0, "value 0") ...
and of the 2nd text overlay string:
...
VideoGrabber.SetTextOverlay_CustomVar (1, 3, "value 3") VideoGrabber.SetTextOverlay_CustomVar (1, 4, "value 4") ...
See also SetTextOverlay_String .