agora-electron-sdk 0.0.0-dev.1

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.
Files changed (369) hide show
  1. package/CHANGELOG.md +315 -0
  2. package/LICENSE +21 -0
  3. package/README.md +143 -0
  4. package/gulpfile.js +52 -0
  5. package/js/AgoraSdk.js +64 -0
  6. package/js/Decoder/gpu-utils.js +74 -0
  7. package/js/Decoder/index.js +172 -0
  8. package/js/Private/AgoraBase.js +3985 -0
  9. package/js/Private/AgoraMediaBase.js +1014 -0
  10. package/js/Private/AgoraMediaPlayerTypes.js +316 -0
  11. package/js/Private/IAgoraH265Transcoder.js +36 -0
  12. package/js/Private/IAgoraLog.js +78 -0
  13. package/js/Private/IAgoraMediaEngine.js +32 -0
  14. package/js/Private/IAgoraMediaPlayer.js +16 -0
  15. package/js/Private/IAgoraMediaPlayerSource.js +3 -0
  16. package/js/Private/IAgoraMediaRecorder.js +10 -0
  17. package/js/Private/IAgoraMediaStreamingSource.js +74 -0
  18. package/js/Private/IAgoraMusicContentCenter.js +157 -0
  19. package/js/Private/IAgoraRhythmPlayer.js +62 -0
  20. package/js/Private/IAgoraRtcEngine.js +982 -0
  21. package/js/Private/IAgoraRtcEngineEx.js +19 -0
  22. package/js/Private/IAgoraSpatialAudio.js +24 -0
  23. package/js/Private/IAudioDeviceManager.js +20 -0
  24. package/js/Private/extension/AgoraBaseExtension.js +3 -0
  25. package/js/Private/extension/AgoraMediaBaseExtension.js +2 -0
  26. package/js/Private/extension/AgoraMediaPlayerTypesExtension.js +2 -0
  27. package/js/Private/extension/IAgoraH265TranscoderExtension.js +2 -0
  28. package/js/Private/extension/IAgoraLogExtension.js +2 -0
  29. package/js/Private/extension/IAgoraMediaEngineExtension.js +2 -0
  30. package/js/Private/extension/IAgoraMediaPlayerExtension.js +2 -0
  31. package/js/Private/extension/IAgoraMediaPlayerSourceExtension.js +2 -0
  32. package/js/Private/extension/IAgoraMediaRecorderExtension.js +2 -0
  33. package/js/Private/extension/IAgoraMusicContentCenterExtension.js +2 -0
  34. package/js/Private/extension/IAgoraRhythmPlayerExtension.js +2 -0
  35. package/js/Private/extension/IAgoraRtcEngineExExtension.js +2 -0
  36. package/js/Private/extension/IAgoraRtcEngineExtension.js +2 -0
  37. package/js/Private/extension/IAgoraSpatialAudioExtension.js +2 -0
  38. package/js/Private/extension/IAudioDeviceManagerExtension.js +2 -0
  39. package/js/Private/impl/AgoraBaseImpl.js +23 -0
  40. package/js/Private/impl/AgoraMediaBaseImpl.js +149 -0
  41. package/js/Private/impl/IAgoraH265TranscoderImpl.js +116 -0
  42. package/js/Private/impl/IAgoraMediaEngineImpl.js +337 -0
  43. package/js/Private/impl/IAgoraMediaPlayerImpl.js +950 -0
  44. package/js/Private/impl/IAgoraMediaPlayerSourceImpl.js +73 -0
  45. package/js/Private/impl/IAgoraMediaRecorderImpl.js +47 -0
  46. package/js/Private/impl/IAgoraMusicContentCenterImpl.js +422 -0
  47. package/js/Private/impl/IAgoraRtcEngineExImpl.js +1042 -0
  48. package/js/Private/impl/IAgoraRtcEngineImpl.js +5167 -0
  49. package/js/Private/impl/IAgoraSpatialAudioImpl.js +358 -0
  50. package/js/Private/impl/IAudioDeviceManagerImpl.js +375 -0
  51. package/js/Private/internal/AgoraH265TranscoderInternal.js +62 -0
  52. package/js/Private/internal/AgoraMediaBaseInternal.js +15 -0
  53. package/js/Private/internal/AudioDeviceManagerInternal.js +44 -0
  54. package/js/Private/internal/IrisApiEngine.js +424 -0
  55. package/js/Private/internal/LocalSpatialAudioEngineInternal.js +7 -0
  56. package/js/Private/internal/MediaEngineInternal.js +122 -0
  57. package/js/Private/internal/MediaPlayerInternal.js +194 -0
  58. package/js/Private/internal/MediaRecorderInternal.js +70 -0
  59. package/js/Private/internal/MusicContentCenterInternal.js +139 -0
  60. package/js/Private/internal/RtcEngineExInternal.js +430 -0
  61. package/js/Private/ipc/main.js +21 -0
  62. package/js/Private/ipc/renderer.js +21 -0
  63. package/js/Private/ti/AgoraBase-ti.js +40 -0
  64. package/js/Private/ti/AgoraMediaBase-ti.js +75 -0
  65. package/js/Private/ti/AgoraMediaPlayerTypes-ti.js +5 -0
  66. package/js/Private/ti/IAgoraH265Transcoder-ti.js +40 -0
  67. package/js/Private/ti/IAgoraLog-ti.js +5 -0
  68. package/js/Private/ti/IAgoraMediaEngine-ti.js +5 -0
  69. package/js/Private/ti/IAgoraMediaPlayer-ti.js +38 -0
  70. package/js/Private/ti/IAgoraMediaPlayerSource-ti.js +50 -0
  71. package/js/Private/ti/IAgoraMediaRecorder-ti.js +5 -0
  72. package/js/Private/ti/IAgoraMediaStreamingSource-ti.js +5 -0
  73. package/js/Private/ti/IAgoraMusicContentCenter-ti.js +42 -0
  74. package/js/Private/ti/IAgoraRhythmPlayer-ti.js +5 -0
  75. package/js/Private/ti/IAgoraRtcEngine-ti.js +141 -0
  76. package/js/Private/ti/IAgoraRtcEngineEx-ti.js +5 -0
  77. package/js/Private/ti/IAgoraSpatialAudio-ti.js +5 -0
  78. package/js/Private/ti/IAudioDeviceManager-ti.js +5 -0
  79. package/js/Renderer/AgoraView.js +161 -0
  80. package/js/Renderer/CapabilityManager.js +99 -0
  81. package/js/Renderer/IRenderer.js +136 -0
  82. package/js/Renderer/IRendererCache.js +75 -0
  83. package/js/Renderer/RendererCache.js +100 -0
  84. package/js/Renderer/RendererManager.js +301 -0
  85. package/js/Renderer/WebCodecsRenderer/index.js +109 -0
  86. package/js/Renderer/WebCodecsRendererCache.js +115 -0
  87. package/js/Renderer/WebGLRenderer/index.js +314 -0
  88. package/js/Renderer/WebGLRenderer/webgl-utils.js +1337 -0
  89. package/js/Renderer/YUVCanvasRenderer/index.js +46 -0
  90. package/js/Renderer/index.js +17 -0
  91. package/js/Types.js +67 -0
  92. package/js/Utils.js +187 -0
  93. package/package.json +167 -0
  94. package/scripts/bootstrap.js +29 -0
  95. package/scripts/build.js +37 -0
  96. package/scripts/buildJS.js +14 -0
  97. package/scripts/checkElectron.js +43 -0
  98. package/scripts/clean.js +16 -0
  99. package/scripts/download.js +105 -0
  100. package/scripts/downloadPrebuild.js +199 -0
  101. package/scripts/getConfig.js +73 -0
  102. package/scripts/logger.js +32 -0
  103. package/scripts/synclib.js +69 -0
  104. package/scripts/util.js +47 -0
  105. package/scripts/zipBuild.js +40 -0
  106. package/ts/AgoraSdk.ts +54 -0
  107. package/ts/Decoder/gpu-utils.ts +92 -0
  108. package/ts/Decoder/index.ts +206 -0
  109. package/ts/Private/AgoraBase.ts +5511 -0
  110. package/ts/Private/AgoraMediaBase.ts +1764 -0
  111. package/ts/Private/AgoraMediaPlayerTypes.ts +464 -0
  112. package/ts/Private/IAgoraH265Transcoder.ts +73 -0
  113. package/ts/Private/IAgoraLog.ts +91 -0
  114. package/ts/Private/IAgoraMediaEngine.ts +316 -0
  115. package/ts/Private/IAgoraMediaPlayer.ts +744 -0
  116. package/ts/Private/IAgoraMediaPlayerSource.ts +137 -0
  117. package/ts/Private/IAgoraMediaRecorder.ts +25 -0
  118. package/ts/Private/IAgoraMediaStreamingSource.ts +81 -0
  119. package/ts/Private/IAgoraMusicContentCenter.ts +455 -0
  120. package/ts/Private/IAgoraRhythmPlayer.ts +67 -0
  121. package/ts/Private/IAgoraRtcEngine.ts +7306 -0
  122. package/ts/Private/IAgoraRtcEngineEx.ts +992 -0
  123. package/ts/Private/IAgoraSpatialAudio.ts +250 -0
  124. package/ts/Private/IAudioDeviceManager.ts +342 -0
  125. package/ts/Private/extension/AgoraBaseExtension.ts +14 -0
  126. package/ts/Private/extension/AgoraMediaBaseExtension.ts +1 -0
  127. package/ts/Private/extension/AgoraMediaPlayerTypesExtension.ts +1 -0
  128. package/ts/Private/extension/IAgoraH265TranscoderExtension.ts +39 -0
  129. package/ts/Private/extension/IAgoraLogExtension.ts +1 -0
  130. package/ts/Private/extension/IAgoraMediaEngineExtension.ts +62 -0
  131. package/ts/Private/extension/IAgoraMediaPlayerExtension.ts +64 -0
  132. package/ts/Private/extension/IAgoraMediaPlayerSourceExtension.ts +1 -0
  133. package/ts/Private/extension/IAgoraMediaRecorderExtension.ts +59 -0
  134. package/ts/Private/extension/IAgoraMusicContentCenterExtension.ts +34 -0
  135. package/ts/Private/extension/IAgoraRhythmPlayerExtension.ts +1 -0
  136. package/ts/Private/extension/IAgoraRtcEngineExExtension.ts +1 -0
  137. package/ts/Private/extension/IAgoraRtcEngineExtension.ts +64 -0
  138. package/ts/Private/extension/IAgoraSpatialAudioExtension.ts +1 -0
  139. package/ts/Private/extension/IAudioDeviceManagerExtension.ts +1 -0
  140. package/ts/Private/impl/AgoraBaseImpl.ts +39 -0
  141. package/ts/Private/impl/AgoraMediaBaseImpl.ts +237 -0
  142. package/ts/Private/impl/IAgoraH265TranscoderImpl.ts +152 -0
  143. package/ts/Private/impl/IAgoraMediaEngineImpl.ts +491 -0
  144. package/ts/Private/impl/IAgoraMediaPlayerImpl.ts +1169 -0
  145. package/ts/Private/impl/IAgoraMediaPlayerSourceImpl.ts +94 -0
  146. package/ts/Private/impl/IAgoraMediaRecorderImpl.ts +59 -0
  147. package/ts/Private/impl/IAgoraMusicContentCenterImpl.ts +562 -0
  148. package/ts/Private/impl/IAgoraRtcEngineExImpl.ts +1672 -0
  149. package/ts/Private/impl/IAgoraRtcEngineImpl.ts +7352 -0
  150. package/ts/Private/impl/IAgoraSpatialAudioImpl.ts +495 -0
  151. package/ts/Private/impl/IAudioDeviceManagerImpl.ts +443 -0
  152. package/ts/Private/internal/AgoraH265TranscoderInternal.ts +97 -0
  153. package/ts/Private/internal/AgoraMediaBaseInternal.ts +15 -0
  154. package/ts/Private/internal/AudioDeviceManagerInternal.ts +46 -0
  155. package/ts/Private/internal/IrisApiEngine.ts +598 -0
  156. package/ts/Private/internal/LocalSpatialAudioEngineInternal.ts +3 -0
  157. package/ts/Private/internal/MediaEngineInternal.ts +190 -0
  158. package/ts/Private/internal/MediaPlayerInternal.ts +311 -0
  159. package/ts/Private/internal/MediaRecorderInternal.ts +100 -0
  160. package/ts/Private/internal/MusicContentCenterInternal.ts +208 -0
  161. package/ts/Private/internal/RtcEngineExInternal.ts +647 -0
  162. package/ts/Private/ipc/main.ts +22 -0
  163. package/ts/Private/ipc/renderer.ts +21 -0
  164. package/ts/Private/ti/AgoraBase-ti.ts +16 -0
  165. package/ts/Private/ti/AgoraMediaBase-ti.ts +58 -0
  166. package/ts/Private/ti/AgoraMediaPlayerTypes-ti.ts +11 -0
  167. package/ts/Private/ti/IAgoraH265Transcoder-ti.ts +16 -0
  168. package/ts/Private/ti/IAgoraLog-ti.ts +11 -0
  169. package/ts/Private/ti/IAgoraMediaEngine-ti.ts +11 -0
  170. package/ts/Private/ti/IAgoraMediaPlayer-ti.ts +14 -0
  171. package/ts/Private/ti/IAgoraMediaPlayerSource-ti.ts +26 -0
  172. package/ts/Private/ti/IAgoraMediaRecorder-ti.ts +11 -0
  173. package/ts/Private/ti/IAgoraMediaStreamingSource-ti.ts +11 -0
  174. package/ts/Private/ti/IAgoraMusicContentCenter-ti.ts +18 -0
  175. package/ts/Private/ti/IAgoraRhythmPlayer-ti.ts +11 -0
  176. package/ts/Private/ti/IAgoraRtcEngine-ti.ts +119 -0
  177. package/ts/Private/ti/IAgoraRtcEngineEx-ti.ts +11 -0
  178. package/ts/Private/ti/IAgoraSpatialAudio-ti.ts +11 -0
  179. package/ts/Private/ti/IAudioDeviceManager-ti.ts +11 -0
  180. package/ts/Renderer/AgoraView.ts +235 -0
  181. package/ts/Renderer/CapabilityManager.ts +126 -0
  182. package/ts/Renderer/IRenderer.ts +158 -0
  183. package/ts/Renderer/IRendererCache.ts +96 -0
  184. package/ts/Renderer/RendererCache.ts +124 -0
  185. package/ts/Renderer/RendererManager.ts +400 -0
  186. package/ts/Renderer/WebCodecsRenderer/index.ts +145 -0
  187. package/ts/Renderer/WebCodecsRendererCache.ts +137 -0
  188. package/ts/Renderer/WebGLRenderer/index.ts +489 -0
  189. package/ts/Renderer/WebGLRenderer/webgl-utils.js +1510 -0
  190. package/ts/Renderer/YUVCanvasRenderer/index.ts +67 -0
  191. package/ts/Renderer/index.ts +1 -0
  192. package/ts/Types.ts +249 -0
  193. package/ts/Utils.ts +197 -0
  194. package/types/AgoraSdk.d.ts +40 -0
  195. package/types/AgoraSdk.d.ts.map +1 -0
  196. package/types/Decoder/gpu-utils.d.ts +21 -0
  197. package/types/Decoder/gpu-utils.d.ts.map +1 -0
  198. package/types/Decoder/index.d.ts +26 -0
  199. package/types/Decoder/index.d.ts.map +1 -0
  200. package/types/Private/AgoraBase.d.ts +5310 -0
  201. package/types/Private/AgoraBase.d.ts.map +1 -0
  202. package/types/Private/AgoraMediaBase.d.ts +1668 -0
  203. package/types/Private/AgoraMediaBase.d.ts.map +1 -0
  204. package/types/Private/AgoraMediaPlayerTypes.d.ts +453 -0
  205. package/types/Private/AgoraMediaPlayerTypes.d.ts.map +1 -0
  206. package/types/Private/IAgoraH265Transcoder.d.ts +28 -0
  207. package/types/Private/IAgoraH265Transcoder.d.ts.map +1 -0
  208. package/types/Private/IAgoraLog.d.ts +89 -0
  209. package/types/Private/IAgoraLog.d.ts.map +1 -0
  210. package/types/Private/IAgoraMediaEngine.d.ts +250 -0
  211. package/types/Private/IAgoraMediaEngine.d.ts.map +1 -0
  212. package/types/Private/IAgoraMediaPlayer.d.ts +648 -0
  213. package/types/Private/IAgoraMediaPlayer.d.ts.map +1 -0
  214. package/types/Private/IAgoraMediaPlayerSource.d.ts +109 -0
  215. package/types/Private/IAgoraMediaPlayerSource.d.ts.map +1 -0
  216. package/types/Private/IAgoraMediaRecorder.d.ts +20 -0
  217. package/types/Private/IAgoraMediaRecorder.d.ts.map +1 -0
  218. package/types/Private/IAgoraMediaStreamingSource.d.ts +42 -0
  219. package/types/Private/IAgoraMediaStreamingSource.d.ts.map +1 -0
  220. package/types/Private/IAgoraMusicContentCenter.d.ts +381 -0
  221. package/types/Private/IAgoraMusicContentCenter.d.ts.map +1 -0
  222. package/types/Private/IAgoraRhythmPlayer.d.ts +65 -0
  223. package/types/Private/IAgoraRhythmPlayer.d.ts.map +1 -0
  224. package/types/Private/IAgoraRtcEngine.d.ts +6103 -0
  225. package/types/Private/IAgoraRtcEngine.d.ts.map +1 -0
  226. package/types/Private/IAgoraRtcEngineEx.d.ts +741 -0
  227. package/types/Private/IAgoraRtcEngineEx.d.ts.map +1 -0
  228. package/types/Private/IAgoraSpatialAudio.d.ts +196 -0
  229. package/types/Private/IAgoraSpatialAudio.d.ts.map +1 -0
  230. package/types/Private/IAudioDeviceManager.d.ts +312 -0
  231. package/types/Private/IAudioDeviceManager.d.ts.map +1 -0
  232. package/types/Private/extension/AgoraBaseExtension.d.ts +14 -0
  233. package/types/Private/extension/AgoraBaseExtension.d.ts.map +1 -0
  234. package/types/Private/extension/AgoraMediaBaseExtension.d.ts +2 -0
  235. package/types/Private/extension/AgoraMediaBaseExtension.d.ts.map +1 -0
  236. package/types/Private/extension/AgoraMediaPlayerTypesExtension.d.ts +2 -0
  237. package/types/Private/extension/AgoraMediaPlayerTypesExtension.d.ts.map +1 -0
  238. package/types/Private/extension/IAgoraH265TranscoderExtension.d.ts +24 -0
  239. package/types/Private/extension/IAgoraH265TranscoderExtension.d.ts.map +1 -0
  240. package/types/Private/extension/IAgoraLogExtension.d.ts +2 -0
  241. package/types/Private/extension/IAgoraLogExtension.d.ts.map +1 -0
  242. package/types/Private/extension/IAgoraMediaEngineExtension.d.ts +40 -0
  243. package/types/Private/extension/IAgoraMediaEngineExtension.d.ts.map +1 -0
  244. package/types/Private/extension/IAgoraMediaPlayerExtension.d.ts +46 -0
  245. package/types/Private/extension/IAgoraMediaPlayerExtension.d.ts.map +1 -0
  246. package/types/Private/extension/IAgoraMediaPlayerSourceExtension.d.ts +2 -0
  247. package/types/Private/extension/IAgoraMediaPlayerSourceExtension.d.ts.map +1 -0
  248. package/types/Private/extension/IAgoraMediaRecorderExtension.d.ts +44 -0
  249. package/types/Private/extension/IAgoraMediaRecorderExtension.d.ts.map +1 -0
  250. package/types/Private/extension/IAgoraMusicContentCenterExtension.d.ts +20 -0
  251. package/types/Private/extension/IAgoraMusicContentCenterExtension.d.ts.map +1 -0
  252. package/types/Private/extension/IAgoraRhythmPlayerExtension.d.ts +2 -0
  253. package/types/Private/extension/IAgoraRhythmPlayerExtension.d.ts.map +1 -0
  254. package/types/Private/extension/IAgoraRtcEngineExExtension.d.ts +2 -0
  255. package/types/Private/extension/IAgoraRtcEngineExExtension.d.ts.map +1 -0
  256. package/types/Private/extension/IAgoraRtcEngineExtension.d.ts +42 -0
  257. package/types/Private/extension/IAgoraRtcEngineExtension.d.ts.map +1 -0
  258. package/types/Private/extension/IAgoraSpatialAudioExtension.d.ts +2 -0
  259. package/types/Private/extension/IAgoraSpatialAudioExtension.d.ts.map +1 -0
  260. package/types/Private/extension/IAudioDeviceManagerExtension.d.ts +2 -0
  261. package/types/Private/extension/IAudioDeviceManagerExtension.d.ts.map +1 -0
  262. package/types/Private/impl/AgoraBaseImpl.d.ts +3 -0
  263. package/types/Private/impl/AgoraBaseImpl.d.ts.map +1 -0
  264. package/types/Private/impl/AgoraMediaBaseImpl.d.ts +14 -0
  265. package/types/Private/impl/AgoraMediaBaseImpl.d.ts.map +1 -0
  266. package/types/Private/impl/IAgoraH265TranscoderImpl.d.ts +15 -0
  267. package/types/Private/impl/IAgoraH265TranscoderImpl.d.ts.map +1 -0
  268. package/types/Private/impl/IAgoraMediaEngineImpl.d.ts +46 -0
  269. package/types/Private/impl/IAgoraMediaEngineImpl.d.ts.map +1 -0
  270. package/types/Private/impl/IAgoraMediaPlayerImpl.d.ts +143 -0
  271. package/types/Private/impl/IAgoraMediaPlayerImpl.d.ts.map +1 -0
  272. package/types/Private/impl/IAgoraMediaPlayerSourceImpl.d.ts +3 -0
  273. package/types/Private/impl/IAgoraMediaPlayerSourceImpl.d.ts.map +1 -0
  274. package/types/Private/impl/IAgoraMediaRecorderImpl.d.ts +11 -0
  275. package/types/Private/impl/IAgoraMediaRecorderImpl.d.ts.map +1 -0
  276. package/types/Private/impl/IAgoraMusicContentCenterImpl.d.ts +67 -0
  277. package/types/Private/impl/IAgoraMusicContentCenterImpl.d.ts.map +1 -0
  278. package/types/Private/impl/IAgoraRtcEngineExImpl.d.ts +116 -0
  279. package/types/Private/impl/IAgoraRtcEngineExImpl.d.ts.map +1 -0
  280. package/types/Private/impl/IAgoraRtcEngineImpl.d.ts +628 -0
  281. package/types/Private/impl/IAgoraRtcEngineImpl.d.ts.map +1 -0
  282. package/types/Private/impl/IAgoraSpatialAudioImpl.d.ts +47 -0
  283. package/types/Private/impl/IAgoraSpatialAudioImpl.d.ts.map +1 -0
  284. package/types/Private/impl/IAudioDeviceManagerImpl.d.ts +65 -0
  285. package/types/Private/impl/IAudioDeviceManagerImpl.d.ts.map +1 -0
  286. package/types/Private/internal/AgoraH265TranscoderInternal.d.ts +14 -0
  287. package/types/Private/internal/AgoraH265TranscoderInternal.d.ts.map +1 -0
  288. package/types/Private/internal/AgoraMediaBaseInternal.d.ts +8 -0
  289. package/types/Private/internal/AgoraMediaBaseInternal.d.ts.map +1 -0
  290. package/types/Private/internal/AudioDeviceManagerInternal.d.ts +9 -0
  291. package/types/Private/internal/AudioDeviceManagerInternal.d.ts.map +1 -0
  292. package/types/Private/internal/IrisApiEngine.d.ts +69 -0
  293. package/types/Private/internal/IrisApiEngine.d.ts.map +1 -0
  294. package/types/Private/internal/LocalSpatialAudioEngineInternal.d.ts +4 -0
  295. package/types/Private/internal/LocalSpatialAudioEngineInternal.d.ts.map +1 -0
  296. package/types/Private/internal/MediaEngineInternal.d.ts +23 -0
  297. package/types/Private/internal/MediaEngineInternal.d.ts.map +1 -0
  298. package/types/Private/internal/MediaPlayerInternal.d.ts +30 -0
  299. package/types/Private/internal/MediaPlayerInternal.d.ts.map +1 -0
  300. package/types/Private/internal/MediaRecorderInternal.d.ts +16 -0
  301. package/types/Private/internal/MediaRecorderInternal.d.ts.map +1 -0
  302. package/types/Private/internal/MusicContentCenterInternal.d.ts +31 -0
  303. package/types/Private/internal/MusicContentCenterInternal.d.ts.map +1 -0
  304. package/types/Private/internal/RtcEngineExInternal.d.ts +73 -0
  305. package/types/Private/internal/RtcEngineExInternal.d.ts.map +1 -0
  306. package/types/Private/ipc/main.d.ts +2 -0
  307. package/types/Private/ipc/main.d.ts.map +1 -0
  308. package/types/Private/ipc/renderer.d.ts +3 -0
  309. package/types/Private/ipc/renderer.d.ts.map +1 -0
  310. package/types/Private/ti/AgoraBase-ti.d.ts +8 -0
  311. package/types/Private/ti/AgoraBase-ti.d.ts.map +1 -0
  312. package/types/Private/ti/AgoraMediaBase-ti.d.ts +15 -0
  313. package/types/Private/ti/AgoraMediaBase-ti.d.ts.map +1 -0
  314. package/types/Private/ti/AgoraMediaPlayerTypes-ti.d.ts +7 -0
  315. package/types/Private/ti/AgoraMediaPlayerTypes-ti.d.ts.map +1 -0
  316. package/types/Private/ti/IAgoraH265Transcoder-ti.d.ts +8 -0
  317. package/types/Private/ti/IAgoraH265Transcoder-ti.d.ts.map +1 -0
  318. package/types/Private/ti/IAgoraLog-ti.d.ts +7 -0
  319. package/types/Private/ti/IAgoraLog-ti.d.ts.map +1 -0
  320. package/types/Private/ti/IAgoraMediaEngine-ti.d.ts +7 -0
  321. package/types/Private/ti/IAgoraMediaEngine-ti.d.ts.map +1 -0
  322. package/types/Private/ti/IAgoraMediaPlayer-ti.d.ts +8 -0
  323. package/types/Private/ti/IAgoraMediaPlayer-ti.d.ts.map +1 -0
  324. package/types/Private/ti/IAgoraMediaPlayerSource-ti.d.ts +8 -0
  325. package/types/Private/ti/IAgoraMediaPlayerSource-ti.d.ts.map +1 -0
  326. package/types/Private/ti/IAgoraMediaRecorder-ti.d.ts +7 -0
  327. package/types/Private/ti/IAgoraMediaRecorder-ti.d.ts.map +1 -0
  328. package/types/Private/ti/IAgoraMediaStreamingSource-ti.d.ts +7 -0
  329. package/types/Private/ti/IAgoraMediaStreamingSource-ti.d.ts.map +1 -0
  330. package/types/Private/ti/IAgoraMusicContentCenter-ti.d.ts +8 -0
  331. package/types/Private/ti/IAgoraMusicContentCenter-ti.d.ts.map +1 -0
  332. package/types/Private/ti/IAgoraRhythmPlayer-ti.d.ts +7 -0
  333. package/types/Private/ti/IAgoraRhythmPlayer-ti.d.ts.map +1 -0
  334. package/types/Private/ti/IAgoraRtcEngine-ti.d.ts +10 -0
  335. package/types/Private/ti/IAgoraRtcEngine-ti.d.ts.map +1 -0
  336. package/types/Private/ti/IAgoraRtcEngineEx-ti.d.ts +7 -0
  337. package/types/Private/ti/IAgoraRtcEngineEx-ti.d.ts.map +1 -0
  338. package/types/Private/ti/IAgoraSpatialAudio-ti.d.ts +7 -0
  339. package/types/Private/ti/IAgoraSpatialAudio-ti.d.ts.map +1 -0
  340. package/types/Private/ti/IAudioDeviceManager-ti.d.ts +7 -0
  341. package/types/Private/ti/IAudioDeviceManager-ti.d.ts.map +1 -0
  342. package/types/Renderer/AgoraView.d.ts +76 -0
  343. package/types/Renderer/AgoraView.d.ts.map +1 -0
  344. package/types/Renderer/CapabilityManager.d.ts +20 -0
  345. package/types/Renderer/CapabilityManager.d.ts.map +1 -0
  346. package/types/Renderer/IRenderer.d.ts +20 -0
  347. package/types/Renderer/IRenderer.d.ts.map +1 -0
  348. package/types/Renderer/IRendererCache.d.ts +26 -0
  349. package/types/Renderer/IRendererCache.d.ts.map +1 -0
  350. package/types/Renderer/RendererCache.d.ts +24 -0
  351. package/types/Renderer/RendererCache.d.ts.map +1 -0
  352. package/types/Renderer/RendererManager.d.ts +66 -0
  353. package/types/Renderer/RendererManager.d.ts.map +1 -0
  354. package/types/Renderer/WebCodecsRenderer/index.d.ts +14 -0
  355. package/types/Renderer/WebCodecsRenderer/index.d.ts.map +1 -0
  356. package/types/Renderer/WebCodecsRendererCache.d.ts +15 -0
  357. package/types/Renderer/WebCodecsRendererCache.d.ts.map +1 -0
  358. package/types/Renderer/WebGLRenderer/index.d.ts +27 -0
  359. package/types/Renderer/WebGLRenderer/index.d.ts.map +1 -0
  360. package/types/Renderer/WebGLRenderer/webgl-utils.d.ts +1 -0
  361. package/types/Renderer/WebGLRenderer/webgl-utils.d.ts.map +1 -0
  362. package/types/Renderer/YUVCanvasRenderer/index.d.ts +9 -0
  363. package/types/Renderer/YUVCanvasRenderer/index.d.ts.map +1 -0
  364. package/types/Renderer/index.d.ts +2 -0
  365. package/types/Renderer/index.d.ts.map +1 -0
  366. package/types/Types.d.ts +177 -0
  367. package/types/Types.d.ts.map +1 -0
  368. package/types/Utils.d.ts +50 -0
  369. package/types/Utils.d.ts.map +1 -0
