agora-electron-sdk 4.5.2 → 4.5.3-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.
Files changed (411) hide show
  1. package/CHANGELOG.md +39 -0
  2. package/README.md +6 -3
  3. package/js/example/src/renderer/examples/advanced/VideoEffect/videoEffectHelpers.js +395 -0
  4. package/js/{AgoraSdk.js → ts/AgoraSdk.js} +2 -12
  5. package/js/{Decoder → ts/Decoder}/index.js +1 -1
  6. package/js/{Private → ts/Private}/AgoraBase.js +829 -674
  7. package/js/{Private → ts/Private}/AgoraMediaBase.js +154 -151
  8. package/js/{Private → ts/Private}/AgoraMediaPlayerTypes.js +58 -54
  9. package/js/{Private → ts/Private}/IAgoraLog.js +13 -13
  10. package/js/{Private → ts/Private}/IAgoraMediaEngine.js +4 -4
  11. package/js/{Private → ts/Private}/IAgoraMediaPlayer.js +2 -2
  12. package/js/{Private → ts/Private}/IAgoraMusicContentCenter.js +1 -1
  13. package/js/{Private → ts/Private}/IAgoraRhythmPlayer.js +13 -13
  14. package/js/{Private → ts/Private}/IAgoraRtcEngine.js +150 -94
  15. package/js/{Private → ts/Private}/IAgoraRtcEngineEx.js +3 -3
  16. package/js/{Private → ts/Private}/IAgoraSpatialAudio.js +4 -4
  17. package/js/{Private → ts/Private}/IAudioDeviceManager.js +2 -2
  18. package/js/{Private → ts/Private}/impl/IAgoraMediaPlayerImpl.js +10 -0
  19. package/js/{Private → ts/Private}/impl/IAgoraRtcEngineExImpl.js +74 -0
  20. package/js/{Private → ts/Private}/impl/IAgoraRtcEngineImpl.js +233 -1
  21. package/js/{Private → ts/Private}/internal/IrisApiEngine.js +45 -0
  22. package/js/{Private → ts/Private}/internal/RtcEngineExInternal.js +74 -4
  23. package/js/ts/Private/internal/VideoEffectObjectInternal.js +14 -0
  24. package/js/{Private → ts/Private}/ti/IAgoraRtcEngine-ti.js +2 -0
  25. package/js/{Renderer → ts/Renderer}/AgoraView.js +19 -2
  26. package/js/{Renderer → ts/Renderer}/IRenderer.js +7 -4
  27. package/js/{Renderer → ts/Renderer}/IRendererCache.js +17 -1
  28. package/js/ts/Renderer/RendererCache.js +252 -0
  29. package/js/{Renderer → ts/Renderer}/RendererManager.js +13 -64
  30. package/js/{Renderer → ts/Renderer}/WebCodecsRenderer/index.js +5 -5
  31. package/js/{Renderer → ts/Renderer}/WebCodecsRendererCache.js +13 -1
  32. package/js/{Renderer → ts/Renderer}/WebGLRenderer/index.js +179 -26
  33. package/js/{Renderer → ts/Renderer}/YUVCanvasRenderer/index.js +12 -5
  34. package/js/{Utils.js → ts/Utils.js} +7 -7
  35. package/package.json +25 -12
  36. package/scripts/checkElectron.js +4 -2
  37. package/scripts/download.js +102 -0
  38. package/scripts/downloadPrebuild.js +2 -1
  39. package/scripts/synclib.js +2 -2
  40. package/ts/AgoraSdk.ts +2 -12
  41. package/ts/Decoder/index.ts +5 -1
  42. package/ts/Private/AgoraBase.ts +1259 -1060
  43. package/ts/Private/AgoraMediaBase.ts +351 -324
  44. package/ts/Private/AgoraMediaPlayerTypes.ts +94 -91
  45. package/ts/Private/IAgoraLog.ts +20 -18
  46. package/ts/Private/IAgoraMediaEngine.ts +86 -81
  47. package/ts/Private/IAgoraMediaPlayer.ts +196 -181
  48. package/ts/Private/IAgoraMediaPlayerSource.ts +40 -40
  49. package/ts/Private/IAgoraMusicContentCenter.ts +3 -3
  50. package/ts/Private/IAgoraRhythmPlayer.ts +15 -15
  51. package/ts/Private/IAgoraRtcEngine.ts +2492 -2047
  52. package/ts/Private/IAgoraRtcEngineEx.ts +434 -335
  53. package/ts/Private/IAgoraSpatialAudio.ts +43 -45
  54. package/ts/Private/IAudioDeviceManager.ts +106 -97
  55. package/ts/Private/impl/IAgoraMediaPlayerImpl.ts +12 -0
  56. package/ts/Private/impl/IAgoraRtcEngineExImpl.ts +138 -0
  57. package/ts/Private/impl/IAgoraRtcEngineImpl.ts +331 -0
  58. package/ts/Private/internal/IrisApiEngine.ts +47 -0
  59. package/ts/Private/internal/RtcEngineExInternal.ts +106 -9
  60. package/ts/Private/internal/VideoEffectObjectInternal.ts +14 -0
  61. package/ts/Private/ti/IAgoraRtcEngine-ti.ts +2 -0
  62. package/ts/Renderer/AgoraView.ts +32 -3
  63. package/ts/Renderer/IRenderer.ts +8 -3
  64. package/ts/Renderer/IRendererCache.ts +33 -0
  65. package/ts/Renderer/RendererCache.ts +211 -12
  66. package/ts/Renderer/RendererManager.ts +21 -99
  67. package/ts/Renderer/WebCodecsRenderer/index.ts +9 -6
  68. package/ts/Renderer/WebCodecsRendererCache.ts +17 -1
  69. package/ts/Renderer/WebGLRenderer/index.ts +246 -40
  70. package/ts/Renderer/YUVCanvasRenderer/index.ts +29 -16
  71. package/ts/Types.ts +14 -9
  72. package/ts/Utils.ts +8 -7
  73. package/types/example/src/renderer/examples/advanced/VideoEffect/videoEffectHelpers.d.ts +168 -0
  74. package/types/example/src/renderer/examples/advanced/VideoEffect/videoEffectHelpers.d.ts.map +1 -0
  75. package/types/{AgoraSdk.d.ts → ts/AgoraSdk.d.ts} +2 -12
  76. package/types/ts/AgoraSdk.d.ts.map +1 -0
  77. package/types/ts/Decoder/gpu-utils.d.ts.map +1 -0
  78. package/types/ts/Decoder/index.d.ts.map +1 -0
  79. package/types/ts/Private/AgoraBase.d.ts +5504 -0
  80. package/types/ts/Private/AgoraBase.d.ts.map +1 -0
  81. package/types/ts/Private/AgoraMediaBase.d.ts +1695 -0
  82. package/types/ts/Private/AgoraMediaBase.d.ts.map +1 -0
  83. package/types/ts/Private/AgoraMediaPlayerTypes.d.ts +456 -0
  84. package/types/ts/Private/AgoraMediaPlayerTypes.d.ts.map +1 -0
  85. package/types/ts/Private/IAgoraH265Transcoder.d.ts.map +1 -0
  86. package/types/ts/Private/IAgoraLog.d.ts +91 -0
  87. package/types/ts/Private/IAgoraLog.d.ts.map +1 -0
  88. package/types/ts/Private/IAgoraMediaEngine.d.ts +255 -0
  89. package/types/ts/Private/IAgoraMediaEngine.d.ts.map +1 -0
  90. package/types/ts/Private/IAgoraMediaPlayer.d.ts +662 -0
  91. package/types/ts/Private/IAgoraMediaPlayer.d.ts.map +1 -0
  92. package/types/ts/Private/IAgoraMediaPlayerSource.d.ts +109 -0
  93. package/types/ts/Private/IAgoraMediaPlayerSource.d.ts.map +1 -0
  94. package/types/ts/Private/IAgoraMediaRecorder.d.ts.map +1 -0
  95. package/types/ts/Private/IAgoraMediaStreamingSource.d.ts.map +1 -0
  96. package/types/{Private → ts/Private}/IAgoraMusicContentCenter.d.ts +3 -3
  97. package/types/ts/Private/IAgoraMusicContentCenter.d.ts.map +1 -0
  98. package/types/ts/Private/IAgoraRhythmPlayer.d.ts +65 -0
  99. package/types/ts/Private/IAgoraRhythmPlayer.d.ts.map +1 -0
  100. package/types/ts/Private/IAgoraRtcEngine.d.ts +6504 -0
  101. package/types/ts/Private/IAgoraRtcEngine.d.ts.map +1 -0
  102. package/types/ts/Private/IAgoraRtcEngineEx.d.ts +817 -0
  103. package/types/ts/Private/IAgoraRtcEngineEx.d.ts.map +1 -0
  104. package/types/ts/Private/IAgoraSpatialAudio.d.ts +194 -0
  105. package/types/ts/Private/IAgoraSpatialAudio.d.ts.map +1 -0
  106. package/types/ts/Private/IAudioDeviceManager.d.ts +321 -0
  107. package/types/ts/Private/IAudioDeviceManager.d.ts.map +1 -0
  108. package/types/ts/Private/extension/AgoraBaseExtension.d.ts.map +1 -0
  109. package/types/ts/Private/extension/AgoraMediaBaseExtension.d.ts.map +1 -0
  110. package/types/ts/Private/extension/AgoraMediaPlayerTypesExtension.d.ts.map +1 -0
  111. package/types/ts/Private/extension/IAgoraH265TranscoderExtension.d.ts.map +1 -0
  112. package/types/ts/Private/extension/IAgoraLogExtension.d.ts.map +1 -0
  113. package/types/ts/Private/extension/IAgoraMediaEngineExtension.d.ts.map +1 -0
  114. package/types/ts/Private/extension/IAgoraMediaPlayerExtension.d.ts.map +1 -0
  115. package/types/ts/Private/extension/IAgoraMediaPlayerSourceExtension.d.ts.map +1 -0
  116. package/types/ts/Private/extension/IAgoraMediaRecorderExtension.d.ts.map +1 -0
  117. package/types/ts/Private/extension/IAgoraMusicContentCenterExtension.d.ts.map +1 -0
  118. package/types/ts/Private/extension/IAgoraRhythmPlayerExtension.d.ts.map +1 -0
  119. package/types/ts/Private/extension/IAgoraRtcEngineExExtension.d.ts.map +1 -0
  120. package/types/ts/Private/extension/IAgoraRtcEngineExtension.d.ts.map +1 -0
  121. package/types/ts/Private/extension/IAgoraSpatialAudioExtension.d.ts.map +1 -0
  122. package/types/ts/Private/extension/IAudioDeviceManagerExtension.d.ts.map +1 -0
  123. package/types/ts/Private/impl/AgoraBaseImpl.d.ts.map +1 -0
  124. package/types/ts/Private/impl/AgoraMediaBaseImpl.d.ts.map +1 -0
  125. package/types/ts/Private/impl/IAgoraH265TranscoderImpl.d.ts.map +1 -0
  126. package/types/ts/Private/impl/IAgoraMediaEngineImpl.d.ts.map +1 -0
  127. package/types/{Private → ts/Private}/impl/IAgoraMediaPlayerImpl.d.ts +2 -0
  128. package/types/ts/Private/impl/IAgoraMediaPlayerImpl.d.ts.map +1 -0
  129. package/types/ts/Private/impl/IAgoraMediaPlayerSourceImpl.d.ts.map +1 -0
  130. package/types/ts/Private/impl/IAgoraMediaRecorderImpl.d.ts.map +1 -0
  131. package/types/ts/Private/impl/IAgoraMusicContentCenterImpl.d.ts.map +1 -0
  132. package/types/{Private → ts/Private}/impl/IAgoraRtcEngineExImpl.d.ts +7 -1
  133. package/types/ts/Private/impl/IAgoraRtcEngineExImpl.d.ts.map +1 -0
  134. package/types/{Private → ts/Private}/impl/IAgoraRtcEngineImpl.d.ts +27 -1
  135. package/types/ts/Private/impl/IAgoraRtcEngineImpl.d.ts.map +1 -0
  136. package/types/ts/Private/impl/IAgoraSpatialAudioImpl.d.ts.map +1 -0
  137. package/types/ts/Private/impl/IAudioDeviceManagerImpl.d.ts.map +1 -0
  138. package/types/ts/Private/internal/AgoraH265TranscoderInternal.d.ts.map +1 -0
  139. package/types/ts/Private/internal/AgoraMediaBaseInternal.d.ts.map +1 -0
  140. package/types/ts/Private/internal/AudioDeviceManagerInternal.d.ts.map +1 -0
  141. package/types/ts/Private/internal/IrisApiEngine.d.ts.map +1 -0
  142. package/types/ts/Private/internal/LocalSpatialAudioEngineInternal.d.ts.map +1 -0
  143. package/types/ts/Private/internal/MediaEngineInternal.d.ts.map +1 -0
  144. package/types/ts/Private/internal/MediaPlayerInternal.d.ts.map +1 -0
  145. package/types/ts/Private/internal/MediaRecorderInternal.d.ts.map +1 -0
  146. package/types/ts/Private/internal/MusicContentCenterInternal.d.ts.map +1 -0
  147. package/types/{Private → ts/Private}/internal/RtcEngineExInternal.d.ts +10 -4
  148. package/types/ts/Private/internal/RtcEngineExInternal.d.ts.map +1 -0
  149. package/types/ts/Private/internal/VideoEffectObjectInternal.d.ts +7 -0
  150. package/types/ts/Private/internal/VideoEffectObjectInternal.d.ts.map +1 -0
  151. package/types/{Private → ts/Private}/ipc/main.d.ts.map +1 -1
  152. package/types/ts/Private/ipc/renderer.d.ts.map +1 -0
  153. package/types/ts/Private/ti/AgoraBase-ti.d.ts.map +1 -0
  154. package/types/ts/Private/ti/AgoraMediaBase-ti.d.ts.map +1 -0
  155. package/types/ts/Private/ti/AgoraMediaPlayerTypes-ti.d.ts.map +1 -0
  156. package/types/ts/Private/ti/IAgoraH265Transcoder-ti.d.ts.map +1 -0
  157. package/types/ts/Private/ti/IAgoraLog-ti.d.ts.map +1 -0
  158. package/types/ts/Private/ti/IAgoraMediaEngine-ti.d.ts.map +1 -0
  159. package/types/ts/Private/ti/IAgoraMediaPlayer-ti.d.ts.map +1 -0
  160. package/types/ts/Private/ti/IAgoraMediaPlayerSource-ti.d.ts.map +1 -0
  161. package/types/ts/Private/ti/IAgoraMediaRecorder-ti.d.ts.map +1 -0
  162. package/types/ts/Private/ti/IAgoraMediaStreamingSource-ti.d.ts.map +1 -0
  163. package/types/ts/Private/ti/IAgoraMusicContentCenter-ti.d.ts.map +1 -0
  164. package/types/ts/Private/ti/IAgoraRhythmPlayer-ti.d.ts.map +1 -0
  165. package/types/ts/Private/ti/IAgoraRtcEngine-ti.d.ts.map +1 -0
  166. package/types/ts/Private/ti/IAgoraRtcEngineEx-ti.d.ts.map +1 -0
  167. package/types/ts/Private/ti/IAgoraSpatialAudio-ti.d.ts.map +1 -0
  168. package/types/ts/Private/ti/IAudioDeviceManager-ti.d.ts.map +1 -0
  169. package/types/{Renderer → ts/Renderer}/AgoraView.d.ts +6 -0
  170. package/types/ts/Renderer/AgoraView.d.ts.map +1 -0
  171. package/types/ts/Renderer/CapabilityManager.d.ts.map +1 -0
  172. package/types/{Renderer → ts/Renderer}/IRenderer.d.ts +2 -2
  173. package/types/ts/Renderer/IRenderer.d.ts.map +1 -0
  174. package/types/{Renderer → ts/Renderer}/IRendererCache.d.ts +21 -1
  175. package/types/ts/Renderer/IRendererCache.d.ts.map +1 -0
  176. package/types/{Renderer → ts/Renderer}/RendererCache.d.ts +27 -0
  177. package/types/ts/Renderer/RendererCache.d.ts.map +1 -0
  178. package/types/{Renderer → ts/Renderer}/RendererManager.d.ts +4 -17
  179. package/types/ts/Renderer/RendererManager.d.ts.map +1 -0
  180. package/types/{Renderer → ts/Renderer}/WebCodecsRenderer/index.d.ts +3 -3
  181. package/types/ts/Renderer/WebCodecsRenderer/index.d.ts.map +1 -0
  182. package/types/{Renderer → ts/Renderer}/WebCodecsRendererCache.d.ts +7 -0
  183. package/types/ts/Renderer/WebCodecsRendererCache.d.ts.map +1 -0
  184. package/types/{Renderer → ts/Renderer}/WebGLRenderer/index.d.ts +12 -2
  185. package/types/ts/Renderer/WebGLRenderer/index.d.ts.map +1 -0
  186. package/types/ts/Renderer/WebGLRenderer/webgl-utils.d.ts.map +1 -0
  187. package/types/ts/Renderer/YUVCanvasRenderer/index.d.ts +10 -0
  188. package/types/ts/Renderer/YUVCanvasRenderer/index.d.ts.map +1 -0
  189. package/types/ts/Renderer/index.d.ts.map +1 -0
  190. package/types/{Types.d.ts → ts/Types.d.ts} +11 -6
  191. package/types/ts/Types.d.ts.map +1 -0
  192. package/types/{Utils.d.ts → ts/Utils.d.ts} +1 -1
  193. package/types/ts/Utils.d.ts.map +1 -0
  194. package/js/Renderer/RendererCache.js +0 -100
  195. package/types/AgoraSdk.d.ts.map +0 -1
  196. package/types/Decoder/gpu-utils.d.ts.map +0 -1
  197. package/types/Decoder/index.d.ts.map +0 -1
  198. package/types/Private/AgoraBase.d.ts +0 -5310
  199. package/types/Private/AgoraBase.d.ts.map +0 -1
  200. package/types/Private/AgoraMediaBase.d.ts +0 -1668
  201. package/types/Private/AgoraMediaBase.d.ts.map +0 -1
  202. package/types/Private/AgoraMediaPlayerTypes.d.ts +0 -453
  203. package/types/Private/AgoraMediaPlayerTypes.d.ts.map +0 -1
  204. package/types/Private/IAgoraH265Transcoder.d.ts.map +0 -1
  205. package/types/Private/IAgoraLog.d.ts +0 -89
  206. package/types/Private/IAgoraLog.d.ts.map +0 -1
  207. package/types/Private/IAgoraMediaEngine.d.ts +0 -250
  208. package/types/Private/IAgoraMediaEngine.d.ts.map +0 -1
  209. package/types/Private/IAgoraMediaPlayer.d.ts +0 -648
  210. package/types/Private/IAgoraMediaPlayer.d.ts.map +0 -1
  211. package/types/Private/IAgoraMediaPlayerSource.d.ts +0 -109
  212. package/types/Private/IAgoraMediaPlayerSource.d.ts.map +0 -1
  213. package/types/Private/IAgoraMediaRecorder.d.ts.map +0 -1
  214. package/types/Private/IAgoraMediaStreamingSource.d.ts.map +0 -1
  215. package/types/Private/IAgoraMusicContentCenter.d.ts.map +0 -1
  216. package/types/Private/IAgoraRhythmPlayer.d.ts +0 -65
  217. package/types/Private/IAgoraRhythmPlayer.d.ts.map +0 -1
  218. package/types/Private/IAgoraRtcEngine.d.ts +0 -6103
  219. package/types/Private/IAgoraRtcEngine.d.ts.map +0 -1
  220. package/types/Private/IAgoraRtcEngineEx.d.ts +0 -741
  221. package/types/Private/IAgoraRtcEngineEx.d.ts.map +0 -1
  222. package/types/Private/IAgoraSpatialAudio.d.ts +0 -196
  223. package/types/Private/IAgoraSpatialAudio.d.ts.map +0 -1
  224. package/types/Private/IAudioDeviceManager.d.ts +0 -312
  225. package/types/Private/IAudioDeviceManager.d.ts.map +0 -1
  226. package/types/Private/extension/AgoraBaseExtension.d.ts.map +0 -1
  227. package/types/Private/extension/AgoraMediaBaseExtension.d.ts.map +0 -1
  228. package/types/Private/extension/AgoraMediaPlayerTypesExtension.d.ts.map +0 -1
  229. package/types/Private/extension/IAgoraH265TranscoderExtension.d.ts.map +0 -1
  230. package/types/Private/extension/IAgoraLogExtension.d.ts.map +0 -1
  231. package/types/Private/extension/IAgoraMediaEngineExtension.d.ts.map +0 -1
  232. package/types/Private/extension/IAgoraMediaPlayerExtension.d.ts.map +0 -1
  233. package/types/Private/extension/IAgoraMediaPlayerSourceExtension.d.ts.map +0 -1
  234. package/types/Private/extension/IAgoraMediaRecorderExtension.d.ts.map +0 -1
  235. package/types/Private/extension/IAgoraMusicContentCenterExtension.d.ts.map +0 -1
  236. package/types/Private/extension/IAgoraRhythmPlayerExtension.d.ts.map +0 -1
  237. package/types/Private/extension/IAgoraRtcEngineExExtension.d.ts.map +0 -1
  238. package/types/Private/extension/IAgoraRtcEngineExtension.d.ts.map +0 -1
  239. package/types/Private/extension/IAgoraSpatialAudioExtension.d.ts.map +0 -1
  240. package/types/Private/extension/IAudioDeviceManagerExtension.d.ts.map +0 -1
  241. package/types/Private/impl/AgoraBaseImpl.d.ts.map +0 -1
  242. package/types/Private/impl/AgoraMediaBaseImpl.d.ts.map +0 -1
  243. package/types/Private/impl/IAgoraH265TranscoderImpl.d.ts.map +0 -1
  244. package/types/Private/impl/IAgoraMediaEngineImpl.d.ts.map +0 -1
  245. package/types/Private/impl/IAgoraMediaPlayerImpl.d.ts.map +0 -1
  246. package/types/Private/impl/IAgoraMediaPlayerSourceImpl.d.ts.map +0 -1
  247. package/types/Private/impl/IAgoraMediaRecorderImpl.d.ts.map +0 -1
  248. package/types/Private/impl/IAgoraMusicContentCenterImpl.d.ts.map +0 -1
  249. package/types/Private/impl/IAgoraRtcEngineExImpl.d.ts.map +0 -1
  250. package/types/Private/impl/IAgoraRtcEngineImpl.d.ts.map +0 -1
  251. package/types/Private/impl/IAgoraSpatialAudioImpl.d.ts.map +0 -1
  252. package/types/Private/impl/IAudioDeviceManagerImpl.d.ts.map +0 -1
  253. package/types/Private/internal/AgoraH265TranscoderInternal.d.ts.map +0 -1
  254. package/types/Private/internal/AgoraMediaBaseInternal.d.ts.map +0 -1
  255. package/types/Private/internal/AudioDeviceManagerInternal.d.ts.map +0 -1
  256. package/types/Private/internal/IrisApiEngine.d.ts.map +0 -1
  257. package/types/Private/internal/LocalSpatialAudioEngineInternal.d.ts.map +0 -1
  258. package/types/Private/internal/MediaEngineInternal.d.ts.map +0 -1
  259. package/types/Private/internal/MediaPlayerInternal.d.ts.map +0 -1
  260. package/types/Private/internal/MediaRecorderInternal.d.ts.map +0 -1
  261. package/types/Private/internal/MusicContentCenterInternal.d.ts.map +0 -1
  262. package/types/Private/internal/RtcEngineExInternal.d.ts.map +0 -1
  263. package/types/Private/ipc/renderer.d.ts.map +0 -1
  264. package/types/Private/ti/AgoraBase-ti.d.ts.map +0 -1
  265. package/types/Private/ti/AgoraMediaBase-ti.d.ts.map +0 -1
  266. package/types/Private/ti/AgoraMediaPlayerTypes-ti.d.ts.map +0 -1
  267. package/types/Private/ti/IAgoraH265Transcoder-ti.d.ts.map +0 -1
  268. package/types/Private/ti/IAgoraLog-ti.d.ts.map +0 -1
  269. package/types/Private/ti/IAgoraMediaEngine-ti.d.ts.map +0 -1
  270. package/types/Private/ti/IAgoraMediaPlayer-ti.d.ts.map +0 -1
  271. package/types/Private/ti/IAgoraMediaPlayerSource-ti.d.ts.map +0 -1
  272. package/types/Private/ti/IAgoraMediaRecorder-ti.d.ts.map +0 -1
  273. package/types/Private/ti/IAgoraMediaStreamingSource-ti.d.ts.map +0 -1
  274. package/types/Private/ti/IAgoraMusicContentCenter-ti.d.ts.map +0 -1
  275. package/types/Private/ti/IAgoraRhythmPlayer-ti.d.ts.map +0 -1
  276. package/types/Private/ti/IAgoraRtcEngine-ti.d.ts.map +0 -1
  277. package/types/Private/ti/IAgoraRtcEngineEx-ti.d.ts.map +0 -1
  278. package/types/Private/ti/IAgoraSpatialAudio-ti.d.ts.map +0 -1
  279. package/types/Private/ti/IAudioDeviceManager-ti.d.ts.map +0 -1
  280. package/types/Renderer/AgoraView.d.ts.map +0 -1
  281. package/types/Renderer/CapabilityManager.d.ts.map +0 -1
  282. package/types/Renderer/IRenderer.d.ts.map +0 -1
  283. package/types/Renderer/IRendererCache.d.ts.map +0 -1
  284. package/types/Renderer/RendererCache.d.ts.map +0 -1
  285. package/types/Renderer/RendererManager.d.ts.map +0 -1
  286. package/types/Renderer/WebCodecsRenderer/index.d.ts.map +0 -1
  287. package/types/Renderer/WebCodecsRendererCache.d.ts.map +0 -1
  288. package/types/Renderer/WebGLRenderer/index.d.ts.map +0 -1
  289. package/types/Renderer/WebGLRenderer/webgl-utils.d.ts.map +0 -1
  290. package/types/Renderer/YUVCanvasRenderer/index.d.ts +0 -9
  291. package/types/Renderer/YUVCanvasRenderer/index.d.ts.map +0 -1
  292. package/types/Renderer/index.d.ts.map +0 -1
  293. package/types/Types.d.ts.map +0 -1
  294. package/types/Utils.d.ts.map +0 -1
  295. /package/js/{Decoder → ts/Decoder}/gpu-utils.js +0 -0
  296. /package/js/{Private → ts/Private}/IAgoraH265Transcoder.js +0 -0
  297. /package/js/{Private → ts/Private}/IAgoraMediaPlayerSource.js +0 -0
  298. /package/js/{Private → ts/Private}/IAgoraMediaRecorder.js +0 -0
  299. /package/js/{Private → ts/Private}/IAgoraMediaStreamingSource.js +0 -0
  300. /package/js/{Private → ts/Private}/extension/AgoraBaseExtension.js +0 -0
  301. /package/js/{Private → ts/Private}/extension/AgoraMediaBaseExtension.js +0 -0
  302. /package/js/{Private → ts/Private}/extension/AgoraMediaPlayerTypesExtension.js +0 -0
  303. /package/js/{Private → ts/Private}/extension/IAgoraH265TranscoderExtension.js +0 -0
  304. /package/js/{Private → ts/Private}/extension/IAgoraLogExtension.js +0 -0
  305. /package/js/{Private → ts/Private}/extension/IAgoraMediaEngineExtension.js +0 -0
  306. /package/js/{Private → ts/Private}/extension/IAgoraMediaPlayerExtension.js +0 -0
  307. /package/js/{Private → ts/Private}/extension/IAgoraMediaPlayerSourceExtension.js +0 -0
  308. /package/js/{Private → ts/Private}/extension/IAgoraMediaRecorderExtension.js +0 -0
  309. /package/js/{Private → ts/Private}/extension/IAgoraMusicContentCenterExtension.js +0 -0
  310. /package/js/{Private → ts/Private}/extension/IAgoraRhythmPlayerExtension.js +0 -0
  311. /package/js/{Private → ts/Private}/extension/IAgoraRtcEngineExExtension.js +0 -0
  312. /package/js/{Private → ts/Private}/extension/IAgoraRtcEngineExtension.js +0 -0
  313. /package/js/{Private → ts/Private}/extension/IAgoraSpatialAudioExtension.js +0 -0
  314. /package/js/{Private → ts/Private}/extension/IAudioDeviceManagerExtension.js +0 -0
  315. /package/js/{Private → ts/Private}/impl/AgoraBaseImpl.js +0 -0
  316. /package/js/{Private → ts/Private}/impl/AgoraMediaBaseImpl.js +0 -0
  317. /package/js/{Private → ts/Private}/impl/IAgoraH265TranscoderImpl.js +0 -0
  318. /package/js/{Private → ts/Private}/impl/IAgoraMediaEngineImpl.js +0 -0
  319. /package/js/{Private → ts/Private}/impl/IAgoraMediaPlayerSourceImpl.js +0 -0
  320. /package/js/{Private → ts/Private}/impl/IAgoraMediaRecorderImpl.js +0 -0
  321. /package/js/{Private → ts/Private}/impl/IAgoraMusicContentCenterImpl.js +0 -0
  322. /package/js/{Private → ts/Private}/impl/IAgoraSpatialAudioImpl.js +0 -0
  323. /package/js/{Private → ts/Private}/impl/IAudioDeviceManagerImpl.js +0 -0
  324. /package/js/{Private → ts/Private}/internal/AgoraH265TranscoderInternal.js +0 -0
  325. /package/js/{Private → ts/Private}/internal/AgoraMediaBaseInternal.js +0 -0
  326. /package/js/{Private → ts/Private}/internal/AudioDeviceManagerInternal.js +0 -0
  327. /package/js/{Private → ts/Private}/internal/LocalSpatialAudioEngineInternal.js +0 -0
  328. /package/js/{Private → ts/Private}/internal/MediaEngineInternal.js +0 -0
  329. /package/js/{Private → ts/Private}/internal/MediaPlayerInternal.js +0 -0
  330. /package/js/{Private → ts/Private}/internal/MediaRecorderInternal.js +0 -0
  331. /package/js/{Private → ts/Private}/internal/MusicContentCenterInternal.js +0 -0
  332. /package/js/{Private → ts/Private}/ipc/main.js +0 -0
  333. /package/js/{Private → ts/Private}/ipc/renderer.js +0 -0
  334. /package/js/{Private → ts/Private}/ti/AgoraBase-ti.js +0 -0
  335. /package/js/{Private → ts/Private}/ti/AgoraMediaBase-ti.js +0 -0
  336. /package/js/{Private → ts/Private}/ti/AgoraMediaPlayerTypes-ti.js +0 -0
  337. /package/js/{Private → ts/Private}/ti/IAgoraH265Transcoder-ti.js +0 -0
  338. /package/js/{Private → ts/Private}/ti/IAgoraLog-ti.js +0 -0
  339. /package/js/{Private → ts/Private}/ti/IAgoraMediaEngine-ti.js +0 -0
  340. /package/js/{Private → ts/Private}/ti/IAgoraMediaPlayer-ti.js +0 -0
  341. /package/js/{Private → ts/Private}/ti/IAgoraMediaPlayerSource-ti.js +0 -0
  342. /package/js/{Private → ts/Private}/ti/IAgoraMediaRecorder-ti.js +0 -0
  343. /package/js/{Private → ts/Private}/ti/IAgoraMediaStreamingSource-ti.js +0 -0
  344. /package/js/{Private → ts/Private}/ti/IAgoraMusicContentCenter-ti.js +0 -0
  345. /package/js/{Private → ts/Private}/ti/IAgoraRhythmPlayer-ti.js +0 -0
  346. /package/js/{Private → ts/Private}/ti/IAgoraRtcEngineEx-ti.js +0 -0
  347. /package/js/{Private → ts/Private}/ti/IAgoraSpatialAudio-ti.js +0 -0
  348. /package/js/{Private → ts/Private}/ti/IAudioDeviceManager-ti.js +0 -0
  349. /package/js/{Renderer → ts/Renderer}/CapabilityManager.js +0 -0
  350. /package/js/{Renderer → ts/Renderer}/WebGLRenderer/webgl-utils.js +0 -0
  351. /package/js/{Renderer → ts/Renderer}/index.js +0 -0
  352. /package/js/{Types.js → ts/Types.js} +0 -0
  353. /package/types/{Decoder → ts/Decoder}/gpu-utils.d.ts +0 -0
  354. /package/types/{Decoder → ts/Decoder}/index.d.ts +0 -0
  355. /package/types/{Private → ts/Private}/IAgoraH265Transcoder.d.ts +0 -0
  356. /package/types/{Private → ts/Private}/IAgoraMediaRecorder.d.ts +0 -0
  357. /package/types/{Private → ts/Private}/IAgoraMediaStreamingSource.d.ts +0 -0
  358. /package/types/{Private → ts/Private}/extension/AgoraBaseExtension.d.ts +0 -0
  359. /package/types/{Private → ts/Private}/extension/AgoraMediaBaseExtension.d.ts +0 -0
  360. /package/types/{Private → ts/Private}/extension/AgoraMediaPlayerTypesExtension.d.ts +0 -0
  361. /package/types/{Private → ts/Private}/extension/IAgoraH265TranscoderExtension.d.ts +0 -0
  362. /package/types/{Private → ts/Private}/extension/IAgoraLogExtension.d.ts +0 -0
  363. /package/types/{Private → ts/Private}/extension/IAgoraMediaEngineExtension.d.ts +0 -0
  364. /package/types/{Private → ts/Private}/extension/IAgoraMediaPlayerExtension.d.ts +0 -0
  365. /package/types/{Private → ts/Private}/extension/IAgoraMediaPlayerSourceExtension.d.ts +0 -0
  366. /package/types/{Private → ts/Private}/extension/IAgoraMediaRecorderExtension.d.ts +0 -0
  367. /package/types/{Private → ts/Private}/extension/IAgoraMusicContentCenterExtension.d.ts +0 -0
  368. /package/types/{Private → ts/Private}/extension/IAgoraRhythmPlayerExtension.d.ts +0 -0
  369. /package/types/{Private → ts/Private}/extension/IAgoraRtcEngineExExtension.d.ts +0 -0
  370. /package/types/{Private → ts/Private}/extension/IAgoraRtcEngineExtension.d.ts +0 -0
  371. /package/types/{Private → ts/Private}/extension/IAgoraSpatialAudioExtension.d.ts +0 -0
  372. /package/types/{Private → ts/Private}/extension/IAudioDeviceManagerExtension.d.ts +0 -0
  373. /package/types/{Private → ts/Private}/impl/AgoraBaseImpl.d.ts +0 -0
  374. /package/types/{Private → ts/Private}/impl/AgoraMediaBaseImpl.d.ts +0 -0
  375. /package/types/{Private → ts/Private}/impl/IAgoraH265TranscoderImpl.d.ts +0 -0
  376. /package/types/{Private → ts/Private}/impl/IAgoraMediaEngineImpl.d.ts +0 -0
  377. /package/types/{Private → ts/Private}/impl/IAgoraMediaPlayerSourceImpl.d.ts +0 -0
  378. /package/types/{Private → ts/Private}/impl/IAgoraMediaRecorderImpl.d.ts +0 -0
  379. /package/types/{Private → ts/Private}/impl/IAgoraMusicContentCenterImpl.d.ts +0 -0
  380. /package/types/{Private → ts/Private}/impl/IAgoraSpatialAudioImpl.d.ts +0 -0
  381. /package/types/{Private → ts/Private}/impl/IAudioDeviceManagerImpl.d.ts +0 -0
  382. /package/types/{Private → ts/Private}/internal/AgoraH265TranscoderInternal.d.ts +0 -0
  383. /package/types/{Private → ts/Private}/internal/AgoraMediaBaseInternal.d.ts +0 -0
  384. /package/types/{Private → ts/Private}/internal/AudioDeviceManagerInternal.d.ts +0 -0
  385. /package/types/{Private → ts/Private}/internal/IrisApiEngine.d.ts +0 -0
  386. /package/types/{Private → ts/Private}/internal/LocalSpatialAudioEngineInternal.d.ts +0 -0
  387. /package/types/{Private → ts/Private}/internal/MediaEngineInternal.d.ts +0 -0
  388. /package/types/{Private → ts/Private}/internal/MediaPlayerInternal.d.ts +0 -0
  389. /package/types/{Private → ts/Private}/internal/MediaRecorderInternal.d.ts +0 -0
  390. /package/types/{Private → ts/Private}/internal/MusicContentCenterInternal.d.ts +0 -0
  391. /package/types/{Private → ts/Private}/ipc/main.d.ts +0 -0
  392. /package/types/{Private → ts/Private}/ipc/renderer.d.ts +0 -0
  393. /package/types/{Private → ts/Private}/ti/AgoraBase-ti.d.ts +0 -0
  394. /package/types/{Private → ts/Private}/ti/AgoraMediaBase-ti.d.ts +0 -0
  395. /package/types/{Private → ts/Private}/ti/AgoraMediaPlayerTypes-ti.d.ts +0 -0
  396. /package/types/{Private → ts/Private}/ti/IAgoraH265Transcoder-ti.d.ts +0 -0
  397. /package/types/{Private → ts/Private}/ti/IAgoraLog-ti.d.ts +0 -0
  398. /package/types/{Private → ts/Private}/ti/IAgoraMediaEngine-ti.d.ts +0 -0
  399. /package/types/{Private → ts/Private}/ti/IAgoraMediaPlayer-ti.d.ts +0 -0
  400. /package/types/{Private → ts/Private}/ti/IAgoraMediaPlayerSource-ti.d.ts +0 -0
  401. /package/types/{Private → ts/Private}/ti/IAgoraMediaRecorder-ti.d.ts +0 -0
  402. /package/types/{Private → ts/Private}/ti/IAgoraMediaStreamingSource-ti.d.ts +0 -0
  403. /package/types/{Private → ts/Private}/ti/IAgoraMusicContentCenter-ti.d.ts +0 -0
  404. /package/types/{Private → ts/Private}/ti/IAgoraRhythmPlayer-ti.d.ts +0 -0
  405. /package/types/{Private → ts/Private}/ti/IAgoraRtcEngine-ti.d.ts +0 -0
  406. /package/types/{Private → ts/Private}/ti/IAgoraRtcEngineEx-ti.d.ts +0 -0
  407. /package/types/{Private → ts/Private}/ti/IAgoraSpatialAudio-ti.d.ts +0 -0
  408. /package/types/{Private → ts/Private}/ti/IAudioDeviceManager-ti.d.ts +0 -0
  409. /package/types/{Renderer → ts/Renderer}/CapabilityManager.d.ts +0 -0
  410. /package/types/{Renderer → ts/Renderer}/WebGLRenderer/webgl-utils.d.ts +0 -0
  411. /package/types/{Renderer → ts/Renderer}/index.d.ts +0 -0
