Video SDK v3.7.1 API Reference for Unity
Public Attributes | List of all members
agora_gaming_rtc.ScreenCaptureParameters Struct Reference

Public Attributes

VideoDimensions dimensions
 
int frameRate
 
int bitrate
 
bool captureMouseCursor
 
bool windowFocus
 
string[] excludeWindowList
 
int excludeWindowCount
 
int highLightWidth
 
uint highLightColor
 
bool enableHighLight
 

Detailed Description

Screen sharing encoding parameters.

Member Data Documentation

◆ dimensions

VideoDimensions agora_gaming_rtc.ScreenCaptureParameters.dimensions

The maximum encoding dimensions of the shared region in terms of width × height.

The default value is 1920 × 1080 pixels, that is, 2073600 pixels. Agora uses the value of this parameter to calculate the charges.

If the aspect ratio is different between the encoding dimensions and screen dimensions, Agora applies the following algorithms for encoding. Suppose the encoding dimensions are 1920 x 1080:

  • If the value of the screen dimensions is lower than that of the encoding dimensions, for example, 1000 × 1000, the SDK uses 1000 × 1000 for encoding.
  • If the value of the screen dimensions is higher than that of the encoding dimensions, for example, 2000 × 1500, the SDK uses the maximum value under 1920 × 1080 with the aspect ratio of the screen dimension (4:3) for encoding, that is, 1440 × 1080.

◆ frameRate

int agora_gaming_rtc.ScreenCaptureParameters.frameRate

The frame rate (fps) of the shared region.

The default value is 5. We do not recommend setting this to a value greater than 15.

◆ bitrate

int agora_gaming_rtc.ScreenCaptureParameters.bitrate

The bitrate (Kbps) of the shared region.

The default value is 0 (the SDK works out a bitrate according to the dimensions of the current screen).

◆ captureMouseCursor

bool agora_gaming_rtc.ScreenCaptureParameters.captureMouseCursor

Sets whether or not to capture the mouse for screen sharing:

  • true: (Default) Capture the mouse.
  • false: Do not capture the mouse.

◆ windowFocus

bool agora_gaming_rtc.ScreenCaptureParameters.windowFocus

Whether to bring the window to the front when calling StartScreenCaptureByWindowId to share the window:

  • true: Bring the window to the front.
  • false: (Default) Do not bring the window to the front.

◆ excludeWindowList

string [] agora_gaming_rtc.ScreenCaptureParameters.excludeWindowList

A list of IDs of windows to be blocked.

When calling StartScreenCaptureByScreenRect or StartScreenCaptureByWindowId to start screen sharing, you can use this parameter to block the specified windows. When calling UpdateScreenCaptureParameters to update the configuration for screen sharing, you can use this parameter to dynamically block the specified windows during screen sharing.

◆ excludeWindowCount

int agora_gaming_rtc.ScreenCaptureParameters.excludeWindowCount

The number of windows to be blocked.

◆ highLightWidth

int agora_gaming_rtc.ScreenCaptureParameters.highLightWidth

(macOS only) The width (px) of the border. Defaults to 0, and the value range is [0,50].

Since
3.7.0

◆ highLightColor

uint agora_gaming_rtc.ScreenCaptureParameters.highLightColor

(macOS only) The color of the border in RGBA format. The default value is 0xFF8CBF26.

Since
3.7.0

◆ enableHighLight

bool agora_gaming_rtc.ScreenCaptureParameters.enableHighLight

(macOS only) Determines whether to place a border around the shared window or screen:

  • true: Place a border.
  • false: (Default) Do not place a border.
    Since
    3.7.0
    Note
    When you share a part of a window or screen, the SDK places a border around the entire window or screen if you set enableHighLight as true.

The documentation for this struct was generated from the following file: