agora-electron-sdk 4.5.0-dev.1 → 4.5.0-dev.2
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/CHANGELOG.md +8 -1
- package/js/Private/AgoraBase.js +16 -16
- package/js/Private/AgoraMediaBase.js +17 -17
- package/js/Private/IAgoraRtcEngine.js +1 -1
- package/package.json +5 -5
- package/scripts/downloadPrebuild.js +17 -0
- package/scripts/publishCN/common.sh +19 -0
- package/scripts/publishCN/rewrite-dep.sh +22 -0
- package/scripts/publishCN/rewrite-example.sh +22 -0
- package/scripts/zipBuild.js +25 -0
- package/ts/Private/AgoraBase.ts +38 -27
- package/ts/Private/AgoraMediaBase.ts +23 -21
- package/ts/Private/AgoraMediaPlayerTypes.ts +1 -1
- package/ts/Private/IAgoraMediaPlayer.ts +8 -7
- package/ts/Private/IAgoraMediaPlayerSource.ts +1 -1
- package/ts/Private/IAgoraRtcEngine.ts +90 -38
- package/ts/Private/IAgoraRtcEngineEx.ts +11 -1
- package/ts/Private/IAudioDeviceManager.ts +11 -2
- package/types/Private/AgoraBase.d.ts +38 -27
- package/types/Private/AgoraBase.d.ts.map +1 -1
- package/types/Private/AgoraMediaBase.d.ts +23 -21
- package/types/Private/AgoraMediaBase.d.ts.map +1 -1
- package/types/Private/AgoraMediaPlayerTypes.d.ts +1 -1
- package/types/Private/IAgoraMediaPlayer.d.ts +8 -7
- package/types/Private/IAgoraMediaPlayer.d.ts.map +1 -1
- package/types/Private/IAgoraMediaPlayerSource.d.ts +1 -1
- package/types/Private/IAgoraRtcEngine.d.ts +90 -38
- package/types/Private/IAgoraRtcEngine.d.ts.map +1 -1
- package/types/Private/IAgoraRtcEngineEx.d.ts +11 -1
- package/types/Private/IAgoraRtcEngineEx.d.ts.map +1 -1
- package/types/Private/IAudioDeviceManager.d.ts +11 -2
- package/types/Private/IAudioDeviceManager.d.ts.map +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
|
|
2
2
|
|
|
3
|
-
# [4.5.0-dev.
|
|
3
|
+
# [4.5.0-dev.2](https://github.com/AgoraIO-Extensions/Electron-SDK/compare/v4.5.0...v4.5.0-dev.2) (2024-12-19)
|
|
4
|
+
|
|
5
|
+
# [4.5.0](https://github.com/AgoraIO-Extensions/Electron-SDK/compare/v4.4.0...v4.5.0) (2024-12-10)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Features
|
|
9
|
+
|
|
10
|
+
* support 4.5.0 ([#1228](https://github.com/AgoraIO-Extensions/Electron-SDK/issues/1228)) ([d1a6d9c](https://github.com/AgoraIO-Extensions/Electron-SDK/commit/d1a6d9cc2aa361e7b96ad158debe791f4accc6a7)), closes [#1224](https://github.com/AgoraIO-Extensions/Electron-SDK/issues/1224)
|
|
4
11
|
|
|
5
12
|
# [4.4.0](https://github.com/AgoraIO-Extensions/Electron-SDK/compare/v4.3.2...v4.4.0) (2024-08-29)
|
|
6
13
|
|
package/js/Private/AgoraBase.js
CHANGED
|
@@ -772,11 +772,11 @@ var OrientationMode;
|
|
|
772
772
|
var DegradationPreference;
|
|
773
773
|
(function (DegradationPreference) {
|
|
774
774
|
/**
|
|
775
|
-
*
|
|
775
|
+
* 0: (Default) Automatic mode. The SDK will automatically select MaintainFramerate, MaintainBalanced or MaintainResolution based on the video scenario you set, in order to achieve the best overall quality of experience (QoE).
|
|
776
776
|
*/
|
|
777
777
|
DegradationPreference[DegradationPreference["MaintainAuto"] = -1] = "MaintainAuto";
|
|
778
778
|
/**
|
|
779
|
-
* 0:
|
|
779
|
+
* 0: Prefers to reduce the video frame rate while maintaining video resolution during video encoding under limited bandwidth. This degradation preference is suitable for scenarios where video quality is prioritized. Deprecated: This enumerator is deprecated. Use other enumerations instead.
|
|
780
780
|
*/
|
|
781
781
|
DegradationPreference[DegradationPreference["MaintainQuality"] = 0] = "MaintainQuality";
|
|
782
782
|
/**
|
|
@@ -1138,7 +1138,7 @@ exports.EncodedVideoFrameInfo = EncodedVideoFrameInfo;
|
|
|
1138
1138
|
var CompressionPreference;
|
|
1139
1139
|
(function (CompressionPreference) {
|
|
1140
1140
|
/**
|
|
1141
|
-
*
|
|
1141
|
+
* -1: (Default) Automatic mode. The SDK will automatically select PreferLowLatency or PreferQuality based on the video scenario you set to achieve the best user experience.
|
|
1142
1142
|
*/
|
|
1143
1143
|
CompressionPreference[CompressionPreference["PreferCompressionAuto"] = -1] = "PreferCompressionAuto";
|
|
1144
1144
|
/**
|
|
@@ -1146,7 +1146,7 @@ var CompressionPreference;
|
|
|
1146
1146
|
*/
|
|
1147
1147
|
CompressionPreference[CompressionPreference["PreferLowLatency"] = 0] = "PreferLowLatency";
|
|
1148
1148
|
/**
|
|
1149
|
-
* 1:
|
|
1149
|
+
* 1: High quality preference. The SDK compresses video frames while maintaining video quality. This preference is suitable for scenarios where video quality is prioritized.
|
|
1150
1150
|
*/
|
|
1151
1151
|
CompressionPreference[CompressionPreference["PreferQuality"] = 1] = "PreferQuality";
|
|
1152
1152
|
})(CompressionPreference = exports.CompressionPreference || (exports.CompressionPreference = {}));
|
|
@@ -1670,11 +1670,11 @@ var VideoApplicationScenarioType;
|
|
|
1670
1670
|
*/
|
|
1671
1671
|
VideoApplicationScenarioType[VideoApplicationScenarioType["ApplicationScenarioMeeting"] = 1] = "ApplicationScenarioMeeting";
|
|
1672
1672
|
/**
|
|
1673
|
-
* ApplicationScenario1v1 (2) is
|
|
1673
|
+
* ApplicationScenario1v1 (2) This is applicable to the scenario. To meet the requirements for low latency and high-quality video in this scenario, the SDK optimizes its strategies, improving performance in terms of video quality, first frame rendering, latency on mid-to-low-end devices, and smoothness under weak network conditions. 2: 1v1 video call scenario.
|
|
1674
1674
|
*/
|
|
1675
1675
|
VideoApplicationScenarioType[VideoApplicationScenarioType["ApplicationScenario1v1"] = 2] = "ApplicationScenario1v1";
|
|
1676
1676
|
/**
|
|
1677
|
-
*
|
|
1677
|
+
* ApplicationScenarioLiveshow (3) This is applicable to the scenario. In this scenario, fast video rendering and high image quality are crucial. The SDK implements several performance optimizations, including automatically enabling accelerated audio and video frame rendering to minimize first-frame latency (no need to call enableInstantMediaRendering), and B-frame encoding to achieve better image quality and bandwidth efficiency. The SDK also provides enhanced video quality and smooth playback, even in poor network conditions or on lower-end devices. 3. Live show scenario.
|
|
1678
1678
|
*/
|
|
1679
1679
|
VideoApplicationScenarioType[VideoApplicationScenarioType["ApplicationScenarioLiveshow"] = 3] = "ApplicationScenarioLiveshow";
|
|
1680
1680
|
})(VideoApplicationScenarioType = exports.VideoApplicationScenarioType || (exports.VideoApplicationScenarioType = {}));
|
|
@@ -1888,11 +1888,11 @@ var LocalVideoStreamReason;
|
|
|
1888
1888
|
*/
|
|
1889
1889
|
LocalVideoStreamReason[LocalVideoStreamReason["LocalVideoStreamReasonDeviceNotFound"] = 8] = "LocalVideoStreamReasonDeviceNotFound";
|
|
1890
1890
|
/**
|
|
1891
|
-
* 9:
|
|
1891
|
+
* 9: The video capture device currently in use is disconnected (such as being unplugged).
|
|
1892
1892
|
*/
|
|
1893
1893
|
LocalVideoStreamReason[LocalVideoStreamReason["LocalVideoStreamReasonDeviceDisconnected"] = 9] = "LocalVideoStreamReasonDeviceDisconnected";
|
|
1894
1894
|
/**
|
|
1895
|
-
* 10:
|
|
1895
|
+
* 10: The SDK cannot find the video device in the video device list. Check whether the ID of the video device is valid.
|
|
1896
1896
|
*/
|
|
1897
1897
|
LocalVideoStreamReason[LocalVideoStreamReason["LocalVideoStreamReasonDeviceInvalidId"] = 10] = "LocalVideoStreamReasonDeviceInvalidId";
|
|
1898
1898
|
/**
|
|
@@ -1908,11 +1908,11 @@ var LocalVideoStreamReason;
|
|
|
1908
1908
|
*/
|
|
1909
1909
|
LocalVideoStreamReason[LocalVideoStreamReason["LocalVideoStreamReasonDeviceSystemPressure"] = 101] = "LocalVideoStreamReasonDeviceSystemPressure";
|
|
1910
1910
|
/**
|
|
1911
|
-
* 11:
|
|
1911
|
+
* 11: The shared window is minimized when you call the startScreenCaptureByWindowId method to share a window. The SDK cannot share a minimized window. Please prompt the user to unminimize the shared window.
|
|
1912
1912
|
*/
|
|
1913
1913
|
LocalVideoStreamReason[LocalVideoStreamReason["LocalVideoStreamReasonScreenCaptureWindowMinimized"] = 11] = "LocalVideoStreamReasonScreenCaptureWindowMinimized";
|
|
1914
1914
|
/**
|
|
1915
|
-
* 12:
|
|
1915
|
+
* 12: The error code indicates that a window shared by the window ID has been closed or a full-screen window shared by the window ID has exited full-screen mode. After exiting full-screen mode, remote users cannot see the shared window. To prevent remote users from seeing a black screen, Agora recommends that you immediately stop screen sharing. Common scenarios reporting this error code:
|
|
1916
1916
|
* The local user closes the shared window.
|
|
1917
1917
|
* The local user shows some slides in full-screen mode first, and then shares the windows of the slides. After the user exits full-screen mode, the SDK reports this error code.
|
|
1918
1918
|
* The local user watches a web video or reads a web document in full-screen mode first, and then shares the window of the web video or document. After the user exits full-screen mode, the SDK reports this error code.
|
|
@@ -1927,7 +1927,7 @@ var LocalVideoStreamReason;
|
|
|
1927
1927
|
*/
|
|
1928
1928
|
LocalVideoStreamReason[LocalVideoStreamReason["LocalVideoStreamReasonScreenCaptureWindowNotSupported"] = 20] = "LocalVideoStreamReasonScreenCaptureWindowNotSupported";
|
|
1929
1929
|
/**
|
|
1930
|
-
* 21: (Windows only) The
|
|
1930
|
+
* 21: (Windows and Android only) The currently captured window has no data.
|
|
1931
1931
|
*/
|
|
1932
1932
|
LocalVideoStreamReason[LocalVideoStreamReason["LocalVideoStreamReasonScreenCaptureFailure"] = 21] = "LocalVideoStreamReasonScreenCaptureFailure";
|
|
1933
1933
|
/**
|
|
@@ -2502,13 +2502,13 @@ var VideoTranscoderError;
|
|
|
2502
2502
|
VideoTranscoderError[VideoTranscoderError["VtErrInternal"] = 20] = "VtErrInternal";
|
|
2503
2503
|
})(VideoTranscoderError = exports.VideoTranscoderError || (exports.VideoTranscoderError = {}));
|
|
2504
2504
|
/**
|
|
2505
|
-
*
|
|
2505
|
+
* The source of the audio streams that are mixed locally.
|
|
2506
2506
|
*/
|
|
2507
2507
|
class MixedAudioStream {
|
|
2508
2508
|
}
|
|
2509
2509
|
exports.MixedAudioStream = MixedAudioStream;
|
|
2510
2510
|
/**
|
|
2511
|
-
*
|
|
2511
|
+
* The configurations for mixing the lcoal audio.
|
|
2512
2512
|
*/
|
|
2513
2513
|
class LocalAudioMixerConfiguration {
|
|
2514
2514
|
}
|
|
@@ -2902,7 +2902,7 @@ class FaceShapeBeautyOptions {
|
|
|
2902
2902
|
}
|
|
2903
2903
|
exports.FaceShapeBeautyOptions = FaceShapeBeautyOptions;
|
|
2904
2904
|
/**
|
|
2905
|
-
*
|
|
2905
|
+
* Filter effect options.
|
|
2906
2906
|
*/
|
|
2907
2907
|
class FilterEffectOptions {
|
|
2908
2908
|
}
|
|
@@ -2956,7 +2956,7 @@ var VideoDenoiserMode;
|
|
|
2956
2956
|
VideoDenoiserMode[VideoDenoiserMode["VideoDenoiserManual"] = 1] = "VideoDenoiserManual";
|
|
2957
2957
|
})(VideoDenoiserMode = exports.VideoDenoiserMode || (exports.VideoDenoiserMode = {}));
|
|
2958
2958
|
/**
|
|
2959
|
-
*
|
|
2959
|
+
* Video noise reduction level.
|
|
2960
2960
|
*/
|
|
2961
2961
|
var VideoDenoiserLevel;
|
|
2962
2962
|
(function (VideoDenoiserLevel) {
|
|
@@ -2965,7 +2965,7 @@ var VideoDenoiserLevel;
|
|
|
2965
2965
|
*/
|
|
2966
2966
|
VideoDenoiserLevel[VideoDenoiserLevel["VideoDenoiserLevelHighQuality"] = 0] = "VideoDenoiserLevelHighQuality";
|
|
2967
2967
|
/**
|
|
2968
|
-
* 1: Promotes reducing performance consumption during video noise reduction. prioritizes reducing performance consumption over video noise reduction quality. The performance consumption is lower, and the video noise reduction speed is faster. To avoid a noticeable shadowing effect (shadows trailing behind moving objects) in the processed video, Agora recommends that you use this
|
|
2968
|
+
* 1: Promotes reducing performance consumption during video noise reduction. It prioritizes reducing performance consumption over video noise reduction quality. The performance consumption is lower, and the video noise reduction speed is faster. To avoid a noticeable shadowing effect (shadows trailing behind moving objects) in the processed video, Agora recommends that you use this setting when the camera is fixed.
|
|
2969
2969
|
*/
|
|
2970
2970
|
VideoDenoiserLevel[VideoDenoiserLevel["VideoDenoiserLevelFast"] = 1] = "VideoDenoiserLevelFast";
|
|
2971
2971
|
})(VideoDenoiserLevel = exports.VideoDenoiserLevel || (exports.VideoDenoiserLevel = {}));
|
|
@@ -91,24 +91,24 @@ var VideoSourceType;
|
|
|
91
91
|
VideoSourceType[VideoSourceType["VideoSourceUnknown"] = 100] = "VideoSourceUnknown";
|
|
92
92
|
})(VideoSourceType = exports.VideoSourceType || (exports.VideoSourceType = {}));
|
|
93
93
|
/**
|
|
94
|
-
*
|
|
94
|
+
* The audio source type.
|
|
95
95
|
*/
|
|
96
96
|
var AudioSourceType;
|
|
97
97
|
(function (AudioSourceType) {
|
|
98
98
|
/**
|
|
99
|
-
*
|
|
99
|
+
* 0: (Default) Microphone.
|
|
100
100
|
*/
|
|
101
101
|
AudioSourceType[AudioSourceType["AudioSourceMicrophone"] = 0] = "AudioSourceMicrophone";
|
|
102
102
|
/**
|
|
103
|
-
*
|
|
103
|
+
* 1: Custom audio stream.
|
|
104
104
|
*/
|
|
105
105
|
AudioSourceType[AudioSourceType["AudioSourceCustom"] = 1] = "AudioSourceCustom";
|
|
106
106
|
/**
|
|
107
|
-
*
|
|
107
|
+
* 2: Media player.
|
|
108
108
|
*/
|
|
109
109
|
AudioSourceType[AudioSourceType["AudioSourceMediaPlayer"] = 2] = "AudioSourceMediaPlayer";
|
|
110
110
|
/**
|
|
111
|
-
*
|
|
111
|
+
* 3: System audio stream captured during screen sharing.
|
|
112
112
|
*/
|
|
113
113
|
AudioSourceType[AudioSourceType["AudioSourceLoopbackRecording"] = 3] = "AudioSourceLoopbackRecording";
|
|
114
114
|
/**
|
|
@@ -116,15 +116,15 @@ var AudioSourceType;
|
|
|
116
116
|
*/
|
|
117
117
|
AudioSourceType[AudioSourceType["AudioSourceMixedStream"] = 4] = "AudioSourceMixedStream";
|
|
118
118
|
/**
|
|
119
|
-
*
|
|
119
|
+
* 5: Audio stream from a specified remote user.
|
|
120
120
|
*/
|
|
121
121
|
AudioSourceType[AudioSourceType["AudioSourceRemoteUser"] = 5] = "AudioSourceRemoteUser";
|
|
122
122
|
/**
|
|
123
|
-
*
|
|
123
|
+
* 6: Mixed audio streams from all users in the current channel.
|
|
124
124
|
*/
|
|
125
125
|
AudioSourceType[AudioSourceType["AudioSourceRemoteChannel"] = 6] = "AudioSourceRemoteChannel";
|
|
126
126
|
/**
|
|
127
|
-
*
|
|
127
|
+
* 100: An unknown audio source.
|
|
128
128
|
*/
|
|
129
129
|
AudioSourceType[AudioSourceType["AudioSourceUnknown"] = 100] = "AudioSourceUnknown";
|
|
130
130
|
})(AudioSourceType = exports.AudioSourceType || (exports.AudioSourceType = {}));
|
|
@@ -442,11 +442,11 @@ var VideoPixelFormat;
|
|
|
442
442
|
var RenderModeType;
|
|
443
443
|
(function (RenderModeType) {
|
|
444
444
|
/**
|
|
445
|
-
* 1: Hidden mode.
|
|
445
|
+
* 1: Hidden mode. The priority is to fill the window. Any excess video that does not match the window size will be cropped.
|
|
446
446
|
*/
|
|
447
447
|
RenderModeType[RenderModeType["RenderModeHidden"] = 1] = "RenderModeHidden";
|
|
448
448
|
/**
|
|
449
|
-
* 2: Fit mode.
|
|
449
|
+
* 2: Fit mode. The priority is to ensure that all video content is displayed. Any areas of the window that are not filled due to the mismatch between video size and window size will be filled with black.
|
|
450
450
|
*/
|
|
451
451
|
RenderModeType[RenderModeType["RenderModeFit"] = 2] = "RenderModeFit";
|
|
452
452
|
/**
|
|
@@ -713,28 +713,28 @@ class Hdr10MetadataInfo {
|
|
|
713
713
|
}
|
|
714
714
|
exports.Hdr10MetadataInfo = Hdr10MetadataInfo;
|
|
715
715
|
/**
|
|
716
|
-
*
|
|
716
|
+
* The relative position of alphaBuffer and video frames.
|
|
717
717
|
*/
|
|
718
718
|
var AlphaStitchMode;
|
|
719
719
|
(function (AlphaStitchMode) {
|
|
720
720
|
/**
|
|
721
|
-
*
|
|
721
|
+
* 0: (Default) Only video frame, that is, alphaBuffer is not stitched with the video frame.
|
|
722
722
|
*/
|
|
723
723
|
AlphaStitchMode[AlphaStitchMode["NoAlphaStitch"] = 0] = "NoAlphaStitch";
|
|
724
724
|
/**
|
|
725
|
-
*
|
|
725
|
+
* 1: alphaBuffer is above the video frame.
|
|
726
726
|
*/
|
|
727
727
|
AlphaStitchMode[AlphaStitchMode["AlphaStitchUp"] = 1] = "AlphaStitchUp";
|
|
728
728
|
/**
|
|
729
|
-
*
|
|
729
|
+
* 2: alphaBuffer is below the video frame.
|
|
730
730
|
*/
|
|
731
731
|
AlphaStitchMode[AlphaStitchMode["AlphaStitchBelow"] = 2] = "AlphaStitchBelow";
|
|
732
732
|
/**
|
|
733
|
-
*
|
|
733
|
+
* 3: alphaBuffer is to the left of the video frame.
|
|
734
734
|
*/
|
|
735
735
|
AlphaStitchMode[AlphaStitchMode["AlphaStitchLeft"] = 3] = "AlphaStitchLeft";
|
|
736
736
|
/**
|
|
737
|
-
*
|
|
737
|
+
* 4: alphaBuffer is to the right of the video frame.
|
|
738
738
|
*/
|
|
739
739
|
AlphaStitchMode[AlphaStitchMode["AlphaStitchRight"] = 4] = "AlphaStitchRight";
|
|
740
740
|
})(AlphaStitchMode = exports.AlphaStitchMode || (exports.AlphaStitchMode = {}));
|
|
@@ -827,7 +827,7 @@ var VideoModulePosition;
|
|
|
827
827
|
VideoModulePosition[VideoModulePosition["PositionPostCapturerOrigin"] = 8] = "PositionPostCapturerOrigin";
|
|
828
828
|
})(VideoModulePosition = exports.VideoModulePosition || (exports.VideoModulePosition = {}));
|
|
829
829
|
/**
|
|
830
|
-
*
|
|
830
|
+
* The snapshot configuration.
|
|
831
831
|
*/
|
|
832
832
|
class SnapshotConfig {
|
|
833
833
|
}
|
|
@@ -660,7 +660,7 @@ var MediaDeviceStateType;
|
|
|
660
660
|
*/
|
|
661
661
|
MediaDeviceStateType[MediaDeviceStateType["MediaDeviceStateDisabled"] = 2] = "MediaDeviceStateDisabled";
|
|
662
662
|
/**
|
|
663
|
-
*
|
|
663
|
+
* 3: The device is plugged in.
|
|
664
664
|
*/
|
|
665
665
|
MediaDeviceStateType[MediaDeviceStateType["MediaDeviceStatePluggedIn"] = 3] = "MediaDeviceStatePluggedIn";
|
|
666
666
|
/**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "agora-electron-sdk",
|
|
3
|
-
"version": "4.5.0-dev.
|
|
3
|
+
"version": "4.5.0-dev.2",
|
|
4
4
|
"description": "agora-electron-sdk",
|
|
5
5
|
"main": "js/AgoraSdk",
|
|
6
6
|
"types": "types/AgoraSdk.d.ts",
|
|
@@ -142,9 +142,9 @@
|
|
|
142
142
|
"yuv-canvas": "1.2.6"
|
|
143
143
|
},
|
|
144
144
|
"agora_electron": {
|
|
145
|
-
"iris_sdk_win": "https://download.agora.io/sdk/release/iris_4.5.0-
|
|
146
|
-
"iris_sdk_mac": "https://download.agora.io/sdk/release/iris_4.5.0-
|
|
147
|
-
"native_sdk_win": "https://download.agora.io/sdk/release/
|
|
148
|
-
"native_sdk_mac": "https://download.agora.io/sdk/release/
|
|
145
|
+
"iris_sdk_win": "https://download.agora.io/sdk/release/iris_4.5.0-build.1_DCG_Windows_Video_Standalone_20241203_0322_577.zip",
|
|
146
|
+
"iris_sdk_mac": "https://download.agora.io/sdk/release/iris_4.5.0-build.1_DCG_Mac_Video_Standalone_20241203_0322_534.zip",
|
|
147
|
+
"native_sdk_win": "https://download.agora.io/sdk/release/Agora_Native_SDK_for_Windows_v4.5.0_FULL.zip",
|
|
148
|
+
"native_sdk_mac": "https://download.agora.io/sdk/release/Agora_Native_SDK_for_Mac_v4.5.0_FULL.zip"
|
|
149
149
|
}
|
|
150
150
|
}
|
|
@@ -29,6 +29,8 @@ const getDownloadURL = () => {
|
|
|
29
29
|
return downloadUrl;
|
|
30
30
|
};
|
|
31
31
|
|
|
32
|
+
// If native_stk_url is not defined in app/packaging.json,
|
|
33
|
+
// it will be read from agora-electron-sdk/packaging.json
|
|
32
34
|
const getNativeDownloadURL = () => {
|
|
33
35
|
let downloadUrl = '';
|
|
34
36
|
if (platform === 'win32') {
|
|
@@ -36,6 +38,21 @@ const getNativeDownloadURL = () => {
|
|
|
36
38
|
} else if (platform === 'darwin') {
|
|
37
39
|
downloadUrl = native_sdk_mac;
|
|
38
40
|
}
|
|
41
|
+
|
|
42
|
+
if (!downloadUrl) {
|
|
43
|
+
const {
|
|
44
|
+
agora_electron: {
|
|
45
|
+
native_sdk_win,
|
|
46
|
+
native_sdk_mac,
|
|
47
|
+
}
|
|
48
|
+
} = require("../package.json");
|
|
49
|
+
if (platform === 'win32') {
|
|
50
|
+
downloadUrl = native_sdk_win;
|
|
51
|
+
} else if (platform === 'darwin') {
|
|
52
|
+
downloadUrl = native_sdk_mac;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
|
|
39
56
|
return downloadUrl;
|
|
40
57
|
};
|
|
41
58
|
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# common.sh
|
|
2
|
+
#!/bin/bash
|
|
3
|
+
|
|
4
|
+
old_package_name='agora-electron-sdk'
|
|
5
|
+
new_package_name='shengwang-electron-sdk'
|
|
6
|
+
|
|
7
|
+
#./package.json
|
|
8
|
+
old_name="\"name\": \"agora-electron-sdk\""
|
|
9
|
+
new_name="\"name\": \"shengwang-electron-sdk\""
|
|
10
|
+
|
|
11
|
+
old_description="\"description\": \"agora-electron-sdk\""
|
|
12
|
+
new_description="\"description\": \"shengwang-electron-sdk\""
|
|
13
|
+
|
|
14
|
+
old_yarn_link="yarn example link agora-electron-sdk"
|
|
15
|
+
new_yarn_link="yarn example link shengwang-electron-sdk"
|
|
16
|
+
|
|
17
|
+
# node_modules
|
|
18
|
+
old_node_modules="node_modules/agora-electron-sdk"
|
|
19
|
+
new_node_modules="node_modules/shengwang-electron-sdk"
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
#!/bin/bash
|
|
2
|
+
set -e
|
|
3
|
+
MY_PATH=$(realpath $(dirname "$0"))
|
|
4
|
+
PROJECT_ROOT=$(realpath ${MY_PATH}/../..)
|
|
5
|
+
. ${PROJECT_ROOT}/scripts/publishCN/common.sh
|
|
6
|
+
|
|
7
|
+
change_file=${PROJECT_ROOT}/package.json
|
|
8
|
+
sed "s/${old_name}/${new_name}/g" ${change_file} >tmp && mv tmp ${change_file}
|
|
9
|
+
sed "s/${old_description}/${new_description}/g" ${change_file} >tmp && mv tmp ${change_file}
|
|
10
|
+
sed "s/${old_yarn_link}/${new_yarn_link}/g" ${change_file} >tmp && mv tmp ${change_file}
|
|
11
|
+
|
|
12
|
+
change_file=${PROJECT_ROOT}/tsconfig.json
|
|
13
|
+
sed "s/${old_package_name}/${new_package_name}/g" ${change_file} >tmp && mv tmp ${change_file}
|
|
14
|
+
|
|
15
|
+
change_file=${PROJECT_ROOT}/.github/workflows/publish.yml
|
|
16
|
+
sed "s/${old_package_name}/${new_package_name}/g" ${change_file} >tmp && mv tmp ${change_file}
|
|
17
|
+
|
|
18
|
+
change_file=${PROJECT_ROOT}/ci/packager-mac.sh
|
|
19
|
+
sed "s#${old_node_modules}#${new_node_modules}#g" ${change_file} >tmp && mv tmp ${change_file}
|
|
20
|
+
|
|
21
|
+
change_file=${PROJECT_ROOT}/ci/packager-win.ps1
|
|
22
|
+
sed "s#${old_node_modules}#${new_node_modules}#g" ${change_file} >tmp && mv tmp ${change_file}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
#!/bin/bash
|
|
2
|
+
set -e
|
|
3
|
+
MY_PATH=$(realpath $(dirname "$0"))
|
|
4
|
+
PROJECT_ROOT=$(realpath ${MY_PATH}/../..)
|
|
5
|
+
. ${PROJECT_ROOT}/scripts/publishCN/common.sh
|
|
6
|
+
|
|
7
|
+
change_dir="${PROJECT_ROOT}/example/src"
|
|
8
|
+
|
|
9
|
+
find "$change_dir" -type f | while read -r file; do
|
|
10
|
+
sed -i.bak "s/${old_package_name}/${new_package_name}/g" "$file"
|
|
11
|
+
echo "Replaced in $file"
|
|
12
|
+
done
|
|
13
|
+
|
|
14
|
+
change_file=${PROJECT_ROOT}/example/package.json
|
|
15
|
+
sed "s/${old_package_name}/${new_package_name}/g" ${change_file} >tmp && mv tmp ${change_file}
|
|
16
|
+
|
|
17
|
+
change_file=${PROJECT_ROOT}/example/webpack.renderer.additions.js
|
|
18
|
+
sed "s/${old_package_name}/${new_package_name}/g" ${change_file} >tmp && mv tmp ${change_file}
|
|
19
|
+
|
|
20
|
+
find "$change_dir" -name "*.bak" -type f -delete
|
|
21
|
+
|
|
22
|
+
echo "All replacements completed successfully, and backup files have been deleted."
|
package/scripts/zipBuild.js
CHANGED
|
@@ -4,8 +4,31 @@ const { exec } = require('shelljs');
|
|
|
4
4
|
|
|
5
5
|
const logger = require('./logger');
|
|
6
6
|
const { getOS } = require('./util');
|
|
7
|
+
const fs = require('fs');
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
const keepList = [
|
|
11
|
+
'AgoraRtcWrapper',
|
|
12
|
+
'agora_node_ext'
|
|
13
|
+
];
|
|
14
|
+
|
|
15
|
+
const filesMove = (src, dest, keepList) => {
|
|
16
|
+
fs.readdirSync(src).forEach(file => {
|
|
17
|
+
const filePath = path.join(src, file);
|
|
18
|
+
const shouldKeep = keepList.some(pattern => file.includes(pattern));
|
|
19
|
+
if (!shouldKeep) {
|
|
20
|
+
const destPath = path.join(dest, file);
|
|
21
|
+
fs.renameSync(filePath, destPath);
|
|
22
|
+
}
|
|
23
|
+
});
|
|
24
|
+
};
|
|
7
25
|
|
|
8
26
|
const zipBuild = async () => {
|
|
27
|
+
const temp_native = path.join(__dirname, '..', 'build', 'temp_native');
|
|
28
|
+
const build_release = path.join(__dirname, '..', 'build', 'Release');
|
|
29
|
+
fs.mkdirSync(temp_native);
|
|
30
|
+
filesMove(build_release, temp_native, keepList);
|
|
31
|
+
|
|
9
32
|
const isMac = getOS() === 'mac';
|
|
10
33
|
const fileListStr = ` build${path.sep}Release js types package.json`;
|
|
11
34
|
const shellStr =
|
|
@@ -14,6 +37,8 @@ const zipBuild = async () => {
|
|
|
14
37
|
if (code !== 0) {
|
|
15
38
|
logger.error(stderr);
|
|
16
39
|
}
|
|
40
|
+
filesMove(temp_native, build_release, []);
|
|
41
|
+
fs.rmdirSync(temp_native, { recursive: true });
|
|
17
42
|
};
|
|
18
43
|
|
|
19
44
|
module.exports = zipBuild;
|
package/ts/Private/AgoraBase.ts
CHANGED
|
@@ -772,11 +772,11 @@ export enum OrientationMode {
|
|
|
772
772
|
*/
|
|
773
773
|
export enum DegradationPreference {
|
|
774
774
|
/**
|
|
775
|
-
*
|
|
775
|
+
* 0: (Default) Automatic mode. The SDK will automatically select MaintainFramerate, MaintainBalanced or MaintainResolution based on the video scenario you set, in order to achieve the best overall quality of experience (QoE).
|
|
776
776
|
*/
|
|
777
777
|
MaintainAuto = -1,
|
|
778
778
|
/**
|
|
779
|
-
* 0:
|
|
779
|
+
* 0: Prefers to reduce the video frame rate while maintaining video resolution during video encoding under limited bandwidth. This degradation preference is suitable for scenarios where video quality is prioritized. Deprecated: This enumerator is deprecated. Use other enumerations instead.
|
|
780
780
|
*/
|
|
781
781
|
MaintainQuality = 0,
|
|
782
782
|
/**
|
|
@@ -1266,7 +1266,7 @@ export class EncodedVideoFrameInfo {
|
|
|
1266
1266
|
*/
|
|
1267
1267
|
export enum CompressionPreference {
|
|
1268
1268
|
/**
|
|
1269
|
-
*
|
|
1269
|
+
* -1: (Default) Automatic mode. The SDK will automatically select PreferLowLatency or PreferQuality based on the video scenario you set to achieve the best user experience.
|
|
1270
1270
|
*/
|
|
1271
1271
|
PreferCompressionAuto = -1,
|
|
1272
1272
|
/**
|
|
@@ -1274,7 +1274,7 @@ export enum CompressionPreference {
|
|
|
1274
1274
|
*/
|
|
1275
1275
|
PreferLowLatency = 0,
|
|
1276
1276
|
/**
|
|
1277
|
-
* 1:
|
|
1277
|
+
* 1: High quality preference. The SDK compresses video frames while maintaining video quality. This preference is suitable for scenarios where video quality is prioritized.
|
|
1278
1278
|
*/
|
|
1279
1279
|
PreferQuality = 1,
|
|
1280
1280
|
}
|
|
@@ -2108,11 +2108,11 @@ export enum VideoApplicationScenarioType {
|
|
|
2108
2108
|
*/
|
|
2109
2109
|
ApplicationScenarioMeeting = 1,
|
|
2110
2110
|
/**
|
|
2111
|
-
* ApplicationScenario1v1 (2) is
|
|
2111
|
+
* ApplicationScenario1v1 (2) This is applicable to the scenario. To meet the requirements for low latency and high-quality video in this scenario, the SDK optimizes its strategies, improving performance in terms of video quality, first frame rendering, latency on mid-to-low-end devices, and smoothness under weak network conditions. 2: 1v1 video call scenario.
|
|
2112
2112
|
*/
|
|
2113
2113
|
ApplicationScenario1v1 = 2,
|
|
2114
2114
|
/**
|
|
2115
|
-
*
|
|
2115
|
+
* ApplicationScenarioLiveshow (3) This is applicable to the scenario. In this scenario, fast video rendering and high image quality are crucial. The SDK implements several performance optimizations, including automatically enabling accelerated audio and video frame rendering to minimize first-frame latency (no need to call enableInstantMediaRendering), and B-frame encoding to achieve better image quality and bandwidth efficiency. The SDK also provides enhanced video quality and smooth playback, even in poor network conditions or on lower-end devices. 3. Live show scenario.
|
|
2116
2116
|
*/
|
|
2117
2117
|
ApplicationScenarioLiveshow = 3,
|
|
2118
2118
|
}
|
|
@@ -2326,11 +2326,11 @@ export enum LocalVideoStreamReason {
|
|
|
2326
2326
|
*/
|
|
2327
2327
|
LocalVideoStreamReasonDeviceNotFound = 8,
|
|
2328
2328
|
/**
|
|
2329
|
-
* 9:
|
|
2329
|
+
* 9: The video capture device currently in use is disconnected (such as being unplugged).
|
|
2330
2330
|
*/
|
|
2331
2331
|
LocalVideoStreamReasonDeviceDisconnected = 9,
|
|
2332
2332
|
/**
|
|
2333
|
-
* 10:
|
|
2333
|
+
* 10: The SDK cannot find the video device in the video device list. Check whether the ID of the video device is valid.
|
|
2334
2334
|
*/
|
|
2335
2335
|
LocalVideoStreamReasonDeviceInvalidId = 10,
|
|
2336
2336
|
/**
|
|
@@ -2346,11 +2346,11 @@ export enum LocalVideoStreamReason {
|
|
|
2346
2346
|
*/
|
|
2347
2347
|
LocalVideoStreamReasonDeviceSystemPressure = 101,
|
|
2348
2348
|
/**
|
|
2349
|
-
* 11:
|
|
2349
|
+
* 11: The shared window is minimized when you call the startScreenCaptureByWindowId method to share a window. The SDK cannot share a minimized window. Please prompt the user to unminimize the shared window.
|
|
2350
2350
|
*/
|
|
2351
2351
|
LocalVideoStreamReasonScreenCaptureWindowMinimized = 11,
|
|
2352
2352
|
/**
|
|
2353
|
-
* 12:
|
|
2353
|
+
* 12: The error code indicates that a window shared by the window ID has been closed or a full-screen window shared by the window ID has exited full-screen mode. After exiting full-screen mode, remote users cannot see the shared window. To prevent remote users from seeing a black screen, Agora recommends that you immediately stop screen sharing. Common scenarios reporting this error code:
|
|
2354
2354
|
* The local user closes the shared window.
|
|
2355
2355
|
* The local user shows some slides in full-screen mode first, and then shares the windows of the slides. After the user exits full-screen mode, the SDK reports this error code.
|
|
2356
2356
|
* The local user watches a web video or reads a web document in full-screen mode first, and then shares the window of the web video or document. After the user exits full-screen mode, the SDK reports this error code.
|
|
@@ -2365,7 +2365,7 @@ export enum LocalVideoStreamReason {
|
|
|
2365
2365
|
*/
|
|
2366
2366
|
LocalVideoStreamReasonScreenCaptureWindowNotSupported = 20,
|
|
2367
2367
|
/**
|
|
2368
|
-
* 21: (Windows only) The
|
|
2368
|
+
* 21: (Windows and Android only) The currently captured window has no data.
|
|
2369
2369
|
*/
|
|
2370
2370
|
LocalVideoStreamReasonScreenCaptureFailure = 21,
|
|
2371
2371
|
/**
|
|
@@ -3282,41 +3282,45 @@ export enum VideoTranscoderError {
|
|
|
3282
3282
|
}
|
|
3283
3283
|
|
|
3284
3284
|
/**
|
|
3285
|
-
*
|
|
3285
|
+
* The source of the audio streams that are mixed locally.
|
|
3286
3286
|
*/
|
|
3287
3287
|
export class MixedAudioStream {
|
|
3288
3288
|
/**
|
|
3289
|
-
*
|
|
3289
|
+
* The type of the audio source. See AudioSourceType.
|
|
3290
3290
|
*/
|
|
3291
3291
|
sourceType?: AudioSourceType;
|
|
3292
3292
|
/**
|
|
3293
|
-
*
|
|
3293
|
+
* The user ID of the remote user. Set this parameter if the source type of the locally mixed audio steams is AudioSourceRemoteUser.
|
|
3294
3294
|
*/
|
|
3295
3295
|
remoteUserUid?: number;
|
|
3296
3296
|
/**
|
|
3297
|
-
*
|
|
3297
|
+
* The channel name. This parameter signifies the channel in which users engage in real-time audio and video interaction. Under the premise of the same App ID, users who fill in the same channel ID enter the same channel for audio and video interaction. The string length must be less than 64 bytes. Supported characters (89 characters in total):
|
|
3298
|
+
* All lowercase English letters: a to z.
|
|
3299
|
+
* All uppercase English letters: A to Z.
|
|
3300
|
+
* All numeric characters: 0 to 9.
|
|
3301
|
+
* "!", "#", "$", "%", "&", "(", ")", "+", "-", ":", ";", "<", "=", ".", ">", "?", "@", "[", "]", "^", "_", "{", "}", "|", "~", "," Set this parameter if the source type of the locally mixed audio streams is AudioSourceRemoteChannel or AudioSourceRemoteUser.
|
|
3298
3302
|
*/
|
|
3299
3303
|
channelId?: string;
|
|
3300
3304
|
/**
|
|
3301
|
-
*
|
|
3305
|
+
* The audio track ID. Set this parameter to the custom audio track ID returned in createCustomAudioTrack. Set this parameter if the source type of the locally mixed audio steams is AudioSourceCustom.
|
|
3302
3306
|
*/
|
|
3303
3307
|
trackId?: number;
|
|
3304
3308
|
}
|
|
3305
3309
|
|
|
3306
3310
|
/**
|
|
3307
|
-
*
|
|
3311
|
+
* The configurations for mixing the lcoal audio.
|
|
3308
3312
|
*/
|
|
3309
3313
|
export class LocalAudioMixerConfiguration {
|
|
3310
3314
|
/**
|
|
3311
|
-
*
|
|
3315
|
+
* The number of the audio streams that are mixed locally.
|
|
3312
3316
|
*/
|
|
3313
3317
|
streamCount?: number;
|
|
3314
3318
|
/**
|
|
3315
|
-
*
|
|
3319
|
+
* The source of the audio streams that are mixed locally. See MixedAudioStream.
|
|
3316
3320
|
*/
|
|
3317
3321
|
audioInputStreams?: MixedAudioStream[];
|
|
3318
3322
|
/**
|
|
3319
|
-
*
|
|
3323
|
+
* Whether the mxied audio stream uses the timestamp of the audio frames captured by the local microphone. true : (Default) Yes. Set to this value if you want all locally captured audio streams synchronized. false : No. The SDK uses the timestamp of the audio frames at the time when they are mixed.
|
|
3320
3324
|
*/
|
|
3321
3325
|
syncWithLocalMic?: boolean;
|
|
3322
3326
|
}
|
|
@@ -3854,15 +3858,22 @@ export class FaceShapeBeautyOptions {
|
|
|
3854
3858
|
}
|
|
3855
3859
|
|
|
3856
3860
|
/**
|
|
3857
|
-
*
|
|
3861
|
+
* Filter effect options.
|
|
3858
3862
|
*/
|
|
3859
3863
|
export class FilterEffectOptions {
|
|
3860
3864
|
/**
|
|
3861
|
-
*
|
|
3865
|
+
* The absolute path to the local cube map texture file, which can be used to customize the filter effect. The specified .cude file should strictly follow the Cube LUT Format Specification; otherwise, the filter options do not take effect. The following is a sample of the .cude file:
|
|
3866
|
+
* LUT_3D_SIZE 32
|
|
3867
|
+
* 0.0039215689 0 0.0039215682
|
|
3868
|
+
* 0.0086021447 0.0037950677 0
|
|
3869
|
+
* ...
|
|
3870
|
+
* 0.0728652592 0.0039215689 0
|
|
3871
|
+
* The identifier LUT_3D_SIZE on the first line of the cube map file represents the size of the three-dimensional lookup table. The LUT size for filter effect can only be set to 32.
|
|
3872
|
+
* The SDK provides a built-in built_in_whiten_filter.cube file. You can pass the absolute path of this file to get the whitening filter effect.
|
|
3862
3873
|
*/
|
|
3863
3874
|
path?: string;
|
|
3864
3875
|
/**
|
|
3865
|
-
*
|
|
3876
|
+
* The intensity of the filter effect, with a range value of [0.0,1.0], in which 0.0 represents no filter effect. The default value is 0.5. The higher the value, the stronger the filter effect.
|
|
3866
3877
|
*/
|
|
3867
3878
|
strength?: number;
|
|
3868
3879
|
}
|
|
@@ -3924,7 +3935,7 @@ export enum VideoDenoiserMode {
|
|
|
3924
3935
|
}
|
|
3925
3936
|
|
|
3926
3937
|
/**
|
|
3927
|
-
*
|
|
3938
|
+
* Video noise reduction level.
|
|
3928
3939
|
*/
|
|
3929
3940
|
export enum VideoDenoiserLevel {
|
|
3930
3941
|
/**
|
|
@@ -3932,7 +3943,7 @@ export enum VideoDenoiserLevel {
|
|
|
3932
3943
|
*/
|
|
3933
3944
|
VideoDenoiserLevelHighQuality = 0,
|
|
3934
3945
|
/**
|
|
3935
|
-
* 1: Promotes reducing performance consumption during video noise reduction. prioritizes reducing performance consumption over video noise reduction quality. The performance consumption is lower, and the video noise reduction speed is faster. To avoid a noticeable shadowing effect (shadows trailing behind moving objects) in the processed video, Agora recommends that you use this
|
|
3946
|
+
* 1: Promotes reducing performance consumption during video noise reduction. It prioritizes reducing performance consumption over video noise reduction quality. The performance consumption is lower, and the video noise reduction speed is faster. To avoid a noticeable shadowing effect (shadows trailing behind moving objects) in the processed video, Agora recommends that you use this setting when the camera is fixed.
|
|
3936
3947
|
*/
|
|
3937
3948
|
VideoDenoiserLevelFast = 1,
|
|
3938
3949
|
}
|
|
@@ -4088,7 +4099,7 @@ export class AudioTrackConfig {
|
|
|
4088
4099
|
*/
|
|
4089
4100
|
enableLocalPlayback?: boolean;
|
|
4090
4101
|
/**
|
|
4091
|
-
*
|
|
4102
|
+
* Whether to enable audio processing module: true Enable the audio processing module to apply the Automatic Echo Cancellation (AEC), Automatic Noise Suppression (ANS), and Automatic Gain Control (AGC) effects. false : (Default) Do not enable the audio processing module. This parameter only takes effect on AudioTrackDirect in custom audio capturing.
|
|
4092
4103
|
*/
|
|
4093
4104
|
enableAudioProcessing?: boolean;
|
|
4094
4105
|
}
|
|
@@ -4790,7 +4801,7 @@ export class ChannelMediaRelayConfiguration {
|
|
|
4790
4801
|
/**
|
|
4791
4802
|
* The information of the target channel ChannelMediaInfo. It contains the following members: channelName : The name of the target channel. token : The token for joining the target channel. It is generated with the channelName and uid you set in destInfos.
|
|
4792
4803
|
* If you have not enabled the App Certificate, set this parameter as the default value null, which means the SDK applies the App ID.
|
|
4793
|
-
* If you have enabled the App Certificate, you must use the token generated with the channelName and uid. If the token of any target channel expires, the whole media relay stops; hence Agora recommends that you specify the same expiration time for the tokens of all the target channels. uid : The unique user ID to identify the relay stream in the target channel. The value ranges from 0 to (2 32 -1). To avoid user ID conflicts, this user ID must be different from any other user ID in the target channel. The default value is 0, which means the SDK generates a random
|
|
4804
|
+
* If you have enabled the App Certificate, you must use the token generated with the channelName and uid. If the token of any target channel expires, the whole media relay stops; hence Agora recommends that you specify the same expiration time for the tokens of all the target channels. uid : The unique user ID to identify the relay stream in the target channel. The value ranges from 0 to (2 32 -1). To avoid user ID conflicts, this user ID must be different from any other user ID in the target channel. The default value is 0, which means the SDK generates a random UID.
|
|
4794
4805
|
*/
|
|
4795
4806
|
destInfos?: ChannelMediaInfo[];
|
|
4796
4807
|
/**
|