@@ -16,7 +16,7 @@ import {
16
16
  } from './AgoraMediaBase';
17
17
 
18
18
  /**
19
- * The channel mode.
19
+ * Channel mode.
20
20
  */
21
21
  export enum AudioMixingDualMonoMode {
22
22
  /**
@@ -24,15 +24,15 @@ export enum AudioMixingDualMonoMode {
24
24
  */
25
25
  AudioMixingDualMonoAuto = 0,
26
26
  /**
27
- * 1: Left channel mode. This mode replaces the audio of the right channel with the audio of the left channel, which means the user can only hear the audio of the left channel.
27
+ * 1: Left channel mode. This mode replaces the right channel audio with the left channel audio, so the user hears only the left channel.
28
28
  */
29
29
  AudioMixingDualMonoL = 1,
30
30
  /**
31
- * 2: Right channel mode. This mode replaces the audio of the left channel with the audio of the right channel, which means the user can only hear the audio of the right channel.
31
+ * 2: Right channel mode. This mode replaces the left channel audio with the right channel audio, so the user hears only the right channel.
32
32
  */
33
33
  AudioMixingDualMonoR = 2,
34
34
  /**
35
- * 3: Mixed channel mode. This mode mixes the audio of the left channel and the right channel, which means the user can hear the audio of the left channel and the right channel at the same time.
35
+ * 3: Mixed mode. This mode overlays the left and right channel data, so the user hears both the left and right channels simultaneously.
36
36
  */
37
37
  AudioMixingDualMonoMix = 3,
38
38
  }
