zego-express-engine-electron-plugin-blend-image-private 1.2.13 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.d.ts +7 -244
- package/index.js +9 -159
- package/mac/ZegoBlendImageNode.node +0 -0
- package/mac/ZegoBlendImageNode.node.dSYM/Contents/Resources/DWARF/ZegoBlendImageNode.node +0 -0
- package/mac/ZegoBlendImageNode.node.dSYM/Contents/Resources/Relocations/aarch64/ZegoBlendImageNode.node.yml +4638 -0
- package/package.json +1 -1
- package/win/x64/ZegoBlendImageNode.node +0 -0
- package/win/x64/ZegoBlendImageNode.pdb +0 -0
- package/win/x86/ZegoBlendImageNode.node +0 -0
- package/win/x86/ZegoBlendImageNode.pdb +0 -0
- package/mac/libZegoScreenCaptureOSX.dylib +0 -0
- package/win/x64/ZegoScreenCapture.dll +0 -0
- package/win/x86/ZegoScreenCapture.dll +0 -0
package/index.d.ts
CHANGED
|
@@ -12,13 +12,14 @@ declare const ZegoExpressPluginBlendImageLogLevel: {
|
|
|
12
12
|
};
|
|
13
13
|
declare const ZGCustomCaptureSourceType: {
|
|
14
14
|
IMAGE_TYPE: number;
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
15
|
+
RTC_CAMERA: number;
|
|
16
|
+
RTC_VIDEO: number;
|
|
17
|
+
RTC_SCREEN: number;
|
|
18
|
+
RTC_WINDOW: number;
|
|
18
19
|
IMAGE_GIF_TYPE: number;
|
|
19
20
|
COMPLEX_TYPE: number;
|
|
20
|
-
WINDOW_TYPE: number;
|
|
21
21
|
CUSTOM_DATA_TYPE: number;
|
|
22
|
+
TEXT_TYPE: number;
|
|
22
23
|
};
|
|
23
24
|
/**
|
|
24
25
|
* ZegoExpressPluginCustomSourceLayer
|
|
@@ -68,168 +69,10 @@ declare const ZegoBlendImageViewMode: {
|
|
|
68
69
|
*/
|
|
69
70
|
ScaleToFill: number;
|
|
70
71
|
};
|
|
71
|
-
/**
|
|
72
|
-
* ZegoExpressPluginScreenCaptureWindowMode
|
|
73
|
-
* @enum {number}
|
|
74
|
-
*/
|
|
75
|
-
declare const ZegoExpressPluginScreenCaptureWindowMode: {
|
|
76
|
-
/**
|
|
77
|
-
* @description Capture the target window even when it's covered by other window.
|
|
78
|
-
*/
|
|
79
|
-
ScreenCaptureWindowModeNormal: number;
|
|
80
|
-
/**
|
|
81
|
-
* @description After the target window is covered, the covered area uses content of the upper window.
|
|
82
|
-
*/
|
|
83
|
-
ScreenCaptureWindowModeUseUpper: number;
|
|
84
|
-
/**
|
|
85
|
-
* @description Capture the whole screen of the window, compared with ScreenCaptureWindowModeNormal, there is no window switching process in this mode(only for windows).
|
|
86
|
-
*/
|
|
87
|
-
ScreenCaptureWindowModeNormal2: number;
|
|
88
|
-
};
|
|
89
|
-
declare const ZegoExpressPluginScreenCaptureWindowStatus: {
|
|
90
|
-
/**
|
|
91
|
-
* @description the target window has no change.
|
|
92
|
-
*/
|
|
93
|
-
ScreenCaptureWindowStatusNoChange: number;
|
|
94
|
-
/**
|
|
95
|
-
* @description the target window is destroyed.
|
|
96
|
-
*/
|
|
97
|
-
ScreenCaptureWindowStatusDestroy: number;
|
|
98
|
-
/**
|
|
99
|
-
* @description the target window is maximized.
|
|
100
|
-
*/
|
|
101
|
-
ScreenCaptureWindowStatusMaximize: number;
|
|
102
|
-
/**
|
|
103
|
-
* @description the target window is minimized.
|
|
104
|
-
*/
|
|
105
|
-
ScreenCaptureWindowStatusMinimize: number;
|
|
106
|
-
/**
|
|
107
|
-
* @description the target window is actived.
|
|
108
|
-
*/
|
|
109
|
-
ScreenCaptureWindowStatusActive: number;
|
|
110
|
-
/**
|
|
111
|
-
* @description the target window is deactived
|
|
112
|
-
*/
|
|
113
|
-
ScreenCaptureWindowStatusDeactive: number;
|
|
114
|
-
/**
|
|
115
|
-
* @description the target window is is showed
|
|
116
|
-
*/
|
|
117
|
-
ScreenCaptureWindowStatusShow: number;
|
|
118
|
-
/**
|
|
119
|
-
* @description the target window is hided
|
|
120
|
-
*/
|
|
121
|
-
ScreenCaptureWindowStatusHide: number;
|
|
122
|
-
/**
|
|
123
|
-
* @description the target window is movded
|
|
124
|
-
*/
|
|
125
|
-
ScreenCaptureWindowStatusMove: number;
|
|
126
|
-
/**
|
|
127
|
-
* @description the target window is covered
|
|
128
|
-
*/
|
|
129
|
-
ScreenCaptureWindowStatusCover: number;
|
|
130
|
-
/**
|
|
131
|
-
* @description the target window is uncovered
|
|
132
|
-
*/
|
|
133
|
-
ScreenCaptureWindowStatusUnCover: number;
|
|
134
|
-
};
|
|
135
|
-
/**
|
|
136
|
-
* Screen item
|
|
137
|
-
*/
|
|
138
|
-
interface IZegoExpressPluginScreenCaptureScreenItem {
|
|
139
|
-
/**
|
|
140
|
-
* identification for the screen
|
|
141
|
-
*/
|
|
142
|
-
screenID: any;
|
|
143
|
-
/**
|
|
144
|
-
* is the primary screen
|
|
145
|
-
*/
|
|
146
|
-
isPrimary: boolean;
|
|
147
|
-
}
|
|
148
|
-
/**
|
|
149
|
-
* Window item
|
|
150
|
-
*/
|
|
151
|
-
interface IZegoExpressPluginScreenCaptureWindowItem {
|
|
152
|
-
/**
|
|
153
|
-
* identification for the window
|
|
154
|
-
*/
|
|
155
|
-
handle: any;
|
|
156
|
-
/**
|
|
157
|
-
* window title
|
|
158
|
-
*/
|
|
159
|
-
title: string;
|
|
160
|
-
/**
|
|
161
|
-
* The path of process binary that the window corresponds to
|
|
162
|
-
* support only on windows
|
|
163
|
-
*/
|
|
164
|
-
imagePath: string;
|
|
165
|
-
}
|
|
166
|
-
interface IZegoExpressPluginScreenCaptureThumbnailBitmap {
|
|
167
|
-
/**
|
|
168
|
-
* with
|
|
169
|
-
*/
|
|
170
|
-
width: number;
|
|
171
|
-
/**
|
|
172
|
-
* height
|
|
173
|
-
*/
|
|
174
|
-
height: number;
|
|
175
|
-
/**
|
|
176
|
-
* the base64 data of the image
|
|
177
|
-
* example: h5.img.setAttribute('src', "data:image/png;base64," + png)
|
|
178
|
-
*/
|
|
179
|
-
png: any;
|
|
180
|
-
}
|
|
181
|
-
/**
|
|
182
|
-
* Screen thumbnail item
|
|
183
|
-
*/
|
|
184
|
-
interface IZegoExpressPluginScreenCaptureScreenThumbnailItem {
|
|
185
|
-
/**
|
|
186
|
-
* identification for the screen
|
|
187
|
-
*/
|
|
188
|
-
screenID: any;
|
|
189
|
-
/**
|
|
190
|
-
* screen thumbnail
|
|
191
|
-
*/
|
|
192
|
-
imageThumbnail: IZegoExpressPluginScreenCaptureThumbnailBitmap;
|
|
193
|
-
}
|
|
194
|
-
/**
|
|
195
|
-
* Window thumbnail item
|
|
196
|
-
*/
|
|
197
|
-
interface IZegoExpressPluginScreenCaptureWindowThumbnailItem {
|
|
198
|
-
/**
|
|
199
|
-
* identification for the window
|
|
200
|
-
*/
|
|
201
|
-
handle: any;
|
|
202
|
-
/**
|
|
203
|
-
* window thumbnail
|
|
204
|
-
* could be null if sdk cannot get the imageThumnail from the system.
|
|
205
|
-
*/
|
|
206
|
-
imageThumbnail: IZegoExpressPluginScreenCaptureThumbnailBitmap;
|
|
207
|
-
/**
|
|
208
|
-
* window icon thumbnail
|
|
209
|
-
*/
|
|
210
|
-
iconThumbnail: IZegoExpressPluginScreenCaptureThumbnailBitmap;
|
|
211
|
-
}
|
|
212
|
-
/**
|
|
213
|
-
* Rect
|
|
214
|
-
*
|
|
215
|
-
* (x,y)
|
|
216
|
-
* ---------------
|
|
217
|
-
* | |
|
|
218
|
-
* | | height
|
|
219
|
-
* | |
|
|
220
|
-
* ---------------
|
|
221
|
-
* width
|
|
222
|
-
*/
|
|
223
|
-
interface IZegoExpressPluginScreenCaptureRect {
|
|
224
|
-
x: number;
|
|
225
|
-
y: number;
|
|
226
|
-
width: number;
|
|
227
|
-
height: number;
|
|
228
|
-
}
|
|
229
72
|
/**
|
|
230
73
|
* IZegoExpressPluginErrorInfo
|
|
231
74
|
*
|
|
232
|
-
* @remark use by
|
|
75
|
+
* @remark use by onLoadSourceParamError(callback)
|
|
233
76
|
*
|
|
234
77
|
* @param error, error code
|
|
235
78
|
* @param source, return by the function "createCustomCaptureSource()"
|
|
@@ -245,15 +88,6 @@ interface IZegoExpressPluginErrorInfo {
|
|
|
245
88
|
* ZegoExpressPluginBlendImageEventHandler
|
|
246
89
|
*/
|
|
247
90
|
interface ZegoExpressPluginBlendImageEventHandler {
|
|
248
|
-
/**
|
|
249
|
-
* onScreenCaptureError
|
|
250
|
-
*
|
|
251
|
-
* @remark this callback will trigger when capture error occurred, source always is zero
|
|
252
|
-
*
|
|
253
|
-
* @param {IZegoExpressPluginErrorInfo} errorInfo - the error struct
|
|
254
|
-
*
|
|
255
|
-
*/
|
|
256
|
-
onScreenCaptureError: (errorInfo: IZegoExpressPluginErrorInfo) => void;
|
|
257
91
|
/**
|
|
258
92
|
* onLoadSourceParamError
|
|
259
93
|
*
|
|
@@ -262,16 +96,6 @@ interface ZegoExpressPluginBlendImageEventHandler {
|
|
|
262
96
|
* @param {IZegoExpressPluginErrorInfo} errorInfo - the error struct
|
|
263
97
|
*/
|
|
264
98
|
onLoadSourceParamError: (errorInfo: IZegoExpressPluginErrorInfo) => void;
|
|
265
|
-
/**
|
|
266
|
-
* onScreenCaptureWindowStatusChanged
|
|
267
|
-
*
|
|
268
|
-
* @remark this callback will trigger when the status of the window captured changed
|
|
269
|
-
*
|
|
270
|
-
* @param {any} handle - identification for the window
|
|
271
|
-
* @param {ZegoExpressPluginScreenCaptureWindowStatus} windowStatus - the status of the window
|
|
272
|
-
* @param {IZegoExpressPluginScreenCaptureRect} windowRect - the rect of the window
|
|
273
|
-
*/
|
|
274
|
-
onScreenCaptureWindowStatusChanged: (handle: any, windowStatus: number, windowRect: IZegoExpressPluginScreenCaptureRect) => void;
|
|
275
99
|
}
|
|
276
100
|
/**
|
|
277
101
|
* ZegoExpressPluginBlendImage
|
|
@@ -304,39 +128,6 @@ declare class ZegoExpressPluginBlendImage extends EventEmitter {
|
|
|
304
128
|
* Uninit screen capture.
|
|
305
129
|
*/
|
|
306
130
|
uninit(): void;
|
|
307
|
-
/**
|
|
308
|
-
* Get screen list.
|
|
309
|
-
*
|
|
310
|
-
* @return {Array<IZegoExpressPluginScreenCaptureScreenItem>} - the screen list
|
|
311
|
-
*/
|
|
312
|
-
enumScreenList(): Array<IZegoExpressPluginScreenCaptureScreenItem>;
|
|
313
|
-
/**
|
|
314
|
-
* Get screen thumbnail list.
|
|
315
|
-
*
|
|
316
|
-
* @return {Promise<Array<IZegoExpressPluginScreenCaptureScreenThumbnailItem>>} - the screen thumbnail list
|
|
317
|
-
*/
|
|
318
|
-
enumScreenThumbnail(): Promise<Array<IZegoExpressPluginScreenCaptureScreenThumbnailItem>>;
|
|
319
|
-
/**
|
|
320
|
-
* Get window list.
|
|
321
|
-
*
|
|
322
|
-
* @param {boolean} isIncludeIconic - include the iconic window or not
|
|
323
|
-
*
|
|
324
|
-
* @return {Array<IZegoExpressPluginScreenCaptureWindowItem>} - the window list
|
|
325
|
-
*/
|
|
326
|
-
enumWindowList(isIncludeIconic?: boolean): Array<IZegoExpressPluginScreenCaptureWindowItem>;
|
|
327
|
-
/**
|
|
328
|
-
* Get window thumbnail list.
|
|
329
|
-
*
|
|
330
|
-
* @return {Promise<Array<IZegoExpressPluginScreenCaptureWindowThumbnailItem>>} - the window thumbnail list
|
|
331
|
-
*/
|
|
332
|
-
enumWindowThumbnail(): Promise<Array<IZegoExpressPluginScreenCaptureWindowThumbnailItem>>;
|
|
333
|
-
/**
|
|
334
|
-
* 检测窗口是否可以采集,若还未获取辅助功能权限,则调用该函数会申请辅助功能,Windows和Mac均可调用,只有Mac生效;
|
|
335
|
-
* @param {object} option - 参数对象
|
|
336
|
-
* @param {number} option.handle - 窗口句柄,目标窗口句柄,从接口enumWindowList 返回的对象数组列表中每项的handle字段
|
|
337
|
-
* @return {boolean} 是否可以采集该窗口
|
|
338
|
-
*/
|
|
339
|
-
checkWindowSourceAuthorityPermission(handle: number): boolean;
|
|
340
131
|
/**
|
|
341
132
|
* 预览源数据,同一时间只允许预览一个源数据(变更源可以直接切换到其他源预览,不支持合图源),如果需要预览时不合图,可以调用setCustomCaptureSourceVisible
|
|
342
133
|
* @param {number} captureSrc
|
|
@@ -357,17 +148,6 @@ declare class ZegoExpressPluginBlendImage extends EventEmitter {
|
|
|
357
148
|
* @return {number} -1 - 失败, 结果大于0 返回自定义采集源句柄
|
|
358
149
|
*/
|
|
359
150
|
createCustomCaptureSource(captureType: number, dataPlugin?: any): number;
|
|
360
|
-
/**
|
|
361
|
-
* 设置窗口采集源的参数
|
|
362
|
-
* @param {object} option - 参数对象
|
|
363
|
-
* @param {number} option.captureSrc - 窗口采集源,填写通过createCustomCaptureSource接口创建返回的窗口采集源
|
|
364
|
-
* @param {boolean} option.activateWindowWhenCapturing - 在目标窗口模式下,初次选择窗口时,设置是否激活窗口,true - 激活窗口,false - 不激活窗口 (仅windows有效)
|
|
365
|
-
* @param {number} option.targetWindow - 设置采集目标窗口句柄,从接口enumWindowList 返回的对象数组列表中每项的handle字段
|
|
366
|
-
* @param {number} option.fps - 设置采集的帧率
|
|
367
|
-
* @param {number} option.targetWindowMode 1 - 窗口截屏,带窗口标题栏, 2 - 窗口客户区截屏,不带窗口标题栏,3 - 截取窗口对应屏幕区域 (窗口被覆盖后继续捕获对应区域). 4 - 截取窗口对应屏幕区域(窗口被覆盖后继续捕获,覆盖区域涂黑. 5 -截取窗口对应屏幕区域(窗口被覆盖后继续捕获,过滤上层覆盖的窗口,win8及以后系统生效)
|
|
368
|
-
*
|
|
369
|
-
*/
|
|
370
|
-
setWindowCaptureSourceParam(captureSrc: number, activateWindowWhenCapturing?: boolean, targetWindow?: number, fps?: number, targetWindowMode?: number): boolean;
|
|
371
151
|
/**
|
|
372
152
|
*
|
|
373
153
|
* @param captureSrc 自定义采集源对象
|
|
@@ -398,23 +178,6 @@ declare class ZegoExpressPluginBlendImage extends EventEmitter {
|
|
|
398
178
|
* @return {boolean} true - 成功, false - 失败,输入的源无效
|
|
399
179
|
*/
|
|
400
180
|
setImageGifCaptureSourceParam(captureSrc: number, imagePath: string): boolean;
|
|
401
|
-
/**
|
|
402
|
-
* 设置屏幕分享源的参数
|
|
403
|
-
* @param {object} option - 参数对象
|
|
404
|
-
* @param {number} option.captureSrc - 屏幕采集源,填写通过createCustomCaptureSource接口创建返回的屏幕采集源
|
|
405
|
-
* @param {string} option.targetScreen - 设置采集目标屏幕名,从接口enumScreenList 返回的对象数组列表中每项的screen_name字段
|
|
406
|
-
* @param {number} option.fps - 设置采集的帧率
|
|
407
|
-
* @param {boolean} option.fullScreen -设置采集主屏幕全屏,true - 采集全屏
|
|
408
|
-
* @param {boolean} option.virtualFullScreen - 设置采集虚拟桌面全屏,true - 采集虚拟全屏。在full_screen为false时有效
|
|
409
|
-
* @param {boolean} option.cursorVisible - 是否显示光标,true - 显示,false - 不显示
|
|
410
|
-
* @param {boolean} option.clickAnimation - 是否显示鼠标点击动画,true - 显示鼠标点击动画, false - 不显示鼠标点击动画
|
|
411
|
-
* @param {number} option.targetRectLeft - 设置采集目标区域,单位为像素,支持高DPI,目标区域左上角横坐标
|
|
412
|
-
* @param {number} option.targetRectTop - 目标区域左上角纵坐标
|
|
413
|
-
* @param {number} option.targetRectWidth - 目标区域宽
|
|
414
|
-
* @param {number} option.targetRectHeight - 目标区域高
|
|
415
|
-
*
|
|
416
|
-
*/
|
|
417
|
-
setScreenCaptureSourceParam(captureSrc: number, targetScreen?: string, fps?: number, fullScreen?: boolean, virtualFullScreen?: boolean, cursorVisible?: boolean, clickAnimation?: boolean, targetRectLeft?: number, targetRectTop?: number, targetRectWidth?: number, targetRectHeight?: number): boolean;
|
|
418
181
|
/**
|
|
419
182
|
* 设置组合源输出大小
|
|
420
183
|
* @param {object} option - 参数对象
|
|
@@ -518,4 +281,4 @@ declare class ZegoExpressPluginBlendImage extends EventEmitter {
|
|
|
518
281
|
private callEmit;
|
|
519
282
|
}
|
|
520
283
|
declare const ZegoExpressPluginBlendImageInstance: ZegoExpressPluginBlendImage;
|
|
521
|
-
export { ZegoExpressPluginBlendImageLogLevel, ZGCustomCaptureSourceType, ZegoExpressPluginCustomSourceLayer, ZegoBlendImageViewMode,
|
|
284
|
+
export { ZegoExpressPluginBlendImageLogLevel, ZGCustomCaptureSourceType, ZegoExpressPluginCustomSourceLayer, ZegoBlendImageViewMode, ZegoExpressPluginBlendImageEventHandler, ZegoExpressPluginBlendImageInstance };
|
package/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ZegoExpressPluginBlendImageInstance = exports.
|
|
3
|
+
exports.ZegoExpressPluginBlendImageInstance = exports.ZegoBlendImageViewMode = exports.ZegoExpressPluginCustomSourceLayer = exports.ZGCustomCaptureSourceType = exports.ZegoExpressPluginBlendImageLogLevel = void 0;
|
|
4
4
|
let os = require("os");
|
|
5
5
|
let ZegoBlendImageNodeArch = "";
|
|
6
6
|
if (os.platform() === "win32") {
|
|
@@ -31,13 +31,14 @@ const ZegoExpressPluginBlendImageLogLevel = {
|
|
|
31
31
|
exports.ZegoExpressPluginBlendImageLogLevel = ZegoExpressPluginBlendImageLogLevel;
|
|
32
32
|
const ZGCustomCaptureSourceType = {
|
|
33
33
|
IMAGE_TYPE: 0,
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
34
|
+
RTC_CAMERA: 1,
|
|
35
|
+
RTC_VIDEO: 2,
|
|
36
|
+
RTC_SCREEN: 3,
|
|
37
|
+
RTC_WINDOW: 4,
|
|
38
|
+
IMAGE_GIF_TYPE: 5,
|
|
39
|
+
COMPLEX_TYPE: 6,
|
|
40
40
|
CUSTOM_DATA_TYPE: 7,
|
|
41
|
+
TEXT_TYPE: 8
|
|
41
42
|
};
|
|
42
43
|
exports.ZGCustomCaptureSourceType = ZGCustomCaptureSourceType;
|
|
43
44
|
/**
|
|
@@ -90,72 +91,6 @@ const ZegoBlendImageViewMode = {
|
|
|
90
91
|
ScaleToFill: 2,
|
|
91
92
|
};
|
|
92
93
|
exports.ZegoBlendImageViewMode = ZegoBlendImageViewMode;
|
|
93
|
-
/**
|
|
94
|
-
* ZegoExpressPluginScreenCaptureWindowMode
|
|
95
|
-
* @enum {number}
|
|
96
|
-
*/
|
|
97
|
-
const ZegoExpressPluginScreenCaptureWindowMode = {
|
|
98
|
-
/**
|
|
99
|
-
* @description Capture the target window even when it's covered by other window.
|
|
100
|
-
*/
|
|
101
|
-
ScreenCaptureWindowModeNormal: 1,
|
|
102
|
-
/**
|
|
103
|
-
* @description After the target window is covered, the covered area uses content of the upper window.
|
|
104
|
-
*/
|
|
105
|
-
ScreenCaptureWindowModeUseUpper: 2,
|
|
106
|
-
/**
|
|
107
|
-
* @description Capture the whole screen of the window, compared with ScreenCaptureWindowModeNormal, there is no window switching process in this mode(only for windows).
|
|
108
|
-
*/
|
|
109
|
-
ScreenCaptureWindowModeNormal2: 3,
|
|
110
|
-
};
|
|
111
|
-
exports.ZegoExpressPluginScreenCaptureWindowMode = ZegoExpressPluginScreenCaptureWindowMode;
|
|
112
|
-
const ZegoExpressPluginScreenCaptureWindowStatus = {
|
|
113
|
-
/**
|
|
114
|
-
* @description the target window has no change.
|
|
115
|
-
*/
|
|
116
|
-
ScreenCaptureWindowStatusNoChange: 0,
|
|
117
|
-
/**
|
|
118
|
-
* @description the target window is destroyed.
|
|
119
|
-
*/
|
|
120
|
-
ScreenCaptureWindowStatusDestroy: 1,
|
|
121
|
-
/**
|
|
122
|
-
* @description the target window is maximized.
|
|
123
|
-
*/
|
|
124
|
-
ScreenCaptureWindowStatusMaximize: 2,
|
|
125
|
-
/**
|
|
126
|
-
* @description the target window is minimized.
|
|
127
|
-
*/
|
|
128
|
-
ScreenCaptureWindowStatusMinimize: 3,
|
|
129
|
-
/**
|
|
130
|
-
* @description the target window is actived.
|
|
131
|
-
*/
|
|
132
|
-
ScreenCaptureWindowStatusActive: 4,
|
|
133
|
-
/**
|
|
134
|
-
* @description the target window is deactived
|
|
135
|
-
*/
|
|
136
|
-
ScreenCaptureWindowStatusDeactive: 5,
|
|
137
|
-
/**
|
|
138
|
-
* @description the target window is is showed
|
|
139
|
-
*/
|
|
140
|
-
ScreenCaptureWindowStatusShow: 6,
|
|
141
|
-
/**
|
|
142
|
-
* @description the target window is hided
|
|
143
|
-
*/
|
|
144
|
-
ScreenCaptureWindowStatusHide: 7,
|
|
145
|
-
/**
|
|
146
|
-
* @description the target window is movded
|
|
147
|
-
*/
|
|
148
|
-
ScreenCaptureWindowStatusMove: 8,
|
|
149
|
-
/**
|
|
150
|
-
* @description the target window is covered
|
|
151
|
-
*/
|
|
152
|
-
ScreenCaptureWindowStatusCover: 9,
|
|
153
|
-
/**
|
|
154
|
-
* @description the target window is uncovered
|
|
155
|
-
*/
|
|
156
|
-
ScreenCaptureWindowStatusUnCover: 10,
|
|
157
|
-
};
|
|
158
|
-
exports.ZegoExpressPluginScreenCaptureWindowStatus = ZegoExpressPluginScreenCaptureWindowStatus;
|
|
159
94
|
;
|
|
160
95
|
/**
|
|
161
96
|
* ZegoExpressPluginBlendImage
|
|
@@ -204,49 +139,6 @@ class ZegoExpressPluginBlendImage extends EventEmitter {
|
|
|
204
139
|
this.removeAllListeners();
|
|
205
140
|
this._addonInstance.uninit({});
|
|
206
141
|
}
|
|
207
|
-
/**
|
|
208
|
-
* Get screen list.
|
|
209
|
-
*
|
|
210
|
-
* @return {Array<IZegoExpressPluginScreenCaptureScreenItem>} - the screen list
|
|
211
|
-
*/
|
|
212
|
-
enumScreenList() {
|
|
213
|
-
return this._addonInstance.enumScreenList({});
|
|
214
|
-
}
|
|
215
|
-
/**
|
|
216
|
-
* Get screen thumbnail list.
|
|
217
|
-
*
|
|
218
|
-
* @return {Promise<Array<IZegoExpressPluginScreenCaptureScreenThumbnailItem>>} - the screen thumbnail list
|
|
219
|
-
*/
|
|
220
|
-
enumScreenThumbnail() {
|
|
221
|
-
return this._addonInstance.enumScreenThumbnail({});
|
|
222
|
-
}
|
|
223
|
-
/**
|
|
224
|
-
* Get window list.
|
|
225
|
-
*
|
|
226
|
-
* @param {boolean} isIncludeIconic - include the iconic window or not
|
|
227
|
-
*
|
|
228
|
-
* @return {Array<IZegoExpressPluginScreenCaptureWindowItem>} - the window list
|
|
229
|
-
*/
|
|
230
|
-
enumWindowList(isIncludeIconic = true) {
|
|
231
|
-
return this._addonInstance.enumWindowList({ isIncludeIconic });
|
|
232
|
-
}
|
|
233
|
-
/**
|
|
234
|
-
* Get window thumbnail list.
|
|
235
|
-
*
|
|
236
|
-
* @return {Promise<Array<IZegoExpressPluginScreenCaptureWindowThumbnailItem>>} - the window thumbnail list
|
|
237
|
-
*/
|
|
238
|
-
enumWindowThumbnail() {
|
|
239
|
-
return this._addonInstance.enumWindowThumbnail({});
|
|
240
|
-
}
|
|
241
|
-
/**
|
|
242
|
-
* 检测窗口是否可以采集,若还未获取辅助功能权限,则调用该函数会申请辅助功能,Windows和Mac均可调用,只有Mac生效;
|
|
243
|
-
* @param {object} option - 参数对象
|
|
244
|
-
* @param {number} option.handle - 窗口句柄,目标窗口句柄,从接口enumWindowList 返回的对象数组列表中每项的handle字段
|
|
245
|
-
* @return {boolean} 是否可以采集该窗口
|
|
246
|
-
*/
|
|
247
|
-
checkWindowSourceAuthorityPermission(handle) {
|
|
248
|
-
return this._addonInstance.checkWindowSourceAuthorityPermission({ handle });
|
|
249
|
-
}
|
|
250
142
|
/**
|
|
251
143
|
* 预览源数据,同一时间只允许预览一个源数据(变更源可以直接切换到其他源预览,不支持合图源),如果需要预览时不合图,可以调用setCustomCaptureSourceVisible
|
|
252
144
|
* @param {number} captureSrc
|
|
@@ -287,19 +179,6 @@ class ZegoExpressPluginBlendImage extends EventEmitter {
|
|
|
287
179
|
createCustomCaptureSource(captureType, dataPlugin = 0) {
|
|
288
180
|
return this._addonInstance.createCustomCaptureSource({ captureType, dataPlugin });
|
|
289
181
|
}
|
|
290
|
-
/**
|
|
291
|
-
* 设置窗口采集源的参数
|
|
292
|
-
* @param {object} option - 参数对象
|
|
293
|
-
* @param {number} option.captureSrc - 窗口采集源,填写通过createCustomCaptureSource接口创建返回的窗口采集源
|
|
294
|
-
* @param {boolean} option.activateWindowWhenCapturing - 在目标窗口模式下,初次选择窗口时,设置是否激活窗口,true - 激活窗口,false - 不激活窗口 (仅windows有效)
|
|
295
|
-
* @param {number} option.targetWindow - 设置采集目标窗口句柄,从接口enumWindowList 返回的对象数组列表中每项的handle字段
|
|
296
|
-
* @param {number} option.fps - 设置采集的帧率
|
|
297
|
-
* @param {number} option.targetWindowMode 1 - 窗口截屏,带窗口标题栏, 2 - 窗口客户区截屏,不带窗口标题栏,3 - 截取窗口对应屏幕区域 (窗口被覆盖后继续捕获对应区域). 4 - 截取窗口对应屏幕区域(窗口被覆盖后继续捕获,覆盖区域涂黑. 5 -截取窗口对应屏幕区域(窗口被覆盖后继续捕获,过滤上层覆盖的窗口,win8及以后系统生效)
|
|
298
|
-
*
|
|
299
|
-
*/
|
|
300
|
-
setWindowCaptureSourceParam(captureSrc, activateWindowWhenCapturing = true, targetWindow = 0, fps = 10, targetWindowMode = 5) {
|
|
301
|
-
return this._addonInstance.setWindowCaptureSourceParam({ captureSrc, activateWindowWhenCapturing, targetWindow, fps, targetWindowMode });
|
|
302
|
-
}
|
|
303
182
|
/**
|
|
304
183
|
*
|
|
305
184
|
* @param captureSrc 自定义采集源对象
|
|
@@ -338,35 +217,6 @@ class ZegoExpressPluginBlendImage extends EventEmitter {
|
|
|
338
217
|
setImageGifCaptureSourceParam(captureSrc, imagePath) {
|
|
339
218
|
return this._addonInstance.setImageGifCaptureSourceParam({ captureSrc, imagePath });
|
|
340
219
|
}
|
|
341
|
-
/**
|
|
342
|
-
* 设置屏幕分享源的参数
|
|
343
|
-
* @param {object} option - 参数对象
|
|
344
|
-
* @param {number} option.captureSrc - 屏幕采集源,填写通过createCustomCaptureSource接口创建返回的屏幕采集源
|
|
345
|
-
* @param {string} option.targetScreen - 设置采集目标屏幕名,从接口enumScreenList 返回的对象数组列表中每项的screen_name字段
|
|
346
|
-
* @param {number} option.fps - 设置采集的帧率
|
|
347
|
-
* @param {boolean} option.fullScreen -设置采集主屏幕全屏,true - 采集全屏
|
|
348
|
-
* @param {boolean} option.virtualFullScreen - 设置采集虚拟桌面全屏,true - 采集虚拟全屏。在full_screen为false时有效
|
|
349
|
-
* @param {boolean} option.cursorVisible - 是否显示光标,true - 显示,false - 不显示
|
|
350
|
-
* @param {boolean} option.clickAnimation - 是否显示鼠标点击动画,true - 显示鼠标点击动画, false - 不显示鼠标点击动画
|
|
351
|
-
* @param {number} option.targetRectLeft - 设置采集目标区域,单位为像素,支持高DPI,目标区域左上角横坐标
|
|
352
|
-
* @param {number} option.targetRectTop - 目标区域左上角纵坐标
|
|
353
|
-
* @param {number} option.targetRectWidth - 目标区域宽
|
|
354
|
-
* @param {number} option.targetRectHeight - 目标区域高
|
|
355
|
-
*
|
|
356
|
-
*/
|
|
357
|
-
setScreenCaptureSourceParam(captureSrc, targetScreen = "", fps = 10, fullScreen = true, virtualFullScreen = false, cursorVisible = true, clickAnimation = true, targetRectLeft = 0, targetRectTop = 0, targetRectWidth = 0, targetRectHeight = 0) {
|
|
358
|
-
return this._addonInstance.setScreenCaptureSourceParam({ captureSrc,
|
|
359
|
-
targetScreen,
|
|
360
|
-
fps,
|
|
361
|
-
fullScreen,
|
|
362
|
-
virtualFullScreen,
|
|
363
|
-
cursorVisible,
|
|
364
|
-
clickAnimation,
|
|
365
|
-
targetRectLeft,
|
|
366
|
-
targetRectTop,
|
|
367
|
-
targetRectWidth,
|
|
368
|
-
targetRectHeight });
|
|
369
|
-
}
|
|
370
220
|
/**
|
|
371
221
|
* 设置组合源输出大小
|
|
372
222
|
* @param {object} option - 参数对象
|
|
@@ -515,7 +365,7 @@ class ZegoExpressPluginBlendImage extends EventEmitter {
|
|
|
515
365
|
}
|
|
516
366
|
}
|
|
517
367
|
else {
|
|
518
|
-
const highFrequencyCallbacks = ["onDebugError"
|
|
368
|
+
const highFrequencyCallbacks = ["onDebugError"];
|
|
519
369
|
if (!highFrequencyCallbacks.includes(arguments[0])) {
|
|
520
370
|
console.log(arguments[0], arguments[1]);
|
|
521
371
|
}
|
|
Binary file
|