Skip to main content

Code sample - Screen capture

Delphi and C# (ActiveX) sample code.

You can record both the entire screen and a certain area of it.

Use the following parameters to set the area coordinates:

VideoCapture1.Screen_Capture_Top := StrToInt(edScreenTop.Text);
VideoCapture1.Screen_Capture_Bottom := StrToInt(edScreenBottom.Text);
VideoCapture1.Screen_Capture_Left := StrToInt(edScreenLeft.Text);
VideoCapture1.Screen_Capture_Right := StrToInt(edScreenRight.Text);
VideoCapture1.Screen_Capture_Top = Convert.ToInt32(edScreenTop.Text);
VideoCapture1.Screen_Capture_Bottom = Convert.ToInt32(edScreenBottom.Text);
VideoCapture1.Screen_Capture_Left = Convert.ToInt32(edScreenLeft.Text);
VideoCapture1.Screen_Capture_Right = Convert.ToInt32(edScreenRight.Text);

or

Set

VideoCapture1.Screen_Capture_FullScreen := true;
VideoCapture1.Screen_Capture_FullScreen = true;

to record the entire screen.

Use

VideoCapture1.Screen_Capture_FrameRate := 10;
VideoCapture1.Screen_Capture_FrameRate = 10;

to set the frame rate.

Set

VideoCapture1.Screen_Capture_Grab_Mouse_Cursor := true;
VideoCapture1.Screen_Capture_Grab_Mouse_Cursor = true;

to capture the mouse cursor

Set screen capture mode.

VideoCapture1.Mode := Mode_Screen_Capture;
VideoCapture1.Mode = VisioForge_Video_Capture_5.TxVFMode.Mode_Screen_Capture; 

Please get in touch with support to get help with this tutorial. Visit our GitHub page to get more code samples.