Desktop capture

Prev

Next

 






































































































Desktop capture

Description

How to perform a desktop capture

- set VideoSource = vs_ScreenRecording
- invoke StartPreview
- minimizes the app (or make it non-visible)
- then it is possible to capture the desktop image to a memory bitmap or a BMP or JPEG file by invoking CaptureFrameTo, or perform a screen recording as explained in the recording the screen with or without cursor chapter.

This can be quick tested in 2 clicks by using MainDemo.exe included in the package as follows:

- run MainDemo.exe
- in the "video source" tab, select video source = "screen recording"
- click StartPreview
- go to the "frame grabber" tab
- move the MainDemo.exe window at the bottom of the desktop (to hide most of the MainDemo.exe app), just keep the buttons of "one shot frame capture" group visible,
- then click "BMP file" or "JPEG file"to capture the desktop image to a file, or "TBitmap" to capture it to a new window.

Of course, the app must be kept minimized (or not visible) to capture the desktop without capturing your app's window.

Remark: if some special windows appear black in the captured image, enable the ScreenRecordingThroughClipboard property.