zego-express-engine-electron-private 3.6.0-29708 → 3.7.0-30160
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/ZegoExpressCopyrightedMusic.js +3 -3
- package/ZegoExpressDefines.js +26 -0
- package/ZegoExpressEngine.js +38 -16
- package/ZegoExpressEngineImpl.js +4 -0
- package/ZegoExpressErrorCode.js +1 -1
- package/ZegoExpressScreenCaptureSource.js +1 -0
- package/mac/ZegoExpressNodeNative.node +0 -0
- package/mac/ZegoExpressNodeNative.node.dSYM/Contents/Resources/DWARF/ZegoExpressNodeNative.node +0 -0
- package/mac/libZegoExpressEngine.dylib +0 -0
- package/package.json +1 -1
- package/win/x64/ZegoExpressEngine.dll +0 -0
- package/win/x64/ZegoExpressNodeNative.node +0 -0
- package/win/x64/ZegoExpressNodeNative.pdb +0 -0
- package/win/x86/ZegoExpressEngine.dll +0 -0
- package/win/x86/ZegoExpressNodeNative.node +0 -0
- package/win/x86/ZegoExpressNodeNative.pdb +0 -0
|
@@ -77,11 +77,11 @@ class ZegoCopyrightedMusic extends EventEmitter {
|
|
|
77
77
|
* Get lyrics in krc format.
|
|
78
78
|
*
|
|
79
79
|
* Available since: 2.13.0
|
|
80
|
-
* Description: Get lyrics
|
|
80
|
+
* Description: Get verbatim lyrics, support parsing lyrics word by word.
|
|
81
81
|
* Use case: Used to display lyrics word by word.
|
|
82
82
|
* When to call: After initializing the copyrighted music success [initCopyrightedMusic].
|
|
83
83
|
* @param {string} krcToken - The krcToken obtained by calling requestAccompaniment.
|
|
84
|
-
* @return {Promise<Object>} - Get
|
|
84
|
+
* @return {Promise<Object>} - Get verbatim lyrics complete callback.
|
|
85
85
|
*/
|
|
86
86
|
getKrcLyricByToken(krcToken) {
|
|
87
87
|
return this.nativeCopyrightedMusic.getKrcLyricByToken({ krcToken })
|
|
@@ -189,7 +189,7 @@ class ZegoCopyrightedMusic extends EventEmitter {
|
|
|
189
189
|
* Available since: 2.15.0
|
|
190
190
|
* Description: Start the scoring function.After starting scoring, the scoring result OnCurrentPitchValueUpdate callback will be received according to the set callback time interval.
|
|
191
191
|
* Use case: Can be used to display the singing score on the view.
|
|
192
|
-
* When to call: After obtaining
|
|
192
|
+
* When to call: After obtaining verbatim lyrics and playing the accompaniment resources of copyrighted music.
|
|
193
193
|
* Restrictions: Only support use this api after [startPublishingStream].
|
|
194
194
|
* @param {string} resourceID - the resource ID corresponding to the accompaniment or accompaniment clip.
|
|
195
195
|
* @param {number} pitchValueInterval - the time interval of real-time pitch line callback, in milliseconds, the default is 50 milliseconds.
|
package/ZegoExpressDefines.js
CHANGED
|
@@ -986,6 +986,25 @@ const ZegoStreamResourceMode = {
|
|
|
986
986
|
CDNPlus: 4,
|
|
987
987
|
}
|
|
988
988
|
|
|
989
|
+
/**
|
|
990
|
+
* Stream Switch Resource Mode
|
|
991
|
+
* @enum {number}
|
|
992
|
+
*/
|
|
993
|
+
const ZegoStreamResourceSwitchMode = {
|
|
994
|
+
/**
|
|
995
|
+
* @description Default mode. The SDK will automatically select the streaming resource according to the parameters set by the player config and the ready-made background configuration.
|
|
996
|
+
*/
|
|
997
|
+
Default: 0,
|
|
998
|
+
/**
|
|
999
|
+
* @description Auto switch to RTC resource when publishing.
|
|
1000
|
+
*/
|
|
1001
|
+
SwitchToRTC: 1,
|
|
1002
|
+
/**
|
|
1003
|
+
* @description Keep using original resource when publishing, not switch to RTC resource.
|
|
1004
|
+
*/
|
|
1005
|
+
KeepOriginal: 2,
|
|
1006
|
+
}
|
|
1007
|
+
|
|
989
1008
|
/**
|
|
990
1009
|
* Update type.
|
|
991
1010
|
* @enum {number}
|
|
@@ -1380,6 +1399,10 @@ const ZegoVideoBufferType = {
|
|
|
1380
1399
|
* @description GL_TEXTURE_EXTERNAL_OES type video frame
|
|
1381
1400
|
*/
|
|
1382
1401
|
GLTextureExternalOES: 6,
|
|
1402
|
+
/**
|
|
1403
|
+
* @description Texture 2D and raw data type video frame
|
|
1404
|
+
*/
|
|
1405
|
+
GLTexture2DAndRawData: 7,
|
|
1383
1406
|
}
|
|
1384
1407
|
|
|
1385
1408
|
/**
|
|
@@ -2200,6 +2223,7 @@ const ZegoScreenCaptureSourceExceptionType = {
|
|
|
2200
2223
|
* @property {ZegoVideoCodecID} videoCodecID - The video encoding type of the stream, please contact ZEGO technical support if you need to use it, otherwise this parameter can be ignored.
|
|
2201
2224
|
* @property {ZegoResourceType} sourceResourceType - The resource type of the source stream, please contact ZEGO technical support if you need to use it, otherwise this parameter can be ignored.
|
|
2202
2225
|
* @property {number} codecTemplateID - Preconfigured codec template ID, please contact ZEGO technical support if you need to use it, otherwise this parameter can be ignored.
|
|
2226
|
+
* @property {ZegoStreamResourceSwitchMode} resourceSwitchMode - Play resource switching strategy mode, the default is ZegoStreamResourceSwitchModeDefault
|
|
2203
2227
|
*/
|
|
2204
2228
|
|
|
2205
2229
|
/**
|
|
@@ -2300,6 +2324,7 @@ const ZegoScreenCaptureSourceExceptionType = {
|
|
|
2300
2324
|
/**
|
|
2301
2325
|
* @typedef {Object} ZegoMixerImageInfo - Set the image information of a single input stream in the mux.
|
|
2302
2326
|
* @property {string} url - The image path, if not empty, the image will be displayed, otherwise, the video will be displayed. JPG and PNG formats are supported. There are 2 ways to use it: 1. URI: Provide the picture to ZEGO technical support for configuration. After the configuration is complete, the picture URI will be provided, for example: preset-id://xxx.jpg. 2. URL: Only HTTP protocol is supported.
|
|
2327
|
+
* @property {number} displayMode - Image display mode. 0: Default. Use image to replace video content when url is not null. 1: Display image based on camera status. Display image when camera is turned off. Display video content when camera is turned on (no need to clear the url parameter). 2: Display image based on the input stream is empty or not. Display image when the input stream is empty for 3 consecutive seconds. The default duration for determine a input stream is empty or not is 3 seconds. If you need change this setting, please contact ZEGO technical support. Display video content when the input stream has video data.
|
|
2303
2328
|
*/
|
|
2304
2329
|
|
|
2305
2330
|
/**
|
|
@@ -2526,6 +2551,7 @@ module.exports = {
|
|
|
2526
2551
|
ZegoPlayerMediaEvent,
|
|
2527
2552
|
ZegoResourceType,
|
|
2528
2553
|
ZegoStreamResourceMode,
|
|
2554
|
+
ZegoStreamResourceSwitchMode,
|
|
2529
2555
|
ZegoUpdateType,
|
|
2530
2556
|
ZegoStreamRelayCDNState,
|
|
2531
2557
|
ZegoStreamRelayCDNUpdateReason,
|
package/ZegoExpressEngine.js
CHANGED
|
@@ -17,7 +17,7 @@ class ZegoExpressEngine extends EventEmitter {
|
|
|
17
17
|
* Description: Create ZegoExpressEngine singleton object and initialize SDK.
|
|
18
18
|
* When to call: The engine needs to be created before calling other functions.
|
|
19
19
|
* Restrictions: None.
|
|
20
|
-
* Caution: The SDK only supports the creation of one instance of ZegoExpressEngine.
|
|
20
|
+
* Caution: The SDK only supports the creation of one instance of ZegoExpressEngine. If you need call [createEngine] multiple times, you need call [destroyEngine] before you call the next [createEngine]. Otherwise it will return the instance which created by [createEngine] you called last time.
|
|
21
21
|
* @param {ZegoEngineProfile} profile - The basic configuration information is used to create the engine.
|
|
22
22
|
* @return {Promise<Object>} - The result notification callback of create engine.
|
|
23
23
|
*/
|
|
@@ -149,9 +149,9 @@ class ZegoExpressEngine extends EventEmitter {
|
|
|
149
149
|
* Available since: 1.1.0
|
|
150
150
|
* Description: By default, SDK creates and prints log files in the App's default directory. Each log file defaults to a maximum of 5MB. Three log files are written over and over in a circular fashion. When calling this function, SDK will auto package and upload the log files to the ZEGO server.
|
|
151
151
|
* Use cases: Developers can provide a business “feedback” channel in the App. When users feedback problems, they can call this function to upload the local log information of SDK to help locate user problems.
|
|
152
|
-
* When to call: After [
|
|
153
|
-
* Restrictions:
|
|
154
|
-
* Caution: After calling this interface to upload logs, if you call [destroyEngine] or exit the App too quickly, there may be a failure.It is recommended to wait a few seconds, and then call [destroyEngine] or exit the App after receiving the upload success callback.
|
|
152
|
+
* When to call: After [createEngine].
|
|
153
|
+
* Restrictions: The frequency limit is once per minute.
|
|
154
|
+
* Caution: 1.After calling this interface to upload logs, if you call [destroyEngine] or exit the App too quickly, there may be a failure.It is recommended to wait a few seconds, and then call [destroyEngine] or exit the App after receiving the upload success callback. 2.If you want to call before [createEngine], use the [submitLog] interface.
|
|
155
155
|
*/
|
|
156
156
|
uploadLog() {
|
|
157
157
|
ZegoExpressEngineImpl.uploadLog()
|
|
@@ -199,7 +199,6 @@ class ZegoExpressEngine extends EventEmitter {
|
|
|
199
199
|
* 2. SDK supports startPlayingStream audio and video streams from different rooms under the same appID, that is, startPlayingStream audio and video streams across rooms. Since ZegoExpressEngine's room related callback notifications are based on the same room, when developers want to startPlayingStream streams across rooms, developers need to maintain related messages and signaling notifications by themselves.
|
|
200
200
|
* 3. It is strongly recommended that userID corresponds to the user ID of the business APP, that is, a userID and a real user are fixed and unique, and should not be passed to the SDK in a random userID. Because the unique and fixed userID allows ZEGO technicians to quickly locate online problems.
|
|
201
201
|
* 4. After the first login failure due to network reasons or the room is disconnected, the default time of SDK reconnection is 20min.
|
|
202
|
-
* 5. After the user has successfully logged in to the room, if the application exits abnormally, after restarting the application, the developer needs to call the logoutRoom interface to log out of the room, and then call the loginRoom interface to log in to the room again.
|
|
203
202
|
* Privacy reminder: Please do not fill in sensitive user information in this interface, including but not limited to mobile phone number, ID number, passport number, real name, etc.
|
|
204
203
|
* Related callbacks:
|
|
205
204
|
* 1. When the user starts to log in to the room, the room is successfully logged in, or the room fails to log in, the [onRoomStateChanged] (Not supported before 2.18.0, please use [onRoomStateUpdate]) callback will be triggered to notify the developer of the status of the current user connected to the room.
|
|
@@ -453,6 +452,22 @@ class ZegoExpressEngine extends EventEmitter {
|
|
|
453
452
|
ZegoExpressEngineImpl.setAudioConfig(config)
|
|
454
453
|
}
|
|
455
454
|
|
|
455
|
+
/**
|
|
456
|
+
* Sets up the audio configurations for the specified publish channel.
|
|
457
|
+
*
|
|
458
|
+
* Available since: 1.3.4
|
|
459
|
+
* Description: You can set the combined value of the audio codec, bit rate, and audio channel through this function. If the preset value cannot meet the developer's scenario, the developer can set the parameters according to the business requirements.
|
|
460
|
+
* Default value: The default audio config refers to the default value of [ZegoAudioConfig].
|
|
461
|
+
* When to call: After the engine is created [createEngine], and before publishing [startPublishingStream].
|
|
462
|
+
* Restrictions: None.
|
|
463
|
+
* Related APIs: [getAudioConfig].
|
|
464
|
+
* @param {(ZegoAudioConfigPreset|ZegoAudioConfig)} config - Audio config.
|
|
465
|
+
* @param {ZegoPublishChannel} channel - Publish stream channel.
|
|
466
|
+
*/
|
|
467
|
+
setAudioConfigWithChannel(config, channel = ZegoPublishChannel.Main) {
|
|
468
|
+
ZegoExpressEngineImpl.setAudioConfigWithChannel(config, channel)
|
|
469
|
+
}
|
|
470
|
+
|
|
456
471
|
/**
|
|
457
472
|
* Gets the current audio configurations.
|
|
458
473
|
*
|
|
@@ -1291,7 +1306,7 @@ class ZegoExpressEngine extends EventEmitter {
|
|
|
1291
1306
|
/**
|
|
1292
1307
|
* Chooses to use the specified audio device.
|
|
1293
1308
|
*
|
|
1294
|
-
* Available since: 1.
|
|
1309
|
+
* Available since: 1.1.0
|
|
1295
1310
|
* Description: Chooses to use the specified audio device.
|
|
1296
1311
|
* When to call: After creating the engine [createEngine] and before call [startPublishingStream] or [startPlayingStream].
|
|
1297
1312
|
* Restrictions: Only supports Windows / macOS / Linux
|
|
@@ -1361,7 +1376,12 @@ class ZegoExpressEngine extends EventEmitter {
|
|
|
1361
1376
|
/**
|
|
1362
1377
|
* Turn on audio device volume monitoring.
|
|
1363
1378
|
*
|
|
1364
|
-
*
|
|
1379
|
+
* Available since: 1.1.0
|
|
1380
|
+
* Description: Starts the audio device volume monitor. When the volume of the device changes, the changed volume will be called back via [onAudioDeviceVolumeChanged].
|
|
1381
|
+
* Caution: Currently, only one audio output device and one audio input device are supported to be monitored at the same time. When this API is called multiple times and the same device type is set, the device ID set to this API during the last call will be overwritten.
|
|
1382
|
+
* When to call: After creating the engine via [createEngine].
|
|
1383
|
+
* Platform differences: Only supports Windows and macOS.
|
|
1384
|
+
* Related APIs: When you no longer need to monitor the device volume, please call [stopAudioDeviceVolumeMonitor] to stop monitoring.
|
|
1365
1385
|
* @param {ZegoAudioDeviceType} deviceType - Audio device type
|
|
1366
1386
|
* @param {string} deviceID - ID of a device obtained by [getAudioDeviceList]
|
|
1367
1387
|
*/
|
|
@@ -1372,7 +1392,10 @@ class ZegoExpressEngine extends EventEmitter {
|
|
|
1372
1392
|
/**
|
|
1373
1393
|
* Turn off audio device volume monitoring. Only for Windows/macOS.
|
|
1374
1394
|
*
|
|
1375
|
-
*
|
|
1395
|
+
* Available since: 1.1.0
|
|
1396
|
+
* Description: Stops the audio device volume monitor.
|
|
1397
|
+
* When to call: After creating the engine via [createEngine], and when you no longer need to monitor the device volume.
|
|
1398
|
+
* Platform differences: Only supports Windows and macOS.
|
|
1376
1399
|
* @param {ZegoAudioDeviceType} deviceType - Audio device type
|
|
1377
1400
|
* @param {string} deviceID - ID of a device obtained by [getAudioDeviceList]
|
|
1378
1401
|
*/
|
|
@@ -1591,7 +1614,7 @@ class ZegoExpressEngine extends EventEmitter {
|
|
|
1591
1614
|
/**
|
|
1592
1615
|
* Enable or disable mix SDK playout to stream publishing.
|
|
1593
1616
|
*
|
|
1594
|
-
* Available since: 1.
|
|
1617
|
+
* Available since: 1.1.0
|
|
1595
1618
|
* Description: Enable mix SDK playout sounds into the stream publishing.
|
|
1596
1619
|
* Use cases: Users need to mix the sound of SDK playout into stream publishing. For example, when the class scene, the teacher and student Co-hosting, and the teacher can mix the play streaming sound into the publish streaming.
|
|
1597
1620
|
* Default value: Default is disable.
|
|
@@ -1623,7 +1646,7 @@ class ZegoExpressEngine extends EventEmitter {
|
|
|
1623
1646
|
/**
|
|
1624
1647
|
* Stop audio VAD stable state monitoring.
|
|
1625
1648
|
*
|
|
1626
|
-
* Available
|
|
1649
|
+
* Available since: 2.14.0
|
|
1627
1650
|
* Description: After calling this interface, the specified type of [onAudioVADStateUpdate] callback can no longer be received.
|
|
1628
1651
|
* When to call: None.
|
|
1629
1652
|
* Restrictions: None.
|
|
@@ -2014,7 +2037,7 @@ class ZegoExpressEngine extends EventEmitter {
|
|
|
2014
2037
|
* Available since: 1.20.0
|
|
2015
2038
|
* Description: This function supports uplink/downlink network speed test when the network can be connected.
|
|
2016
2039
|
* Use cases: This function can be used to detect whether the network environment is suitable for pushing/pulling streams with specified bitrates.
|
|
2017
|
-
* When to call: It needs to be called after [
|
|
2040
|
+
* When to call: It needs to be called after [createEngine], and before [startPublishingStream]. If you call [startPublishingStream] while speed testing, the speed test will automatically stop.
|
|
2018
2041
|
* Restrictions: The default maximum allowable test time for a single network speed test is 30 seconds.
|
|
2019
2042
|
* Caution: Developers can register [onNetworkSpeedTestQualityUpdate] callback to get the speed test result, which will be triggered every 3 seconds. If an error occurs during the speed test process, [onNetworkSpeedTestError] callback will be triggered. If this function is repeatedly called multiple times, the last functioh call's configuration will be used.
|
|
2020
2043
|
* Related APIs: Call [stopNetworkSpeedTest] to stop network speed test.
|
|
@@ -2759,10 +2782,9 @@ class ZegoExpressEngine extends EventEmitter {
|
|
|
2759
2782
|
* @event ZegoExpressEngine#onAudioDeviceVolumeChanged
|
|
2760
2783
|
* @desc The callback triggered when there is a change of the volume for the audio devices.
|
|
2761
2784
|
*
|
|
2762
|
-
* Available since: 1.
|
|
2763
|
-
* Description:
|
|
2764
|
-
* When to trigger:
|
|
2765
|
-
* Restrictions: None
|
|
2785
|
+
* Available since: 1.1.0
|
|
2786
|
+
* Description: Audio device volume change event callback.
|
|
2787
|
+
* When to trigger: After calling the [startAudioDeviceVolumeMonitor] function to start the device volume monitor, and the volume of the monitored audio device changes.
|
|
2766
2788
|
* Platform differences: Only supports Windows and macOS.
|
|
2767
2789
|
* @property {object} result - param object
|
|
2768
2790
|
* @property {ZegoAudioDeviceType} result.deviceType - Audio device type
|
|
@@ -2774,7 +2796,7 @@ class ZegoExpressEngine extends EventEmitter {
|
|
|
2774
2796
|
* @event ZegoExpressEngine#onVideoDeviceStateChanged
|
|
2775
2797
|
* @desc The callback triggered when there is a change to video devices (i.e. new device added or existing device deleted).
|
|
2776
2798
|
*
|
|
2777
|
-
* Available since: 1.
|
|
2799
|
+
* Available since: 1.1.0
|
|
2778
2800
|
* Description: By listening to this callback, users can update the video capture using a specific device when necessary.
|
|
2779
2801
|
* When to trigger: This callback is triggered when a video device is added or removed from the system.
|
|
2780
2802
|
* Restrictions: None
|
package/ZegoExpressEngineImpl.js
CHANGED
|
@@ -263,6 +263,10 @@ class ZegoExpressEngineImpl extends EventEmitter {
|
|
|
263
263
|
this.ZegoNativeInstance.setAudioConfig({ config })
|
|
264
264
|
}
|
|
265
265
|
|
|
266
|
+
setAudioConfigWithChannel(config, channel) {
|
|
267
|
+
this.ZegoNativeInstance.setAudioConfig({ config, channel })
|
|
268
|
+
}
|
|
269
|
+
|
|
266
270
|
getAudioConfig() {
|
|
267
271
|
return this.ZegoNativeInstance.getAudioConfig({})
|
|
268
272
|
}
|
package/ZegoExpressErrorCode.js
CHANGED
|
@@ -857,7 +857,7 @@ const ZegoErrorCode = {
|
|
|
857
857
|
/** Description: RTP timeout. <br>Cause: Not connected to the network. <br> Solutions: Please check if you can access the Internet properly. */
|
|
858
858
|
UtilitiesNetworkToolRtpTimeoutError: 1015003,
|
|
859
859
|
|
|
860
|
-
/** Description: The server side ends the network speed test. <br>Cause: Network speed test time is too long. <br> Solutions: Please stop network speed test in
|
|
860
|
+
/** Description: The server side ends the network speed test. <br>Cause: Network speed test time is too long. <br> Solutions: Please stop network speed test in 30 seconds. */
|
|
861
861
|
UtilitiesNetworkToolEngineDenied: 1015004,
|
|
862
862
|
|
|
863
863
|
/** Description: Network speed test stopped. <br>Cause: Network speed test not stopped before publishing stream. <br> Solutions: Please stop network speed test(stopNetworkSpeedTest) before publishing stream. */
|
|
@@ -109,6 +109,7 @@ class ZegoScreenCaptureSource extends EventEmitter {
|
|
|
109
109
|
* Description: The callback triggered when a screen capture source exception occurred.
|
|
110
110
|
* Trigger: This callback is triggered when an exception occurs after the screen start capture.
|
|
111
111
|
* Caution: The callback does not actually take effect until call [setEventHandler] to set.
|
|
112
|
+
* Restrictions: Only available on Windows/macOS.
|
|
112
113
|
* @property {object} result - param object
|
|
113
114
|
* @property {ZegoScreenCaptureSourceExceptionType} result.exceptionType - Capture source exception type.
|
|
114
115
|
*/
|
|
Binary file
|
package/mac/ZegoExpressNodeNative.node.dSYM/Contents/Resources/DWARF/ZegoExpressNodeNative.node
CHANGED
|
Binary file
|
|
Binary file
|
package/package.json
CHANGED
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|