ZegoScreenCaptureSource Class Reference

Inherits from NSObject
Declared in ZegoExpressDefines.h

– setEventHandler:

Event handler for real-time sequential data.

- (void)setEventHandler:(nullable id<ZegoScreenCaptureSourceEventHandler>)handler

Parameters

handler

Event handler for real-time sequential data.

Declared In

ZegoExpressDefines.h

– updateCaptureSource:sourceType:

The specified screen ID or window ID.

- (void)updateCaptureSource:(unsigned int)sourceId sourceType:(ZegoScreenCaptureSourceType)sourceType

Parameters

sourceId

The specified screen ID or window ID.

sourceType

The specified screen source type.

Declared In

ZegoExpressDefines.h

– startCapture

Available since: 3.1.0 Description: Start screen capture. When to call: It can be called after the engine by [createScreenCaptureSource] has been initialized.

- (void)startCapture

Declared In

ZegoExpressDefines.h

– stopCapture

Available since: 3.1.0 Description: Stop screen capture.

- (void)stopCapture

Declared In

ZegoExpressDefines.h

– getCaptureSourceRect

Rect information about the capture resource.

- (CGRect)getCaptureSourceRect

Return Value

Rect information about the capture resource.

Declared In

ZegoExpressDefines.h

– updateCaptureRegion:

The position of the area to be captured relative to the entire screen or window.

- (void)updateCaptureRegion:(CGRect)rect

Parameters

rect

The position of the area to be captured relative to the entire screen or window.

Declared In

ZegoExpressDefines.h

– updatePublishRegion:

The position of the area to be pushed relative to the upper left corner of the capture screen, the actual capture screen size can be obtained through [onAvailableFrame].

- (void)updatePublishRegion:(CGRect)rect

Parameters

rect

The position of the area to be pushed relative to the upper left corner of the capture screen, the actual capture screen size can be obtained through [onAvailableFrame].

Declared In

ZegoExpressDefines.h

– setExcludeWindowList:

List of IDs to filter windows.

- (void)setExcludeWindowList:(NSArray<NSNumber*> *)list

Parameters

list

List of IDs to filter windows.

Declared In

ZegoExpressDefines.h

– enableWindowActivate:

Whether to activate the window. YES to activate the window, NO to not activate the window, the default is YES.

- (void)enableWindowActivate:(BOOL)active

Parameters

active

Whether to activate the window. YES to activate the window, NO to not activate the window, the default is YES.

Declared In

ZegoExpressDefines.h

– enableCursorVisible:

Whether to show the cursor. YES to show the cursor, NO to not show the cursor, the default is NO.

- (void)enableCursorVisible:(BOOL)visible

Parameters

visible

Whether to show the cursor. YES to show the cursor, NO to not show the cursor, the default is NO.

Declared In

ZegoExpressDefines.h

– getIndex

Index of the screen capture source.

- (NSNumber *)getIndex

Return Value

Index of the screen capture source.

Declared In

ZegoExpressDefines.h

+ new

Please use the [createScreenCaptureSource] function in ZegoExpressEngine class instead.

+ (instancetype)new

Declared In

ZegoExpressDefines.h

– init

Please use the [createScreenCaptureSource] function in ZegoExpressEngine class instead.

- (instancetype)init

Declared In

ZegoExpressDefines.h