ScreenCaptureConfiguration

Screen capture configuration.

class ScreenCaptureConfiguration {
  const ScreenCaptureConfiguration(
      {this.isCaptureWindow,
      this.displayId,
      this.screenRect,
      this.windowId,
      this.params,
      this.regionRect});

  @JsonKey(name: 'isCaptureWindow')
  final bool? isCaptureWindow;
  @JsonKey(name: 'displayId')
  final int? displayId;
  @JsonKey(name: 'screenRect')
  final Rectangle? screenRect;
  @JsonKey(name: 'windowId')
  final int? windowId;
  @JsonKey(name: 'params')
  final ScreenCaptureParameters? params;
  @JsonKey(name: 'regionRect')
  final Rectangle? regionRect;
  factory ScreenCaptureConfiguration.fromJson(Map<String, dynamic> json) =>
      _$ScreenCaptureConfigurationFromJson(json);
  Map<String, dynamic> toJson() => _$ScreenCaptureConfigurationToJson(this);
}

Properties

isCaptureWindow
Whether to capture a window on the screen:
  • true: Capture window.
  • false: (Default) Capture screen, not window.
displayId
(macOS only) Display ID of the screen.
Note: Use this parameter only when capturing the screen on Mac devices.
screenRect
(Windows only) Position of the screen to be shared relative to the virtual screen.
Note: Use this parameter only when capturing the screen on Windows devices.
windowId
(Windows and macOS only) Window ID.
Note: Use this parameter only when capturing a window.
params
(Windows and macOS only) Encoding parameter configuration for screen sharing stream. See ScreenCaptureParameters.
regionRect
(Windows and macOS only) Position of the region to be shared relative to the entire screen. See Rectangle. If not set, the entire screen is shared. If the specified region exceeds screen boundaries, only the content within the screen is shared. If width or height in Rectangle is set to 0, the entire screen is shared.