@@ -0,0 +1,992 @@
1
+ import './extension/IAgoraRtcEngineExExtension';
2
+ import {
3
+ ChannelMediaRelayConfiguration,
4
+ ConnectionStateType,
5
+ DataStreamConfig,
6
+ EncryptionConfig,
7
+ LiveTranscoding,
8
+ SimulcastConfig,
9
+ SimulcastStreamConfig,
10
+ SimulcastStreamMode,
11
+ SpatialAudioParams,
12
+ UserInfo,
13
+ VideoCanvas,
14
+ VideoEncoderConfiguration,
15
+ VideoMirrorModeType,
16
+ VideoStreamType,
17
+ VideoSubscriptionOptions,
18
+ WatermarkOptions,
19
+ } from './AgoraBase';
20
+ import {
21
+ ContentInspectConfig,
22
+ RenderModeType,
23
+ SnapshotConfig,
24
+ } from './AgoraMediaBase';
25
+ import {
26
+ ChannelMediaOptions,
27
+ IRtcEngine,
28
+ LeaveChannelOptions,
29
+ StreamFallbackOptions,
30
+ } from './IAgoraRtcEngine';
31
+
32
+ /**
33
+ * Contains connection information.
34
+ */
35
+ export class RtcConnection {
36
+ /**
37
+ * The channel name.
38
+ */
39
+ channelId?: string;
40
+ /**
41
+ * The ID of the local user.
42
+ */
43
+ localUid?: number;
44
+ }
45
+
46
+ /**
47
+ * This interface class contains multi-channel methods.
48
+ *
49
+ * Inherited from IRtcEngine.
50
+ */
51
+ export abstract class IRtcEngineEx extends IRtcEngine {
52
+ /**
53
+ * Joins a channel.
54
+ *
55
+ * You can call this method multiple times to join more than one channel. If you want to join the same channel from different devices, ensure that the user IDs are different for all devices.
56
+ *
57
+ * @param token The token generated on your server for authentication.
58
+ * (Recommended) If your project has enabled the security mode (using APP ID and Token for authentication), this parameter is required.
59
+ * If you have only enabled the testing mode (using APP ID for authentication), this parameter is optional. You will automatically exit the channel 24 hours after successfully joining in.
60
+ * If you need to join different channels at the same time or switch between channels, Agora recommends using a wildcard token so that you don't need to apply for a new token every time joining a channel.
61
+ * @param connection The connection information. See RtcConnection.
62
+ * @param options The channel media options. See ChannelMediaOptions.
63
+ *
64
+ * @returns
65
+ * 0: Success.
66
+ * < 0: Failure.
67
+ * -2: The parameter is invalid. For example, the token is invalid, the uid parameter is not set to an integer, or the value of a member in ChannelMediaOptions is invalid. You need to pass in a valid parameter and join the channel again.
68
+ * -3: Fails to initialize the IRtcEngine object. You need to reinitialize the IRtcEngine object.
69
+ * -7: The IRtcEngine object has not been initialized. You need to initialize the IRtcEngine object before calling this method.
70
+ * -8: The internal state of the IRtcEngine object is wrong. The typical cause is that after calling startEchoTest to start a call loop test, you call this method to join the channel without calling stopEchoTest to stop the test. You need to call stopEchoTest before calling this method.
71
+ * -17: The request to join the channel is rejected. The typical cause is that the user is already in the channel. Agora recommends that you use the onConnectionStateChanged callback to see whether the user is in the channel. Do not call this method to join the channel unless you receive the ConnectionStateDisconnected (1) state.
72
+ * -102: The channel name is invalid. You need to pass in a valid channel name in channelId to rejoin the channel.
73
+ * -121: The user ID is invalid. You need to pass in a valid user ID in uid to rejoin the channel.
74
+ */
75
+ abstract joinChannelEx(
76
+ token: string,
77
+ connection: RtcConnection,
78
+ options: ChannelMediaOptions
79
+ ): number;
80
+
81
+ /**
82
+ * Sets channel options and leaves the channel.
83
+ *
84
+ * After calling this method, the SDK terminates the audio and video interaction, leaves the current channel, and releases all resources related to the session. After calling joinChannelEx to join a channel, you must call this method to end the call, otherwise, the next call cannot be started.
85
+ * This method call is asynchronous. When this method returns, it does not necessarily mean that the user has left the channel.
86
+ * If you call leaveChannel, you will leave all the channels you have joined by calling joinChannel or joinChannelEx.
87
+ *
88
+ * @param connection The connection information. See RtcConnection.
89
+ * @param options The options for leaving the channel. See LeaveChannelOptions. This parameter only supports the stopMicrophoneRecording member in the LeaveChannelOptions settings; setting other members does not take effect.
90
+ *
91
+ * @returns
92
+ * 0: Success.
93
+ * < 0: Failure.
94
+ */
95
+ abstract leaveChannelEx(
96
+ connection: RtcConnection,
97
+ options?: LeaveChannelOptions
98
+ ): number;
99
+
100
+ /**
101
+ * @ignore
102
+ */
103
+ abstract leaveChannelWithUserAccountEx(
104
+ channelId: string,
105
+ userAccount: string,
106
+ options?: LeaveChannelOptions
107
+ ): number;
108
+
109
+ /**
110
+ * Updates the channel media options after joining the channel.
111
+ *
112
+ * @param options The channel media options. See ChannelMediaOptions.
113
+ * @param connection The connection information. See RtcConnection.
114
+ *
115
+ * @returns
116
+ * 0: Success.
117
+ * < 0: Failure.
118
+ * -2: The value of a member in ChannelMediaOptions is invalid. For example, the token or the user ID is invalid. You need to fill in a valid parameter.
119
+ * -7: The IRtcEngine object has not been initialized. You need to initialize the IRtcEngine object before calling this method.
120
+ * -8: The internal state of the IRtcEngine object is wrong. The possible reason is that the user is not in the channel. Agora recommends that you use the onConnectionStateChanged callback to see whether the user is in the channel. If you receive the ConnectionStateDisconnected (1) or ConnectionStateFailed (5) state, the user is not in the channel. You need to call joinChannel to join a channel before calling this method.
121
+ */
122
+ abstract updateChannelMediaOptionsEx(
123
+ options: ChannelMediaOptions,
124
+ connection: RtcConnection
125
+ ): number;
126
+
127
+ /**
128
+ * Sets the video encoder configuration.
129
+ *
130
+ * Sets the encoder configuration for the local video. Each configuration profile corresponds to a set of video parameters, including the resolution, frame rate, and bitrate.
131
+ *
132
+ * @param config Video profile. See VideoEncoderConfiguration.
133
+ * @param connection The connection information. See RtcConnection.
134
+ *
135
+ * @returns
136
+ * 0: Success.
137
+ * < 0: Failure.
138
+ */
139
+ abstract setVideoEncoderConfigurationEx(
140
+ config: VideoEncoderConfiguration,
141
+ connection: RtcConnection
142
+ ): number;
143
+
144
+ /**
145
+ * Initializes the video view of a remote user.
146
+ *
147
+ * This method initializes the video view of a remote stream on the local device. It affects only the video view that the local user sees. Call this method to bind the remote video stream to a video view and to set the rendering and mirror modes of the video view. The application specifies the uid of the remote video in the VideoCanvas method before the remote user joins the channel. If the remote uid is unknown to the application, set it after the application receives the onUserJoined callback. If the Video Recording function is enabled, the Video Recording Service joins the channel as a dummy client, causing other clients to also receive the onUserJoined callback. Do not bind the dummy client to the application view because the dummy client does not send any video streams. To unbind the remote user from the view, set the view parameter to NULL. Once the remote user leaves the channel, the SDK unbinds the remote user.
148
+ * Call this method after joinChannelEx.
149
+ * To update the rendering or mirror mode of the remote video view during a call, use the setRemoteRenderModeEx method.
150
+ *
151
+ * @param canvas The remote video view settings. See VideoCanvas.
152
+ * @param connection The connection information. See RtcConnection.
153
+ *
154
+ * @returns
155
+ * 0: Success.
156
+ * < 0: Failure.
157
+ */
158
+ abstract setupRemoteVideoEx(
159
+ canvas: VideoCanvas,
160
+ connection: RtcConnection
161
+ ): number;
162
+
163
+ /**
164
+ * Stops or resumes receiving the audio stream of a specified user.
165
+ *
166
+ * @param uid The ID of the specified user.
167
+ * @param mute Whether to stop receiving the audio stream of the specified user: true : Stop receiving the audio stream of the specified user. false : (Default) Resume receiving the audio stream of the specified user.
168
+ * @param connection The connection information. See RtcConnection.
169
+ *
170
+ * @returns
171
+ * 0: Success.
172
+ * < 0: Failure.
173
+ */
174
+ abstract muteRemoteAudioStreamEx(
175
+ uid: number,
176
+ mute: boolean,
177
+ connection: RtcConnection
178
+ ): number;
179
+
180
+ /**
181
+ * Stops or resumes receiving the video stream of a specified user.
182
+ *
183
+ * This method is used to stop or resume receiving the video stream of a specified user. You can call this method before or after joining a channel. If a user leaves a channel, the settings in this method become invalid.
184
+ *
185
+ * @param uid The user ID of the remote user.
186
+ * @param mute Whether to stop receiving the video stream of the specified user: true : Stop receiving the video stream of the specified user. false : (Default) Resume receiving the video stream of the specified user.
187
+ * @param connection The connection information. See RtcConnection.
188
+ *
189
+ * @returns
190
+ * 0: Success.
191
+ * < 0: Failure.
192
+ */
193
+ abstract muteRemoteVideoStreamEx(
194
+ uid: number,
195
+ mute: boolean,
196
+ connection: RtcConnection
197
+ ): number;
198
+
199
+ /**
200
+ * Sets the video stream type to subscribe to.
201
+ *
202
+ * The SDK will dynamically adjust the size of the corresponding video stream based on the size of the video window to save bandwidth and computing resources. The default aspect ratio of the low-quality video stream is the same as that of the high-quality video stream. According to the current aspect ratio of the high-quality video stream, the system will automatically allocate the resolution, frame rate, and bitrate of the low-quality video stream. Depending on the default behavior of the sender and the specific settings when calling setDualStreamMode, the scenarios for the receiver calling this method are as follows:
203
+ * The SDK enables low-quality video stream adaptive mode (AutoSimulcastStream) on the sender side by default, meaning only the high-quality video stream is transmitted. Only the receiver with the role of the host can call this method to initiate a low-quality video stream request. Once the sender receives the request, it starts automatically sending the low-quality video stream. At this point, all users in the channel can call this method to switch to low-quality video stream subscription mode.
204
+ * If the sender calls setDualStreamMode and sets mode to DisableSimulcastStream (never send low-quality video stream), then calling this method will have no effect.
205
+ * If the sender calls setDualStreamMode and sets mode to EnableSimulcastStream (always send low-quality video stream), both the host and audience receivers can call this method to switch to low-quality video stream subscription mode.
206
+ * If the publisher has already called setDualStreamModeEx and set mode to DisableSimulcastStream (never send low-quality video stream), calling this method will not take effect, you should call setDualStreamModeEx again on the sending end and adjust the settings.
207
+ * Calling this method on the receiving end of the audience role will not take effect.
208
+ *
209
+ * @param uid The user ID.
210
+ * @param streamType The video stream type, see VideoStreamType.
211
+ * @param connection The connection information. See RtcConnection.
212
+ *
213
+ * @returns
214
+ * 0: Success.
215
+ * < 0: Failure.
216
+ */
217
+ abstract setRemoteVideoStreamTypeEx(
218
+ uid: number,
219
+ streamType: VideoStreamType,
220
+ connection: RtcConnection
221
+ ): number;
222
+
223
+ /**
224
+ * Stops or resumes publishing the local audio stream.
225
+ *
226
+ * This method does not affect any ongoing audio recording, because it does not disable the audio capture device. A successful call of this method triggers the onUserMuteAudio and onRemoteAudioStateChanged callbacks on the remote client.
227
+ *
228
+ * @param mute Whether to stop publishing the local audio stream: true : Stops publishing the local audio stream. false : (Default) Resumes publishing the local audio stream.
229
+ * @param connection The connection information. See RtcConnection.
230
+ *
231
+ * @returns
232
+ * 0: Success.
233
+ * < 0: Failure.
234
+ */
235
+ abstract muteLocalAudioStreamEx(
236
+ mute: boolean,
237
+ connection: RtcConnection
238
+ ): number;
239
+
240
+ /**
241
+ * Stops or resumes publishing the local video stream.
242
+ *
243
+ * A successful call of this method triggers the onUserMuteVideo callback on the remote client.
244
+ * This method does not affect any ongoing video recording, because it does not disable the camera.
245
+ *
246
+ * @param mute Whether to stop publishing the local video stream. true : Stop publishing the local video stream. false : (Default) Publish the local video stream.
247
+ * @param connection The connection information. See RtcConnection.
248
+ *
249
+ * @returns
250
+ * 0: Success.
251
+ * < 0: Failure.
252
+ */
253
+ abstract muteLocalVideoStreamEx(
254
+ mute: boolean,
255
+ connection: RtcConnection
256
+ ): number;
257
+
258
+ /**
259
+ * Stops or resumes subscribing to the audio streams of all remote users.
260
+ *
261
+ * After successfully calling this method, the local user stops or resumes subscribing to the audio streams of all remote users, including the ones join the channel subsequent to this call.
262
+ * Call this method after joining a channel.
263
+ * If you do not want to subscribe the audio streams of remote users before joining a channel, you can set autoSubscribeAudio as false when calling joinChannel.
264
+ *
265
+ * @param mute Whether to stop subscribing to the audio streams of all remote users: true : Stops subscribing to the audio streams of all remote users. false : (Default) Subscribes to the audio streams of all remote users by default.
266
+ * @param connection The connection information. See RtcConnection.
267
+ *
268
+ * @returns
269
+ * 0: Success.
270
+ * < 0: Failure.
271
+ */
272
+ abstract muteAllRemoteAudioStreamsEx(
273
+ mute: boolean,
274
+ connection: RtcConnection
275
+ ): number;
276
+
277
+ /**
278
+ * Stops or resumes subscribing to the video streams of all remote users.
279
+ *
280
+ * After successfully calling this method, the local user stops or resumes subscribing to the video streams of all remote users, including all subsequent users.
281
+ *
282
+ * @param mute Whether to stop subscribing to the video streams of all remote users. true : Stop subscribing to the video streams of all remote users. false : (Default) Subscribe to the video streams of all remote users by default.
283
+ * @param connection The connection information. See RtcConnection.
284
+ *
285
+ * @returns
286
+ * 0: Success.
287
+ * < 0: Failure.
288
+ */
289
+ abstract muteAllRemoteVideoStreamsEx(
290
+ mute: boolean,
291
+ connection: RtcConnection
292
+ ): number;
293
+
294
+ /**
295
+ * Set the blocklist of subscriptions for audio streams.
296
+ *
297
+ * You can call this method to specify the audio streams of a user that you do not want to subscribe to.
298
+ * You can call this method either before or after joining a channel.
299
+ * The blocklist is not affected by the setting in muteRemoteAudioStream, muteAllRemoteAudioStreams, and autoSubscribeAudio in ChannelMediaOptions.
300
+ * Once the blocklist of subscriptions is set, it is effective even if you leave the current channel and rejoin the channel.
301
+ * If a user is added in the allowlist and blocklist at the same time, only the blocklist takes effect.
302
+ *
303
+ * @param uidList The user ID list of users that you do not want to subscribe to. If you want to specify the audio streams of a user that you do not want to subscribe to, add the user ID in this list. If you want to remove a user from the blocklist, you need to call the setSubscribeAudioBlocklist method to update the user ID list; this means you only add the uid of users that you do not want to subscribe to in the new user ID list.
304
+ * @param uidNumber The number of users in the user ID list.
305
+ * @param connection The connection information. See RtcConnection.
306
+ *
307
+ * @returns
308
+ * 0: Success.
309
+ * < 0: Failure.
310
+ */
311
+ abstract setSubscribeAudioBlocklistEx(
312
+ uidList: number[],
313
+ uidNumber: number,
314
+ connection: RtcConnection
315
+ ): number;
316
+
317
+ /**
318
+ * Sets the allowlist of subscriptions for audio streams.
319
+ *
320
+ * You can call this method to specify the audio streams of a user that you want to subscribe to.
321
+ * If a user is added in the allowlist and blocklist at the same time, only the blocklist takes effect.
322
+ * You can call this method either before or after joining a channel.
323
+ * The allowlist is not affected by the setting in muteRemoteAudioStream, muteAllRemoteAudioStreams and autoSubscribeAudio in ChannelMediaOptions.
324
+ * Once the allowlist of subscriptions is set, it is effective even if you leave the current channel and rejoin the channel.
325
+ *
326
+ * @param uidList The user ID list of users that you want to subscribe to. If you want to specify the audio streams of a user for subscription, add the user ID in this list. If you want to remove a user from the allowlist, you need to call the setSubscribeAudioAllowlist method to update the user ID list; this means you only add the uid of users that you want to subscribe to in the new user ID list.
327
+ * @param uidNumber The number of users in the user ID list.
328
+ * @param connection The connection information. See RtcConnection.
329
+ *
330
+ * @returns
331
+ * 0: Success.
332
+ * < 0: Failure.
333
+ */
334
+ abstract setSubscribeAudioAllowlistEx(
335
+ uidList: number[],
336
+ uidNumber: number,
337
+ connection: RtcConnection
338
+ ): number;
339
+
340
+ /**
341
+ * Set the blocklist of subscriptions for video streams.
342
+ *
343
+ * You can call this method to specify the video streams of a user that you do not want to subscribe to.
344
+ * If a user is added in the allowlist and blocklist at the same time, only the blocklist takes effect.
345
+ * Once the blocklist of subscriptions is set, it is effective even if you leave the current channel and rejoin the channel.
346
+ * You can call this method either before or after joining a channel.
347
+ * The blocklist is not affected by the setting in muteRemoteVideoStream, muteAllRemoteVideoStreams and autoSubscribeAudio in ChannelMediaOptions.
348
+ *
349
+ * @param uidList The user ID list of users that you do not want to subscribe to. If you want to specify the video streams of a user that you do not want to subscribe to, add the user ID of that user in this list. If you want to remove a user from the blocklist, you need to call the setSubscribeVideoBlocklist method to update the user ID list; this means you only add the uid of users that you do not want to subscribe to in the new user ID list.
350
+ * @param uidNumber The number of users in the user ID list.
351
+ * @param connection The connection information. See RtcConnection.
352
+ *
353
+ * @returns
354
+ * 0: Success.
355
+ * < 0: Failure.
356
+ */
357
+ abstract setSubscribeVideoBlocklistEx(
358
+ uidList: number[],
359
+ uidNumber: number,
360
+ connection: RtcConnection
361
+ ): number;
362
+
363
+ /**
364
+ * Set the allowlist of subscriptions for video streams.
365
+ *
366
+ * You can call this method to specify the video streams of a user that you want to subscribe to.
367
+ * If a user is added in the allowlist and blocklist at the same time, only the blocklist takes effect.
368
+ * Once the allowlist of subscriptions is set, it is effective even if you leave the current channel and rejoin the channel.
369
+ * You can call this method either before or after joining a channel.
370
+ * The allowlist is not affected by the setting in muteRemoteVideoStream, muteAllRemoteVideoStreams and autoSubscribeAudio in ChannelMediaOptions.
371
+ *
372
+ * @param uidList The user ID list of users that you want to subscribe to. If you want to specify the video streams of a user for subscription, add the user ID of that user in this list. If you want to remove a user from the allowlist, you need to call the setSubscribeVideoAllowlist method to update the user ID list; this means you only add the uid of users that you want to subscribe to in the new user ID list.
373
+ * @param uidNumber The number of users in the user ID list.
374
+ * @param connection The connection information. See RtcConnection.
375
+ *
376
+ * @returns
377
+ * 0: Success.
378
+ * < 0: Failure.
379
+ */
380
+ abstract setSubscribeVideoAllowlistEx(
381
+ uidList: number[],
382
+ uidNumber: number,
383
+ connection: RtcConnection
384
+ ): number;
385
+
386
+ /**
387
+ * Options for subscribing to remote video streams.
388
+ *
389
+ * When a remote user has enabled dual-stream mode, you can call this method to choose the option for subscribing to the video streams sent by the remote user.
390
+ *
391
+ * @param uid The user ID of the remote user.
392
+ * @param options The video subscription options. See VideoSubscriptionOptions.
393
+ * @param connection The connection information. See RtcConnection.
394
+ *
395
+ * @returns
396
+ * 0: Success.
397
+ * < 0: Failure.
398
+ */
399
+ abstract setRemoteVideoSubscriptionOptionsEx(
400
+ uid: number,
401
+ options: VideoSubscriptionOptions,
402
+ connection: RtcConnection
403
+ ): number;
404
+
405
+ /**
406
+ * Sets the 2D position (the position on the horizontal plane) of the remote user's voice.
407
+ *
408
+ * This method sets the voice position and volume of a remote user. When the local user calls this method to set the voice position of a remote user, the voice difference between the left and right channels allows the local user to track the real-time position of the remote user, creating a sense of space. This method applies to massive multiplayer online games, such as Battle Royale games.
409
+ * For the best voice positioning, Agora recommends using a wired headset.
410
+ * Call this method after joining a channel.
411
+ *
412
+ * @param uid The user ID of the remote user.
413
+ * @param pan The voice position of the remote user. The value ranges from -1.0 to 1.0:
414
+ * -1.0: The remote voice comes from the left.
415
+ * 0.0: (Default) The remote voice comes from the front.
416
+ * 1.0: The remote voice comes from the right.
417
+ * @param gain The volume of the remote user. The value ranges from 0.0 to 100.0. The default value is 100.0 (the original volume of the remote user). The smaller the value, the lower the volume.
418
+ * @param connection The connection information. See RtcConnection.
419
+ *
420
+ * @returns
421
+ * 0: Success.
422
+ * < 0: Failure.
423
+ */
424
+ abstract setRemoteVoicePositionEx(
425
+ uid: number,
426
+ pan: number,
427
+ gain: number,
428
+ connection: RtcConnection
429
+ ): number;
430
+
431
+ /**
432
+ * @ignore
433
+ */
434
+ abstract setRemoteUserSpatialAudioParamsEx(
435
+ uid: number,
436
+ params: SpatialAudioParams,
437
+ connection: RtcConnection
438
+ ): number;
439
+
440
+ /**
441
+ * Sets the video display mode of a specified remote user.
442
+ *
443
+ * After initializing the video view of a remote user, you can call this method to update its rendering and mirror modes. This method affects only the video view that the local user sees.
444
+ * Call this method after initializing the remote view by calling the setupRemoteVideo method.
445
+ * During a call, you can call this method as many times as necessary to update the display mode of the video view of a remote user.
446
+ *
447
+ * @param uid The user ID of the remote user.
448
+ * @param renderMode The video display mode of the remote user. See RenderModeType.
449
+ * @param mirrorMode The mirror mode of the remote user view. See VideoMirrorModeType.
450
+ * @param connection The connection information. See RtcConnection.
451
+ *
452
+ * @returns
453
+ * 0: Success.
454
+ * < 0: Failure.
455
+ */
456
+ abstract setRemoteRenderModeEx(
457
+ uid: number,
458
+ renderMode: RenderModeType,
459
+ mirrorMode: VideoMirrorModeType,
460
+ connection: RtcConnection
461
+ ): number;
462
+
463
+ /**
464
+ * Enables loopback audio capturing.
465
+ *
466
+ * If you enable loopback audio capturing, the output of the sound card is mixed into the audio stream sent to the other end.
467
+ * macOS does not support loopback audio capture of the default sound card. If you need to use this function, use a virtual sound card and pass its name to the deviceName parameter. Agora recommends using AgoraALD as the virtual sound card for audio capturing.
468
+ * This method only supports using one sound card for audio capturing.
469
+ *
470
+ * @param connection The connection information. See RtcConnection.
471
+ * @param enabled Sets whether to enable loopback audio capture: true : Enable loopback audio capturing. false : (Default) Disable loopback audio capturing.
472
+ * @param deviceName macOS: The device name of the virtual sound card. The default value is set to NULL, which means using AgoraALD for loopback audio capturing.
473
+ * Windows: The device name of the sound card. The default is set to NULL, which means the SDK uses the sound card of your device for loopback audio capturing.
474
+ *
475
+ * @returns
476
+ * 0: Success.
477
+ * < 0: Failure.
478
+ */
479
+ abstract enableLoopbackRecordingEx(
480
+ connection: RtcConnection,
481
+ enabled: boolean,
482
+ deviceName?: string
483
+ ): number;
484
+
485
+ /**
486
+ * @ignore
487
+ */
488
+ abstract adjustRecordingSignalVolumeEx(
489
+ volume: number,
490
+ connection: RtcConnection
491
+ ): number;
492
+
493
+ /**
494
+ * @ignore
495
+ */
496
+ abstract muteRecordingSignalEx(
497
+ mute: boolean,
498
+ connection: RtcConnection
499
+ ): number;
500
+
501
+ /**
502
+ * Adjusts the playback signal volume of a specified remote user.
503
+ *
504
+ * You can call this method to adjust the playback volume of a specified remote user. To adjust the playback volume of different remote users, call the method as many times, once for each remote user.
505
+ *
506
+ * @param uid The user ID of the remote user.
507
+ * @param volume The volume of the user. The value range is [0,400].
508
+ * 0: Mute.
509
+ * 100: (Default) The original volume.
510
+ * 400: Four times the original volume (amplifying the audio signals by four times).
511
+ * @param connection The connection information. See RtcConnection.
512
+ *
513
+ * @returns
514
+ * 0: Success.
515
+ * < 0: Failure.
516
+ */
517
+ abstract adjustUserPlaybackSignalVolumeEx(
518
+ uid: number,
519
+ volume: number,
520
+ connection: RtcConnection
521
+ ): number;
522
+
523
+ /**
524
+ * Gets the current connection state of the SDK.
525
+ *
526
+ * @param connection The connection information. See RtcConnection.
527
+ *
528
+ * @returns
529
+ * The current connection state. See ConnectionStateType.
530
+ */
531
+ abstract getConnectionStateEx(connection: RtcConnection): ConnectionStateType;
532
+
533
+ /**
534
+ * Enables or disables the built-in encryption.
535
+ *
536
+ * After the user leaves the channel, the SDK automatically disables the built-in encryption. To enable the built-in encryption, call this method before the user joins the channel again.
537
+ *
538
+ * @param connection The connection information. See RtcConnection.
539
+ * @param enabled Whether to enable built-in encryption: true : Enable the built-in encryption. false : (Default) Disable the built-in encryption.
540
+ * @param config Built-in encryption configurations. See EncryptionConfig.
541
+ *
542
+ * @returns
543
+ * 0: Success.
544
+ * < 0: Failure.
545
+ */
546
+ abstract enableEncryptionEx(
547
+ connection: RtcConnection,
548
+ enabled: boolean,
549
+ config: EncryptionConfig
550
+ ): number;
551
+
552
+ /**
553
+ * Creates a data stream.
554
+ *
555
+ * @param config The configurations for the data stream. See DataStreamConfig.
556
+ * @param connection The connection information. See RtcConnection.
557
+ *
558
+ * @returns
559
+ * ID of the created data stream, if the method call succeeds.
560
+ * < 0: Failure.
561
+ */
562
+ abstract createDataStreamEx(
563
+ config: DataStreamConfig,
564
+ connection: RtcConnection
565
+ ): number;
566
+
567
+ /**
568
+ * Sends data stream messages.
569
+ *
570
+ * A successful method call triggers the onStreamMessage callback on the remote client, from which the remote user gets the stream message. A failed method call triggers the onStreamMessageError callback on the remote client. The SDK has the following restrictions on this method:
571
+ * Each client within the channel can have up to 5 data channels simultaneously, with a total shared packet bitrate limit of 30 KB/s for all data channels.
572
+ * Each data channel can send up to 60 packets per second, with each packet being a maximum of 1 KB. After calling createDataStreamEx, you can call this method to send data stream messages to all users in the channel.
573
+ * Call this method after joinChannelEx.
574
+ * Ensure that you call createDataStreamEx to create a data channel before calling this method.
575
+ * This method applies only to the COMMUNICATION profile or to the hosts in the LIVE_BROADCASTING profile. If an audience in the LIVE_BROADCASTING profile calls this method, the audience may be switched to a host.
576
+ *
577
+ * @param streamId The data stream ID. You can get the data stream ID by calling createDataStreamEx.
578
+ * @param data The message to be sent.
579
+ * @param length The length of the data.
580
+ * @param connection The connection information. See RtcConnection.
581
+ *
582
+ * @returns
583
+ * 0: Success.
584
+ * < 0: Failure.
585
+ */
586
+ abstract sendStreamMessageEx(
587
+ streamId: number,
588
+ data: Uint8Array,
589
+ length: number,
590
+ connection: RtcConnection
591
+ ): number;
592
+
593
+ /**
594
+ * Adds a watermark image to the local video.
595
+ *
596
+ * This method adds a PNG watermark image to the local video in the live streaming. Once the watermark image is added, all the audience in the channel (CDN audience included), and the capturing device can see and capture it. The Agora SDK supports adding only one watermark image onto a local video or CDN live stream. The newly added watermark image replaces the previous one. The watermark coordinates are dependent on the settings in the setVideoEncoderConfigurationEx method:
597
+ * If the orientation mode of the encoding video (OrientationMode) is fixed landscape mode or the adaptive landscape mode, the watermark uses the landscape orientation.
598
+ * If the orientation mode of the encoding video (OrientationMode) is fixed portrait mode or the adaptive portrait mode, the watermark uses the portrait orientation.
599
+ * When setting the watermark position, the region must be less than the dimensions set in the setVideoEncoderConfigurationEx method; otherwise, the watermark image will be cropped.
600
+ * Ensure that you have called enableVideo before calling this method.
601
+ * This method supports adding a watermark image in the PNG file format only. Supported pixel formats of the PNG image are RGBA, RGB, Palette, Gray, and Alpha_gray.
602
+ * If the dimensions of the PNG image differ from your settings in this method, the image will be cropped or zoomed to conform to your settings.
603
+ * If you have enabled the local video preview by calling the startPreview method, you can use the visibleInPreview member to set whether or not the watermark is visible in the preview.
604
+ * If you have enabled the mirror mode for the local video, the watermark on the local video is also mirrored. To avoid mirroring the watermark, Agora recommends that you do not use the mirror and watermark functions for the local video at the same time. You can implement the watermark function in your application layer.
605
+ *
606
+ * @param watermarkUrl The local file path of the watermark image to be added. This method supports adding a watermark image from the local absolute or relative file path.
607
+ * @param options The options of the watermark image to be added. See WatermarkOptions.
608
+ * @param connection The connection information. See RtcConnection.
609
+ *
610
+ * @returns
611
+ * 0: Success.
612
+ * < 0: Failure.
613
+ */
614
+ abstract addVideoWatermarkEx(
615
+ watermarkUrl: string,
616
+ options: WatermarkOptions,
617
+ connection: RtcConnection
618
+ ): number;
619
+
620
+ /**
621
+ * Removes the watermark image from the video stream.
622
+ *
623
+ * @param connection The connection information. See RtcConnection.
624
+ *
625
+ * @returns
626
+ * 0: Success.
627
+ * < 0: Failure.
628
+ */
629
+ abstract clearVideoWatermarkEx(connection: RtcConnection): number;
630
+
631
+ /**
632
+ * Agora supports reporting and analyzing customized messages.
633
+ *
634
+ * Agora supports reporting and analyzing customized messages. This function is in the beta stage with a free trial. The ability provided in its beta test version is reporting a maximum of 10 message pieces within 6 seconds, with each message piece not exceeding 256 bytes and each string not exceeding 100 bytes. To try out this function, contact and discuss the format of customized messages with us.
635
+ */
636
+ abstract sendCustomReportMessageEx(
637
+ id: string,
638
+ category: string,
639
+ event: string,
640
+ label: string,
641
+ value: number,
642
+ connection: RtcConnection
643
+ ): number;
644
+
645
+ /**
646
+ * Enables the reporting of users' volume indication.
647
+ *
648
+ * This method enables the SDK to regularly report the volume information to the app of the local user who sends a stream and remote users (three users at most) whose instantaneous volumes are the highest.
649
+ *
650
+ * @param interval Sets the time interval between two consecutive volume indications:
651
+ * ≤ 0: Disables the volume indication.
652
+ * > 0: Time interval (ms) between two consecutive volume indications. Ensure this parameter is set to a value greater than 10, otherwise you will not receive the onAudioVolumeIndication callback. Agora recommends that this value is set as greater than 100.
653
+ * @param smooth The smoothing factor that sets the sensitivity of the audio volume indicator. The value ranges between 0 and 10. The recommended value is 3. The greater the value, the more sensitive the indicator.
654
+ * @param reportVad true : Enables the voice activity detection of the local user. Once it is enabled, the vad parameter of the onAudioVolumeIndication callback reports the voice activity status of the local user. false : (Default) Disables the voice activity detection of the local user. Once it is disabled, the vad parameter of the onAudioVolumeIndication callback does not report the voice activity status of the local user, except for the scenario where the engine automatically detects the voice activity of the local user.
655
+ * @param connection The connection information. See RtcConnection.
656
+ *
657
+ * @returns
658
+ * 0: Success.
659
+ * < 0: Failure.
660
+ */
661
+ abstract enableAudioVolumeIndicationEx(
662
+ interval: number,
663
+ smooth: number,
664
+ reportVad: boolean,
665
+ connection: RtcConnection
666
+ ): number;
667
+
668
+ /**
669
+ * Starts pushing media streams to a CDN without transcoding.
670
+ *
671
+ * Call this method after joining a channel.
672
+ * Only hosts in the LIVE_BROADCASTING profile can call this method.
673
+ * If you want to retry pushing streams after a failed push, make sure to call stopRtmpStream first, then call this method to retry pushing streams; otherwise, the SDK returns the same error code as the last failed push. Agora recommends that you use the server-side Media Push function. You can call this method to push an audio or video stream to the specified CDN address. This method can push media streams to only one CDN address at a time, so if you need to push streams to multiple addresses, call this method multiple times. After you call this method, the SDK triggers the onRtmpStreamingStateChanged callback on the local client to report the state of the streaming.
674
+ *
675
+ * @param url The address of Media Push. The format is RTMP or RTMPS. The character length cannot exceed 1024 bytes. Special characters such as Chinese characters are not supported.
676
+ * @param connection The connection information. See RtcConnection.
677
+ *
678
+ * @returns
679
+ * 0: Success.
680
+ * < 0: Failure.
681
+ * -2: The URL or configuration of transcoding is invalid; check your URL and transcoding configurations.
682
+ * -7: The SDK is not initialized before calling this method.
683
+ * -19: The Media Push URL is already in use; use another URL instead.
684
+ */
685
+ abstract startRtmpStreamWithoutTranscodingEx(
686
+ url: string,
687
+ connection: RtcConnection
688
+ ): number;
689
+
690
+ /**
691
+ * Starts Media Push and sets the transcoding configuration.
692
+ *
693
+ * Agora recommends that you use the server-side Media Push function. You can call this method to push a live audio-and-video stream to the specified CDN address and set the transcoding configuration. This method can push media streams to only one CDN address at a time, so if you need to push streams to multiple addresses, call this method multiple times. After you call this method, the SDK triggers the onRtmpStreamingStateChanged callback on the local client to report the state of the streaming.
694
+ * Ensure that you enable the Media Push service before using this function.
695
+ * Call this method after joining a channel.
696
+ * Only hosts in the LIVE_BROADCASTING profile can call this method.
697
+ * If you want to retry pushing streams after a failed push, make sure to call stopRtmpStreamEx first, then call this method to retry pushing streams; otherwise, the SDK returns the same error code as the last failed push.
698
+ *
699
+ * @param url The address of Media Push. The format is RTMP or RTMPS. The character length cannot exceed 1024 bytes. Special characters such as Chinese characters are not supported.
700
+ * @param transcoding The transcoding configuration for Media Push. See LiveTranscoding.
701
+ * @param connection The connection information. See RtcConnection.
702
+ *
703
+ * @returns
704
+ * 0: Success.
705
+ * < 0: Failure.
706
+ * -2: The URL or configuration of transcoding is invalid; check your URL and transcoding configurations.
707
+ * -7: The SDK is not initialized before calling this method.
708
+ * -19: The Media Push URL is already in use; use another URL instead.
709
+ */
710
+ abstract startRtmpStreamWithTranscodingEx(
711
+ url: string,
712
+ transcoding: LiveTranscoding,
713
+ connection: RtcConnection
714
+ ): number;
715
+
716
+ /**
717
+ * Updates the transcoding configuration.
718
+ *
719
+ * Agora recommends that you use the server-side Media Push function. After you start pushing media streams to CDN with transcoding, you can dynamically update the transcoding configuration according to the scenario. The SDK triggers the onTranscodingUpdated callback after the transcoding configuration is updated.
720
+ *
721
+ * @param transcoding The transcoding configuration for Media Push. See LiveTranscoding.
722
+ * @param connection The connection information. See RtcConnection.
723
+ *
724
+ * @returns
725
+ * 0: Success.
726
+ * < 0: Failure.
727
+ */
728
+ abstract updateRtmpTranscodingEx(
729
+ transcoding: LiveTranscoding,
730
+ connection: RtcConnection
731
+ ): number;
732
+
733
+ /**
734
+ * Stops pushing media streams to a CDN.
735
+ *
736
+ * Agora recommends that you use the server-side Media Push function. You can call this method to stop the live stream on the specified CDN address. This method can stop pushing media streams to only one CDN address at a time, so if you need to stop pushing streams to multiple addresses, call this method multiple times. After you call this method, the SDK triggers the onRtmpStreamingStateChanged callback on the local client to report the state of the streaming.
737
+ *
738
+ * @param url The address of Media Push. The format is RTMP or RTMPS. The character length cannot exceed 1024 bytes. Special characters such as Chinese characters are not supported.
739
+ *
740
+ * @returns
741
+ * 0: Success.
742
+ * < 0: Failure.
743
+ */
744
+ abstract stopRtmpStreamEx(url: string, connection: RtcConnection): number;
745
+
746
+ /**
747
+ * Starts relaying media streams across channels or updates channels for media relay.
748
+ *
749
+ * The first successful call to this method starts relaying media streams from the source channel to the destination channels. To relay the media stream to other channels, or exit one of the current media relays, you can call this method again to update the destination channels. This feature supports relaying media streams to a maximum of six destination channels. After a successful method call, the SDK triggers the onChannelMediaRelayStateChanged callback, and this callback returns the state of the media stream relay. Common states are as follows:
750
+ * If the onChannelMediaRelayStateChanged callback returns RelayStateRunning (2) and RelayOk (0), it means that the SDK starts relaying media streams from the source channel to the destination channel.
751
+ * If the onChannelMediaRelayStateChanged callback returns RelayStateFailure (3), an exception occurs during the media stream relay.
752
+ * Call this method after joining the channel.
753
+ * This method takes effect only when you are a host in a live streaming channel.
754
+ * The relaying media streams across channels function needs to be enabled by contacting.
755
+ * Agora does not support string user accounts in this API.
756
+ *
757
+ * @param configuration The configuration of the media stream relay. See ChannelMediaRelayConfiguration.
758
+ * @param connection The connection information. See RtcConnection.
759
+ *
760
+ * @returns
761
+ * 0: Success.
762
+ * < 0: Failure.
763
+ * -1: A general error occurs (no specified reason).
764
+ * -2: The parameter is invalid.
765
+ * -8: Internal state error. Probably because the user is not a broadcaster.
766
+ */
767
+ abstract startOrUpdateChannelMediaRelayEx(
768
+ configuration: ChannelMediaRelayConfiguration,
769
+ connection: RtcConnection
770
+ ): number;
771
+
772
+ /**
773
+ * Stops the media stream relay. Once the relay stops, the host quits all the target channels.
774
+ *
775
+ * After a successful method call, the SDK triggers the onChannelMediaRelayStateChanged callback. If the callback reports RelayStateIdle (0) and RelayOk (0), the host successfully stops the relay. If the method call fails, the SDK triggers the onChannelMediaRelayStateChanged callback with the RelayErrorServerNoResponse (2) or RelayErrorServerConnectionLost (8) status code. You can call the leaveChannel method to leave the channel, and the media stream relay automatically stops.
776
+ *
777
+ * @param connection The connection information. See RtcConnection.
778
+ *
779
+ * @returns
780
+ * 0: Success.
781
+ * < 0: Failure.
782
+ * -5: The method call was rejected. There is no ongoing channel media relay.
783
+ */
784
+ abstract stopChannelMediaRelayEx(connection: RtcConnection): number;
785
+
786
+ /**
787
+ * Pauses the media stream relay to all target channels.
788
+ *
789
+ * After the cross-channel media stream relay starts, you can call this method to pause relaying media streams to all target channels; after the pause, if you want to resume the relay, call resumeAllChannelMediaRelay. Call this method after startOrUpdateChannelMediaRelayEx.
790
+ *
791
+ * @param connection The connection information. See RtcConnection.
792
+ *
793
+ * @returns
794
+ * 0: Success.
795
+ * < 0: Failure.
796
+ * -5: The method call was rejected. There is no ongoing channel media relay.
797
+ */
798
+ abstract pauseAllChannelMediaRelayEx(connection: RtcConnection): number;
799
+
800
+ /**
801
+ * Resumes the media stream relay to all target channels.
802
+ *
803
+ * After calling the pauseAllChannelMediaRelayEx method, you can call this method to resume relaying media streams to all destination channels. Call this method after pauseAllChannelMediaRelayEx.
804
+ *
805
+ * @param connection The connection information. See RtcConnection.
806
+ *
807
+ * @returns
808
+ * 0: Success.
809
+ * < 0: Failure.
810
+ * -5: The method call was rejected. There is no paused channel media relay.
811
+ */
812
+ abstract resumeAllChannelMediaRelayEx(connection: RtcConnection): number;
813
+
814
+ /**
815
+ * @ignore
816
+ */
817
+ abstract getUserInfoByUserAccountEx(
818
+ userAccount: string,
819
+ connection: RtcConnection
820
+ ): UserInfo;
821
+
822
+ /**
823
+ * @ignore
824
+ */
825
+ abstract getUserInfoByUidEx(uid: number, connection: RtcConnection): UserInfo;
826
+
827
+ /**
828
+ * Enables or disables dual-stream mode on the sender side.
829
+ *
830
+ * After you enable dual-stream mode, you can call setRemoteVideoStreamType to choose to receive either the high-quality video stream or the low-quality video stream on the subscriber side. You can call this method to enable or disable the dual-stream mode on the publisher side. Dual streams are a pairing of a high-quality video stream and a low-quality video stream:
831
+ * High-quality video stream: High bitrate, high resolution.
832
+ * Low-quality video stream: Low bitrate, low resolution. Deprecated: This method is deprecated as of v4.2.0. Use setDualStreamModeEx instead. This method is applicable to all types of streams from the sender, including but not limited to video streams collected from cameras, screen sharing streams, and custom-collected video streams.
833
+ *
834
+ * @param enabled Whether to enable dual-stream mode: true : Enable dual-stream mode. false : (Default) Disable dual-stream mode.
835
+ * @param streamConfig The configuration of the low-quality video stream. See SimulcastStreamConfig. When setting mode to DisableSimulcastStream, setting streamConfig will not take effect.
836
+ * @param connection The connection information. See RtcConnection.
837
+ *
838
+ * @returns
839
+ * 0: Success.
840
+ * < 0: Failure.
841
+ */
842
+ abstract enableDualStreamModeEx(
843
+ enabled: boolean,
844
+ streamConfig: SimulcastStreamConfig,
845
+ connection: RtcConnection
846
+ ): number;
847
+
848
+ /**
849
+ * Sets the dual-stream mode on the sender side.
850
+ *
851
+ * The SDK defaults to enabling low-quality video stream adaptive mode (AutoSimulcastStream) on the sender side, which means the sender does not actively send low-quality video stream. The receiving end with the role of the host can initiate a low-quality video stream request by calling setRemoteVideoStreamTypeEx, and upon receiving the request, the sending end automatically starts sending low-quality stream.
852
+ * If you want to modify this behavior, you can call this method and set mode to DisableSimulcastStream (never send low-quality video streams) or EnableSimulcastStream (always send low-quality video streams).
853
+ * If you want to restore the default behavior after making changes, you can call this method again with mode set to AutoSimulcastStream. The difference and connection between this method and enableDualStreamModeEx is as follows:
854
+ * When calling this method and setting mode to DisableSimulcastStream, it has the same effect as enableDualStreamModeEx (false).
855
+ * When calling this method and setting mode to EnableSimulcastStream, it has the same effect as enableDualStreamModeEx (true).
856
+ * Both methods can be called before and after joining a channel. If both methods are used, the settings in the method called later takes precedence.
857
+ *
858
+ * @param mode The mode in which the video stream is sent. See SimulcastStreamMode.
859
+ * @param streamConfig The configuration of the low-quality video stream. See SimulcastStreamConfig. When setting mode to DisableSimulcastStream, setting streamConfig will not take effect.
860
+ * @param connection The connection information. See RtcConnection.
861
+ *
862
+ * @returns
863
+ * 0: Success.
864
+ * < 0: Failure.
865
+ */
866
+ abstract setDualStreamModeEx(
867
+ mode: SimulcastStreamMode,
868
+ streamConfig: SimulcastStreamConfig,
869
+ connection: RtcConnection
870
+ ): number;
871
+
872
+ /**
873
+ * @ignore
874
+ */
875
+ abstract setSimulcastConfigEx(
876
+ simulcastConfig: SimulcastConfig,
877
+ connection: RtcConnection
878
+ ): number;
879
+
880
+ /**
881
+ * @ignore
882
+ */
883
+ abstract setHighPriorityUserListEx(
884
+ uidList: number[],
885
+ uidNum: number,
886
+ option: StreamFallbackOptions,
887
+ connection: RtcConnection
888
+ ): number;
889
+
890
+ /**
891
+ * Takes a snapshot of a video stream using connection ID.
892
+ *
893
+ * This method takes a snapshot of a video stream from the specified user, generates a JPG image, and saves it to the specified path.
894
+ *
895
+ * @param connection The connection information. See RtcConnection.
896
+ * @param uid The user ID. Set uid as 0 if you want to take a snapshot of the local user's video.
897
+ * @param filePath The local path (including filename extensions) of the snapshot. For example:
898
+ * Windows: C:\Users\<user_name>\AppData\Local\Agora\<process_name>\example.jpg
899
+ * macOS: ~/Library/Logs/example.jpg Ensure that the path you specify exists and is writable.
900
+ *
901
+ * @returns
902
+ * 0: Success.
903
+ * < 0: Failure.
904
+ */
905
+ abstract takeSnapshotEx(
906
+ connection: RtcConnection,
907
+ uid: number,
908
+ filePath: string
909
+ ): number;
910
+
911
+ /**
912
+ * Enables or disables video screenshot and upload.
913
+ *
914
+ * This method can take screenshots for multiple video streams and upload them. When video screenshot and upload function is enabled, the SDK takes screenshots and uploads videos sent by local users based on the type and frequency of the module you set in ContentInspectConfig. After video screenshot and upload, the Agora server sends the callback notification to your app server in HTTPS requests and sends all screenshots to the third-party cloud storage service.
915
+ *
916
+ * @param enabled Whether to enalbe video screenshot and upload: true : Enables video screenshot and upload. false : Disables video screenshot and upload.
917
+ * @param config Screenshot and upload configuration. See ContentInspectConfig.
918
+ * @param connection The connection information. See RtcConnection.
919
+ *
920
+ * @returns
921
+ * 0: Success.
922
+ * < 0: Failure.
923
+ */
924
+ abstract enableContentInspectEx(
925
+ enabled: boolean,
926
+ config: ContentInspectConfig,
927
+ connection: RtcConnection
928
+ ): number;
929
+
930
+ /**
931
+ * Enables tracing the video frame rendering process.
932
+ *
933
+ * The SDK automatically starts tracking the rendering events of the video from the moment that you call joinChannel to join the channel. You can call this method at an appropriate time according to the actual application scenario to customize the tracing process.
934
+ * After the local user leaves the current channel, the SDK automatically resets the time point to the next time when the user successfully joins the channel. The SDK starts tracing the rendering status of the video frames in the channel from the moment this method is successfully called and reports information about the event through the onVideoRenderingTracingResult callback.
935
+ *
936
+ * @param connection The connection information. See RtcConnection.
937
+ *
938
+ * @returns
939
+ * 0: Success.
940
+ * < 0: Failure.
941
+ */
942
+ abstract startMediaRenderingTracingEx(connection: RtcConnection): number;
943
+
944
+ /**
945
+ * @ignore
946
+ */
947
+ abstract setParametersEx(
948
+ connection: RtcConnection,
949
+ parameters: string
950
+ ): number;
951
+
952
+ /**
953
+ * Gets the call ID with the connection ID.
954
+ *
955
+ * When a user joins a channel on a client, a callId is generated to identify the call from the client. You can call this method to get callId, and pass it in when calling methods such as rate and complain.
956
+ *
957
+ * @param connection The connection information. See RtcConnection.
958
+ *
959
+ * @returns
960
+ * The current call ID, if the method succeeds.
961
+ * An empty string, if the method call fails.
962
+ */
963
+ abstract getCallIdEx(connection: RtcConnection): string;
964
+
965
+ /**
966
+ * @ignore
967
+ */
968
+ abstract sendAudioMetadataEx(
969
+ connection: RtcConnection,
970
+ metadata: string,
971
+ length: number
972
+ ): number;
973
+
974
+ /**
975
+ * Gets a video screenshot of the specified observation point using the connection ID.
976
+ *
977
+ * This method takes a snapshot of a video stream from the specified user, generates a JPG image, and saves it to the specified path.
978
+ *
979
+ * @param connection The connection information. See RtcConnection.
980
+ * @param uid The user ID. Set uid as 0 if you want to take a snapshot of the local user's video.
981
+ * @param config The configuration of the snaptshot. See SnapshotConfig.
982
+ *
983
+ * @returns
984
+ * 0: Success.
985
+ * < 0: Failure.
986
+ */
987
+ abstract takeSnapshotWithConfigEx(
988
+ connection: RtcConnection,
989
+ uid: number,
990
+ config: SnapshotConfig
991
+ ): number;
992
+ }