- Qt 6.11
- Qt Multimedia
- QML Types
- WindowCapture
- Qt 6.11.0 Reference Documentation

# WindowCapture QML Type

This type is used for capturing a window. More...

Import Statement: | `import QtMultimedia`
Since: | Qt 6.6
In C++: | QWindowCapture

- List of all members, including inherited members

## Properties

- active : bool
- error : enumeration
- errorString : string
- window : Window

## Methods

- list<CapturableWindow> capturableWindows()
- start()
- stop()

## Detailed Description

WindowCapture captures a window. It is managed by MediaCaptureSession where the captured window can be displayed in a video preview object or recorded to a file.

## Window Capture Limitations

The following limitations apply to using WindowCapture:

- WindowCapture is only supported with the FFmpeg backend.

The following limitations apply when using `QWindowCapture` on X11 systems:

- On Linux X11 systems, when a window is moved partially outside the visible screen area, only the visible region is captured. As a result, the emitted video frames may have a size smaller than the window’s geometry.
- Windows that are outside the visible screen area cannot be captured, and an error signal is emitted in that case.

See also CaptureSession and CapturableWindow.

## Property Documentation

### active : bool

Describes whether the capturing is currently active.

### error : enumeration `[read-only]`

Returns a code of the last error.

### errorString : string `[read-only]`

Returns a human readable string describing the cause of error.

### window : Window

Describes the window for capturing.

See also QtMultimedia::WindowCapture::capturableWindows.

## Method Documentation

### list<CapturableWindow> capturableWindows()

Returns a list of CapturableWindow objects that is available for capturing.

### start()

### stop()