@@ -44,97 +44,102 @@ export abstract class IMediaEngine {
44
44
  /**
45
45
  * Registers an audio frame observer object.
46
46
  *
47
- * Call this method to register an audio frame observer object (register a callback). When you need the SDK to trigger the onMixedAudioFrame, onRecordAudioFrame, onPlaybackAudioFrame, onPlaybackAudioFrameBeforeMixing or onEarMonitoringAudioFrame callback, you need to use this method to register the callbacks.
47
+ * This method registers an audio frame observer object, i.e., registers callbacks. You need to call this method to register callbacks if you want the SDK to trigger the onMixedAudioFrame, onRecordAudioFrame, onPlaybackAudioFrame, onPlaybackAudioFrameBeforeMixing, and onEarMonitoringAudioFrame callbacks.
48
48
  *
49
- * @param observer The observer instance. See IAudioFrameObserver. Agora recommends calling this method after receiving onLeaveChannel to release the audio observer object.
49
+ * @param observer Instance of the interface object. See IAudioFrameObserver. It is recommended to call this after receiving onLeaveChannel to release the audio frame observer object.
50
50
  *
51
51
  * @returns
52
52
  * 0: Success.
53
- * < 0: Failure.
53
+ * < 0: Failure. See [Error Codes](https://docs.agora.io/en/video-calling/troubleshooting/error-codes) for details and resolution suggestions.
54
54
  */
55
55
  abstract registerAudioFrameObserver(observer: IAudioFrameObserver): number;
56
56
 
57
57
  /**
58
58
  * Registers a raw video frame observer object.
59
59
  *
60
- * If you want to observe raw video frames (such as YUV or RGBA format), Agora recommends that you implement one IVideoFrameObserver class with this method. When calling this method to register a video observer, you can register callbacks in the IVideoFrameObserver class as needed. After you successfully register the video frame observer, the SDK triggers the registered callbacks each time a video frame is received.
60
+ * If you want to observe raw video frames (such as YUV or RGBA format), Agora recommends registering an IVideoFrameObserver class using this method.
61
+ * When registering the video observer, you can choose to register callbacks from the IVideoFrameObserver class as needed. Once registered successfully, the SDK triggers the registered callbacks whenever a video frame is captured. When handling callbacks, you need to consider changes in the width and height parameters of the video frame, as the observed video frame may vary due to the following conditions:
62
+ * When the network condition is poor, the resolution may drop in steps.
63
+ * When the user adjusts the resolution manually, the resolution reported in the callback will also change.
61
64
  *
62
- * @param observer The observer instance. See IVideoFrameObserver.
65
+ * @param observer Instance of the interface object. See IVideoFrameObserver.
63
66
  *
64
67
  * @returns
65
68
  * 0: Success.
66
- * < 0: Failure.
69
+ * < 0: Failure. See [Error Codes](https://docs.agora.io/en/video-calling/troubleshooting/error-codes) for details and resolution suggestions.
67
70
  */
68
71
  abstract registerVideoFrameObserver(observer: IVideoFrameObserver): number;
69
72
 
70
73
  /**
71
- * Registers a receiver object for the encoded video image.
74
+ * Registers a video frame observer for encoded video frames.
72
75
  *
73
- * If you only want to observe encoded video frames (such as H.264 format) without decoding and rendering the video, Agora recommends that you implement one IVideoEncodedFrameObserver class through this method. Call this method before joining a channel.
76
+ * If you only want to observe encoded video frames (e.g., H.264 format) and do not need to decode or render them, Agora recommends using this method to register an IVideoEncodedFrameObserver class. This method must be called before joining a channel.
74
77
  *
75
- * @param observer The video frame observer object. See IVideoEncodedFrameObserver.
78
+ * @param observer Video frame observer. See IVideoEncodedFrameObserver.
76
79
  *
77
80
  * @returns
78
81
  * 0: Success.
79
- * < 0: Failure.
82
+ * < 0: Failure. See [Error Codes](https://docs.agora.io/en/video-calling/troubleshooting/error-codes) for details and resolution suggestions.
80
83
  */
81
84
  abstract registerVideoEncodedFrameObserver(
82
85
  observer: IVideoEncodedFrameObserver
83
86
  ): number;
84
87
 
85
88
  /**
86
- * Registers a facial information observer.
89
+ * Registers a face information observer.
87
90
  *
88
- * You can call this method to register the onFaceInfo callback to receive the facial information processed by Agora speech driven extension. When calling this method to register a facial information observer, you can register callbacks in the IFaceInfoObserver class as needed. After successfully registering the facial information observer, the SDK triggers the callback you have registered when it captures the facial information converted by the speech driven extension.
89
- * Call this method before joining a channel.
90
- * Before calling this method, you need to make sure that the speech driven extension has been enabled by calling enableExtension.
91
+ * You can call this method to register the onFaceInfo callback to obtain face information processed by the Agora voice driver plugin. When registering a face information observer using this method, you can register the callbacks in the IFaceInfoObserver class as needed. After successful registration, the SDK triggers the registered callback when face information converted by the voice driver plugin is detected.
92
+ * This method must be called before joining a channel.
93
+ * Before calling this method, make sure you have called enableExtension to enable the voice driver plugin.
91
94
  *
92
- * @param observer Facial information observer, see IFaceInfoObserver.
95
+ * @param observer The face information observer. See IFaceInfoObserver.
93
96
  *
94
97
  * @returns
95
98
  * 0: Success.
96
- * < 0: Failure.
99
+ * < 0: Failure. See [Error Codes](https://docs.agora.io/en/video-calling/troubleshooting/error-codes) for details and resolution suggestions.
97
100
  */
98
101
  abstract registerFaceInfoObserver(observer: IFaceInfoObserver): number;
99
102
 
100
103
  /**
101
- * Pushes the external audio frame.
104
+ * Pushes external audio frames.
102
105
  *
103
- * Call this method to push external audio frames through the audio track.
106
+ * Call this method to push external audio frames through an audio track.
104
107
  *
105
108
  * @param frame The external audio frame. See AudioFrame.
106
- * @param trackId The audio track ID. If you want to publish a custom external audio source, set this parameter to the ID of the corresponding custom audio track you want to publish.
109
+ * @param trackId The audio track ID. If you want to publish a custom external audio source, set this parameter to the custom audio track ID you want to publish.
107
110
  *
108
111
  * @returns
109
112
  * 0: Success.
110
- * < 0: Failure.
113
+ * < 0: Failure. See [Error Codes](https://docs.agora.io/en/video-calling/troubleshooting/error-codes) for details and resolution suggestions.
111
114
  */
112
115
  abstract pushAudioFrame(frame: AudioFrame, trackId?: number): number;
113
116
 
114
117
  /**
115
- * Pulls the remote audio data.
118
+ * Pulls remote audio data.
116
119
  *
117
- * After a successful call of this method, the app pulls the decoded and mixed audio data for playback.
120
+ * After calling this method, the app actively pulls the decoded and mixed remote audio data for audio playback. This method and the onPlaybackAudioFrame callback can both be used to obtain the mixed remote audio playback data. After calling setExternalAudioSink to enable external audio rendering, the app will no longer receive data from the onPlaybackAudioFrame callback. Therefore, choose between this method and the onPlaybackAudioFrame callback based on your actual business needs. The two have different handling mechanisms. The differences are as follows:
121
+ * After calling this method, the app actively pulls audio data. By setting the audio data, the SDK can adjust the buffer to help the app handle latency, effectively avoiding audio playback jitter.
122
+ * After registering the onPlaybackAudioFrame callback, the SDK delivers audio data to the app through the callback. When the app handles audio frame latency, it may cause audio playback jitter. This method is only used to pull mixed remote audio playback data. To obtain the original captured audio data, or the original playback data of each stream before mixing, call registerAudioFrameObserver to register the corresponding callback.
118
123
  *
119
124
  * @returns
120
- * The AudioFrame instance, if the method call succeeds.
121
- * An error code, if the call fails,.
125
+ * If the method call succeeds, returns an AudioFrame object.
126
+ * If the method call fails, returns an error code.
122
127
  */
123
128
  abstract pullAudioFrame(frame: AudioFrame): number;
124
129
 
125
130
  /**
126
- * Configures the external video source.
131
+ * Sets the external video source.
127
132
  *
128
- * After calling this method to enable an external video source, you can call pushVideoFrame to push external video data to the SDK.
133
+ * After calling this method to enable the external video source, you can call pushVideoFrame to push external video data to the SDK. Dynamic switching of video sources within a channel is not supported. If you have enabled the external video source and joined a channel, to switch to the internal video source, you must leave the channel first, then call this method to disable the external video source, and rejoin the channel.
129
134
  *
130
- * @param enabled Whether to use the external video source: true : Use the external video source. The SDK prepares to accept the external video frame. false : (Default) Do not use the external video source.
131
- * @param useTexture Whether to use the external video frame in the Texture format. true : Use the external video frame in the Texture format. false : (Default) Do not use the external video frame in the Texture format.
135
+ * @param enabled Whether to enable the external video source: true : Enable the external video source. The SDK is ready to receive external video frames. false : (Default) Do not enable the external video source.
136
+ * @param useTexture Whether to use external video frames in Texture format: true : Use external video frames in Texture format. false : Do not use external video frames in Texture format.
132
137
  * @param sourceType Whether the external video frame is encoded. See ExternalVideoSourceType.
133
- * @param encodedVideoOption Video encoding options. This parameter needs to be set if sourceType is EncodedVideoFrame. To set this parameter, contact.
138
+ * @param encodedVideoOption Video encoding options. If sourceType is EncodedVideoFrame, you need to set this parameter. You can [contact technical support](https://www.agora.io/cn/contact/) to learn how to configure this parameter.
134
139
  *
135
140
  * @returns
136
141
  * 0: Success.
137
- * < 0: Failure.
142
+ * < 0: Failure. See [Error Codes](https://docs.agora.io/en/video-calling/troubleshooting/error-codes) for details and resolution suggestions.
138
143
  */
139
144
  abstract setExternalVideoSource(
140
145
  enabled: boolean,
@@ -149,19 +154,19 @@ export abstract class IMediaEngine {
149
154
  abstract setExternalRemoteEglContext(eglContext: any): number;
150
155
 
151
156
  /**
152
- * Sets the external audio source parameters.
157
+ * Sets external audio capture parameters.
153
158
  *
154
- * Deprecated: This method is deprecated, use createCustomAudioTrack instead.
159
+ * Deprecated Deprecated: This method is deprecated. Use createCustomAudioTrack instead.
155
160
  *
156
- * @param enabled Whether to enable the external audio source: true : Enable the external audio source. false : (Default) Disable the external audio source.
157
- * @param sampleRate The sample rate (Hz) of the external audio source which can be set as 8000, 16000, 32000, 44100, or 48000.
158
- * @param channels The number of channels of the external audio source, which can be set as 1 (Mono) or 2 (Stereo).
159
- * @param localPlayback Whether to play the external audio source: true : Play the external audio source. false : (Default) Do not play the external source.
160
- * @param publish Whether to publish audio to the remote users: true : (Default) Publish audio to the remote users. false : Do not publish audio to the remote users.
161
+ * @param enabled Whether to enable the use of external audio sources: true : Enable external audio source. false : (Default) Disable external audio source.
162
+ * @param sampleRate Sampling rate (Hz) of the external audio source. Can be set to 8000, 16000, 32000, 44100, or 48000.
163
+ * @param channels Number of channels of the external audio source. Can be set to 1 (mono) or 2 (stereo).
164
+ * @param localPlayback Whether to play the external audio source locally: true : Play locally. false : (Default) Do not play locally.
165
+ * @param publish Whether to publish the audio to the remote end: true : (Default) Publish to remote. false : Do not publish to remote.
161
166
  *
162
167
  * @returns
163
168
  * 0: Success.
164
- * < 0: Failure.
169
+ * < 0: Failure. See [Error Codes](https://docs.agora.io/en/video-calling/troubleshooting/error-codes) for details and resolution suggestions.
165
170
  */
166
171
  abstract setExternalAudioSource(
167
172
  enabled: boolean,
@@ -172,19 +177,19 @@ export abstract class IMediaEngine {
172
177
  ): number;
173
178
 
174
179
  /**
175
- * Creates a custom audio track.
180
+ * Creates a custom audio capture track.
176
181
  *
177
- * Call this method before joining a channel. To publish a custom audio source, see the following steps:
178
- * Call this method to create a custom audio track and get the audio track ID.
179
- * Call joinChannel to join the channel. In ChannelMediaOptions, set publishCustomAudioTrackId to the audio track ID that you want to publish, and set publishCustomAudioTrack to true.
180
- * Call pushAudioFrame and specify trackId as the audio track ID set in step 2. You can then publish the corresponding custom audio source in the channel.
182
+ * To publish custom captured audio in a channel, follow these steps:
183
+ * Call this method to create an audio track and obtain the audio track ID.
184
+ * When calling joinChannel to join a channel, set publishCustomAudioTrackId in ChannelMediaOptions to the audio track ID you want to publish, and set publishCustomAudioTrack to true.
185
+ * Call pushAudioFrame and set trackId to the audio track ID specified in step 2 to publish the corresponding custom audio source in the channel. This method must be called before joining a channel.
181
186
  *
182
- * @param trackType The type of the custom audio track. See AudioTrackType. If AudioTrackDirect is specified for this parameter, you must set publishMicrophoneTrack to false in ChannelMediaOptions when calling joinChannel to join the channel; otherwise, joining the channel fails and returns the error code -2.
183
- * @param config The configuration of the custom audio track. See AudioTrackConfig.
187
+ * @param trackType Custom audio track type. See AudioTrackType. If AudioTrackDirect is specified, you must set publishMicrophoneTrack in ChannelMediaOptions to false when calling joinChannel, otherwise joining the channel will fail and return error code -2.
188
+ * @param config Custom audio track configuration. See AudioTrackConfig.
184
189
  *
185
190
  * @returns
186
- * If the method call is successful, the audio track ID is returned as the unique identifier of the audio track.
187
- * If the method call fails, 0xffffffff is returned.
191
+ * If the method call succeeds, returns the audio track ID as the unique identifier of the audio track.
192
+ * If the method call fails, returns 0xffffffff. See [Error Codes](https://docs.agora.io/en/video-calling/troubleshooting/error-codes) for details and resolution suggestions.
188
193
  */
189
194
  abstract createCustomAudioTrack(
190
195
  trackType: AudioTrackType,
@@ -194,28 +199,28 @@ export abstract class IMediaEngine {
194
199
  /**
195
200
  * Destroys the specified audio track.
196
201
  *
197
- * @param trackId The custom audio track ID returned in createCustomAudioTrack.
202
+ * @param trackId Custom audio track ID returned by the createCustomAudioTrack method.
198
203
  *
199
204
  * @returns
200
205
  * 0: Success.
201
- * < 0: Failure.
206
+ * < 0: Failure. See [Error Codes](https://docs.agora.io/en/video-calling/troubleshooting/error-codes) for details and resolution suggestions.
202
207
  */
203
208
  abstract destroyCustomAudioTrack(trackId: number): number;
204
209
 
205
210
  /**
206
- * Sets the external audio sink.
211
+ * Sets external audio rendering.
207
212
  *
208
- * After enabling the external audio sink, you can call pullAudioFrame to pull remote audio frames. The app can process the remote audio and play it with the audio effects that you want.
213
+ * After calling this method to enable external audio rendering, you can call pullAudioFrame to pull remote audio data. The app can process the pulled raw audio data before rendering to achieve the desired audio effect. After calling this method to enable external audio rendering, the app will no longer receive data from the onPlaybackAudioFrame callback.
209
214
  *
210
- * @param enabled Whether to enable or disable the external audio sink: true : Enables the external audio sink. false : (Default) Disables the external audio sink.
211
- * @param sampleRate The sample rate (Hz) of the external audio sink, which can be set as 16000, 32000, 44100, or 48000.
212
- * @param channels The number of audio channels of the external audio sink:
213
- * 1: Mono.
214
- * 2: Stereo.
215
+ * @param enabled Whether to enable external audio rendering: true : Enable external audio rendering. false : (Default) Disable external audio rendering.
216
+ * @param sampleRate The sample rate (Hz) for external audio rendering. Can be set to 16000, 32000, 44100, or 48000.
217
+ * @param channels The number of channels for external audio rendering:
218
+ * 1: Mono
219
+ * 2: Stereo
215
220
  *
216
221
  * @returns
217
222
  * 0: Success.
218
- * < 0: Failure.
223
+ * < 0: Failure. See [Error Codes](https://docs.agora.io/en/video-calling/troubleshooting/error-codes) for details and resolution suggestions.
219
224
  */
220
225
  abstract setExternalAudioSink(
221
226
  enabled: boolean,
@@ -232,21 +237,21 @@ export abstract class IMediaEngine {
232
237
  ): number;
233
238
 
234
239
  /**
235
- * Pushes the external raw video frame to the SDK through video tracks.
240
+ * Publishes external raw video frames to the channel through a custom video track.
236
241
  *
237
- * To publish a custom video source, see the following steps:
242
+ * When you need to publish a custom captured video in the channel, follow these steps:
238
243
  * Call createCustomVideoTrack to create a video track and get the video track ID.
239
- * Call joinChannel to join the channel. In ChannelMediaOptions, set customVideoTrackId to the video track ID that you want to publish, and set publishCustomVideoTrack to true.
240
- * Call this method and specify videoTrackId as the video track ID set in step 2. You can then publish the corresponding custom video source in the channel. After calling this method, even if you stop pushing external video frames to the SDK, the custom video stream will still be counted as the video duration usage and incur charges. Agora recommends that you take appropriate measures based on the actual situation to avoid such video billing.
241
- * If you no longer need to capture external video data, you can call destroyCustomVideoTrack to destroy the custom video track.
242
- * If you only want to use the external video data for local preview and not publish it in the channel, you can call muteLocalVideoStream to cancel sending video stream or call updateChannelMediaOptions to set publishCustomVideoTrack to false.
244
+ * When calling joinChannel to join the channel, set customVideoTrackId in ChannelMediaOptions to the video track ID you want to publish, and set publishCustomVideoTrack to true.
245
+ * Call this method and specify videoTrackId as the video track ID from step 2 to publish the corresponding custom video source in the channel. After calling this method, even if you stop pushing external video frames to the SDK, the custom captured video stream will still be counted in video duration usage and incur charges. Agora recommends taking appropriate actions based on your actual needs to avoid such video billing:
246
+ * If you no longer need to capture external video data, call destroyCustomVideoTrack to destroy the custom captured video track.
247
+ * If you only want to use the captured external video data for local preview and not publish it in the channel, call muteLocalVideoStream to stop sending the video stream, or call updateChannelMediaOptions and set publishCustomVideoTrack to false.
243
248
  *
244
- * @param frame The external raw video frame to be pushed. See ExternalVideoFrame.
245
- * @param videoTrackId The video track ID returned by calling the createCustomVideoTrack method. The default value is 0.
249
+ * @param frame The video frame to be pushed. See ExternalVideoFrame.
250
+ * @param videoTrackId The video track ID returned by the createCustomVideoTrack method. If you only need to push a single external video stream, set videoTrackId to 0.
246
251
  *
247
252
  * @returns
248
253
  * 0: Success.
249
- * < 0: Failure.
254
+ * < 0: Failure. See [Error Codes](https://docs.agora.io/en/video-calling/troubleshooting/error-codes) for details and resolution suggestions.
250
255
  */
251
256
  abstract pushVideoFrame(
252
257
  frame: ExternalVideoFrame,
@@ -269,48 +274,48 @@ export abstract class IMediaEngine {
269
274
  abstract release(): void;
270
275
 
271
276
  /**
272
- * Unregisters an audio frame observer.
277
+ * Unregisters the audio frame observer.
273
278
  *
274
- * @param observer The audio frame observer, reporting the reception of each audio frame. See IAudioFrameObserver.
279
+ * @param observer The audio frame observer that monitors each received audio frame. See IAudioFrameObserver.
275
280
  *
276
281
  * @returns
277
282
  * 0: Success.
278
- * < 0: Failure.
283
+ * < 0: Failure. See [Error Codes](https://docs.agora.io/en/video-calling/troubleshooting/error-codes) for details and troubleshooting.
279
284
  */
280
285
  abstract unregisterAudioFrameObserver(observer: IAudioFrameObserver): number;
281
286
 
282
287
  /**
283
288
  * Unregisters the video frame observer.
284
289
  *
285
- * @param observer The video observer, reporting the reception of each video frame. See IVideoFrameObserver.
290
+ * @param observer The video frame observer that observes the reception of each video frame. See IVideoFrameObserver.
286
291
  *
287
292
  * @returns
288
293
  * 0: Success.
289
- * < 0: Failure.
294
+ * < 0: Failure. See [Error Codes](https://docs.agora.io/en/video-calling/troubleshooting/error-codes) for details and resolution suggestions.
290
295
  */
291
296
  abstract unregisterVideoFrameObserver(observer: IVideoFrameObserver): number;
292
297
 
293
298
  /**
294
- * Unregisters a receiver object for the encoded video frame.
299
+ * Unregisters the video frame observer for encoded video frames.
295
300
  *
296
- * @param observer The video observer, reporting the reception of each video frame. See IVideoEncodedFrameObserver.
301
+ * @param observer Video frame observer that observes the reception of each video frame. See IVideoEncodedFrameObserver.
297
302
  *
298
303
  * @returns
299
304
  * 0: Success.
300
- * < 0: Failure.
305
+ * < 0: Failure. See [Error Codes](https://docs.agora.io/en/video-calling/troubleshooting/error-codes) for details and resolution suggestions.
301
306
  */
302
307
  abstract unregisterVideoEncodedFrameObserver(
303
308
  observer: IVideoEncodedFrameObserver
304
309
  ): number;
305
310
 
306
311
  /**
307
- * Unregisters a facial information observer.
312
+ * Unregisters the face information observer.
308
313
  *
309
- * @param observer Facial information observer, see IFaceInfoObserver.
314
+ * @param observer The face information observer. See IFaceInfoObserver.
310
315
  *
311
316
  * @returns
312
317
  * 0: Success.
313
- * < 0: Failure.
318
+ * < 0: Failure. See [Error Codes](https://docs.agora.io/en/video-calling/troubleshooting/error-codes) for details and resolution suggestions.
314
319
  */
315
320
  abstract unregisterFaceInfoObserver(observer: IFaceInfoObserver): number;
316
321
  }