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
@@ -3,21 +3,21 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ILocalSpatialAudioEngine = exports.SpatialAudioZone = exports.RemoteVoicePositionInfo = void 0;
4
4
  require("./extension/IAgoraSpatialAudioExtension");
5
5
  /**
6
- * The spatial position of the remote user or the media player.
6
+ * Spatial position information of a remote user or media player.
7
7
  */
8
8
  class RemoteVoicePositionInfo {
9
9
  }
10
10
  exports.RemoteVoicePositionInfo = RemoteVoicePositionInfo;
11
11
  /**
12
- * Sound insulation area settings.
12
+ * Sound isolation zone settings.
13
13
  */
14
14
  class SpatialAudioZone {
15
15
  }
16
16
  exports.SpatialAudioZone = SpatialAudioZone;
17
17
  /**
18
- * This class calculates user positions through the SDK to implement the spatial audio effect.
18
+ * This class implements spatial audio by calculating user coordinates through the SDK.
19
19
  *
20
- * This class inherits from IBaseSpatialAudioEngine. Before calling other APIs in this class, you need to call the initialize method to initialize this class.
20
+ * This class inherits from IBaseSpatialAudioEngine. Before calling other APIs in this class, you need to call the initialize method to initialize it.
21
21
  */
22
22
  class ILocalSpatialAudioEngine {
23
23
  }
@@ -3,12 +3,12 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.IAudioDeviceManager = exports.MaxDeviceIdLengthType = void 0;
4
4
  require("./extension/IAudioDeviceManagerExtension");
5
5
  /**
6
- * The maximum length of the device ID.
6
+ * Maximum length of the device ID.
7
7
  */
8
8
  var MaxDeviceIdLengthType;
9
9
  (function (MaxDeviceIdLengthType) {
10
10
  /**
11
- * The maximum length of the device ID is 512 bytes.
11
+ * The maximum length of the device ID is 512 characters.
12
12
  */
13
13
  MaxDeviceIdLengthType[MaxDeviceIdLengthType["MaxDeviceIdLength"] = 512] = "MaxDeviceIdLength";
14
14
  })(MaxDeviceIdLengthType = exports.MaxDeviceIdLengthType || (exports.MaxDeviceIdLengthType = {}));
@@ -753,6 +753,16 @@ class IMediaPlayerImpl {
753
753
  getApiTypeFromSetSoundPositionParams(pan, gain) {
754
754
  return 'MediaPlayer_setSoundPositionParams_f282d50';
755
755
  }
756
+ getAudioBufferDelay() {
757
+ const apiType = this.getApiTypeFromGetAudioBufferDelay();
758
+ const jsonParams = {};
759
+ const jsonResults = IrisApiEngine_1.callIrisApi.call(this, apiType, jsonParams);
760
+ const delayMs = jsonResults.delayMs;
761
+ return delayMs;
762
+ }
763
+ getApiTypeFromGetAudioBufferDelay() {
764
+ return 'MediaPlayer_getAudioBufferDelay_c30e349';
765
+ }
756
766
  setPlayerOptionInInt(key, value) {
757
767
  const apiType = this.getApiTypeFromSetPlayerOptionInInt(key, value);
758
768
  const jsonParams = {
@@ -1017,6 +1017,80 @@ class IRtcEngineExImpl extends IAgoraRtcEngineImpl_1.IRtcEngineImpl {
1017
1017
  getApiTypeFromSendAudioMetadataEx(connection, metadata, length) {
1018
1018
  return 'RtcEngineEx_sendAudioMetadataEx_e2bf1c4';
1019
1019
  }
1020
+ enableVideoImageSourceEx(enable, options, connection) {
1021
+ const apiType = this.getApiTypeFromEnableVideoImageSourceEx(enable, options, connection);
1022
+ const jsonParams = {
1023
+ enable: enable,
1024
+ options: options,
1025
+ connection: connection,
1026
+ toJSON: () => {
1027
+ return {
1028
+ enable: enable,
1029
+ options: options,
1030
+ connection: connection,
1031
+ };
1032
+ },
1033
+ };
1034
+ const jsonResults = IrisApiEngine_1.callIrisApi.call(this, apiType, jsonParams);
1035
+ return jsonResults.result;
1036
+ }
1037
+ getApiTypeFromEnableVideoImageSourceEx(enable, options, connection) {
1038
+ return 'RtcEngineEx_enableVideoImageSourceEx_b63f346';
1039
+ }
1040
+ preloadEffectEx(connection, soundId, filePath, startPos = 0) {
1041
+ const apiType = this.getApiTypeFromPreloadEffectEx(connection, soundId, filePath, startPos);
1042
+ const jsonParams = {
1043
+ connection: connection,
1044
+ soundId: soundId,
1045
+ filePath: filePath,
1046
+ startPos: startPos,
1047
+ toJSON: () => {
1048
+ return {
1049
+ connection: connection,
1050
+ soundId: soundId,
1051
+ filePath: filePath,
1052
+ startPos: startPos,
1053
+ };
1054
+ },
1055
+ };
1056
+ const jsonResults = IrisApiEngine_1.callIrisApi.call(this, apiType, jsonParams);
1057
+ return jsonResults.result;
1058
+ }
1059
+ getApiTypeFromPreloadEffectEx(connection, soundId, filePath, startPos = 0) {
1060
+ return 'RtcEngineEx_preloadEffectEx_c9fae88';
1061
+ }
1062
+ playEffectEx(connection, soundId, filePath, loopCount, pitch, pan, gain, publish = false, startPos = 0) {
1063
+ const apiType = this.getApiTypeFromPlayEffectEx(connection, soundId, filePath, loopCount, pitch, pan, gain, publish, startPos);
1064
+ const jsonParams = {
1065
+ connection: connection,
1066
+ soundId: soundId,
1067
+ filePath: filePath,
1068
+ loopCount: loopCount,
1069
+ pitch: pitch,
1070
+ pan: pan,
1071
+ gain: gain,
1072
+ publish: publish,
1073
+ startPos: startPos,
1074
+ toJSON: () => {
1075
+ return {
1076
+ connection: connection,
1077
+ soundId: soundId,
1078
+ filePath: filePath,
1079
+ loopCount: loopCount,
1080
+ pitch: pitch,
1081
+ pan: pan,
1082
+ gain: gain,
1083
+ publish: publish,
1084
+ startPos: startPos,
1085
+ };
1086
+ },
1087
+ };
1088
+ const jsonResults = IrisApiEngine_1.callIrisApi.call(this, apiType, jsonParams);
1089
+ return jsonResults.result;
1090
+ }
1091
+ getApiTypeFromPlayEffectEx(connection, soundId, filePath, loopCount, pitch, pan, gain, publish = false, startPos = 0) {
1092
+ return 'RtcEngineEx_playEffectEx_ae5345c';
1093
+ }
1020
1094
  takeSnapshotWithConfigEx(connection, uid, config) {
1021
1095
  const apiType = this.getApiTypeFromTakeSnapshotWithConfigEx(connection, uid, config);
1022
1096
  const jsonParams = {
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.IRtcEngineImpl = exports.processIDirectCdnStreamingEventHandler = exports.processIMetadataObserver = exports.IVideoDeviceManagerImpl = exports.processIRtcEngineEventHandler = void 0;
3
+ exports.IRtcEngineImpl = exports.processIDirectCdnStreamingEventHandler = exports.processIMetadataObserver = exports.IVideoEffectObjectImpl = exports.IVideoDeviceManagerImpl = exports.processIRtcEngineEventHandler = void 0;
4
4
  const AgoraBase_1 = require("../AgoraBase");
5
5
  const AgoraMediaBase_1 = require("../AgoraMediaBase");
6
6
  function processIRtcEngineEventHandler(handler, event, jsonParams) {
@@ -120,6 +120,11 @@ function processIRtcEngineEventHandler(handler, event, jsonParams) {
120
120
  handler.onVideoSizeChanged(jsonParams.connection, jsonParams.sourceType, jsonParams.uid, jsonParams.width, jsonParams.height, jsonParams.rotation);
121
121
  }
122
122
  break;
123
+ case 'onLocalVideoEvent':
124
+ if (handler.onLocalVideoEvent !== undefined) {
125
+ handler.onLocalVideoEvent(jsonParams.source, jsonParams.event);
126
+ }
127
+ break;
123
128
  case 'onLocalVideoStateChanged':
124
129
  if (handler.onLocalVideoStateChanged !== undefined) {
125
130
  handler.onLocalVideoStateChanged(jsonParams.source, jsonParams.state, jsonParams.reason);
@@ -480,6 +485,11 @@ function processIRtcEngineEventHandler(handler, event, jsonParams) {
480
485
  handler.onSetRtmFlagResult(jsonParams.connection, jsonParams.code);
481
486
  }
482
487
  break;
488
+ case 'onMultipathStats':
489
+ if (handler.onMultipathStats !== undefined) {
490
+ handler.onMultipathStats(jsonParams.connection, jsonParams.stats);
491
+ }
492
+ break;
483
493
  }
484
494
  }
485
495
  exports.processIRtcEngineEventHandler = processIRtcEngineEventHandler;
@@ -590,6 +600,196 @@ class IVideoDeviceManagerImpl {
590
600
  }
591
601
  }
592
602
  exports.IVideoDeviceManagerImpl = IVideoDeviceManagerImpl;
603
+ // @ts-ignore
604
+ class IVideoEffectObjectImpl {
605
+ addOrUpdateVideoEffect(nodeId, templateName) {
606
+ const apiType = this.getApiTypeFromAddOrUpdateVideoEffect(nodeId, templateName);
607
+ const jsonParams = {
608
+ nodeId: nodeId,
609
+ templateName: templateName,
610
+ toJSON: () => {
611
+ return {
612
+ nodeId: nodeId,
613
+ templateName: templateName,
614
+ };
615
+ },
616
+ };
617
+ const jsonResults = IrisApiEngine_1.callIrisApi.call(this, apiType, jsonParams);
618
+ return jsonResults.result;
619
+ }
620
+ getApiTypeFromAddOrUpdateVideoEffect(nodeId, templateName) {
621
+ return 'VideoEffectObject_addOrUpdateVideoEffect_303a98c';
622
+ }
623
+ removeVideoEffect(nodeId) {
624
+ const apiType = this.getApiTypeFromRemoveVideoEffect(nodeId);
625
+ const jsonParams = {
626
+ nodeId: nodeId,
627
+ toJSON: () => {
628
+ return {
629
+ nodeId: nodeId,
630
+ };
631
+ },
632
+ };
633
+ const jsonResults = IrisApiEngine_1.callIrisApi.call(this, apiType, jsonParams);
634
+ return jsonResults.result;
635
+ }
636
+ getApiTypeFromRemoveVideoEffect(nodeId) {
637
+ return 'VideoEffectObject_removeVideoEffect_b48de50';
638
+ }
639
+ performVideoEffectAction(nodeId, actionId) {
640
+ const apiType = this.getApiTypeFromPerformVideoEffectAction(nodeId, actionId);
641
+ const jsonParams = {
642
+ nodeId: nodeId,
643
+ actionId: actionId,
644
+ toJSON: () => {
645
+ return {
646
+ nodeId: nodeId,
647
+ actionId: actionId,
648
+ };
649
+ },
650
+ };
651
+ const jsonResults = IrisApiEngine_1.callIrisApi.call(this, apiType, jsonParams);
652
+ return jsonResults.result;
653
+ }
654
+ getApiTypeFromPerformVideoEffectAction(nodeId, actionId) {
655
+ return 'VideoEffectObject_performVideoEffectAction_eddb1a6';
656
+ }
657
+ setVideoEffectStringParam(option, key, param) {
658
+ const apiType = this.getApiTypeFromSetVideoEffectStringParam(option, key, param);
659
+ const jsonParams = {
660
+ option: option,
661
+ key: key,
662
+ param: param,
663
+ toJSON: () => {
664
+ return {
665
+ option: option,
666
+ key: key,
667
+ param: param,
668
+ };
669
+ },
670
+ };
671
+ const jsonResults = IrisApiEngine_1.callIrisApi.call(this, apiType, jsonParams);
672
+ return jsonResults.result;
673
+ }
674
+ getApiTypeFromSetVideoEffectStringParam(option, key, param) {
675
+ return 'VideoEffectObject_setVideoEffectStringParam_0e4f59e';
676
+ }
677
+ setVideoEffectFloatParam(option, key, param) {
678
+ const apiType = this.getApiTypeFromSetVideoEffectFloatParam(option, key, param);
679
+ const jsonParams = {
680
+ option: option,
681
+ key: key,
682
+ param: param,
683
+ toJSON: () => {
684
+ return {
685
+ option: option,
686
+ key: key,
687
+ param: param,
688
+ };
689
+ },
690
+ };
691
+ const jsonResults = IrisApiEngine_1.callIrisApi.call(this, apiType, jsonParams);
692
+ return jsonResults.result;
693
+ }
694
+ getApiTypeFromSetVideoEffectFloatParam(option, key, param) {
695
+ return 'VideoEffectObject_setVideoEffectFloatParam_e8dfcf8';
696
+ }
697
+ setVideoEffectIntParam(option, key, param) {
698
+ const apiType = this.getApiTypeFromSetVideoEffectIntParam(option, key, param);
699
+ const jsonParams = {
700
+ option: option,
701
+ key: key,
702
+ param: param,
703
+ toJSON: () => {
704
+ return {
705
+ option: option,
706
+ key: key,
707
+ param: param,
708
+ };
709
+ },
710
+ };
711
+ const jsonResults = IrisApiEngine_1.callIrisApi.call(this, apiType, jsonParams);
712
+ return jsonResults.result;
713
+ }
714
+ getApiTypeFromSetVideoEffectIntParam(option, key, param) {
715
+ return 'VideoEffectObject_setVideoEffectIntParam_3b77680';
716
+ }
717
+ setVideoEffectBoolParam(option, key, param) {
718
+ const apiType = this.getApiTypeFromSetVideoEffectBoolParam(option, key, param);
719
+ const jsonParams = {
720
+ option: option,
721
+ key: key,
722
+ param: param,
723
+ toJSON: () => {
724
+ return {
725
+ option: option,
726
+ key: key,
727
+ param: param,
728
+ };
729
+ },
730
+ };
731
+ const jsonResults = IrisApiEngine_1.callIrisApi.call(this, apiType, jsonParams);
732
+ return jsonResults.result;
733
+ }
734
+ getApiTypeFromSetVideoEffectBoolParam(option, key, param) {
735
+ return 'VideoEffectObject_setVideoEffectBoolParam_918930f';
736
+ }
737
+ getVideoEffectFloatParam(option, key) {
738
+ const apiType = this.getApiTypeFromGetVideoEffectFloatParam(option, key);
739
+ const jsonParams = {
740
+ option: option,
741
+ key: key,
742
+ toJSON: () => {
743
+ return {
744
+ option: option,
745
+ key: key,
746
+ };
747
+ },
748
+ };
749
+ const jsonResults = IrisApiEngine_1.callIrisApi.call(this, apiType, jsonParams);
750
+ return jsonResults.result;
751
+ }
752
+ getApiTypeFromGetVideoEffectFloatParam(option, key) {
753
+ return 'VideoEffectObject_getVideoEffectFloatParam_ccad422';
754
+ }
755
+ getVideoEffectIntParam(option, key) {
756
+ const apiType = this.getApiTypeFromGetVideoEffectIntParam(option, key);
757
+ const jsonParams = {
758
+ option: option,
759
+ key: key,
760
+ toJSON: () => {
761
+ return {
762
+ option: option,
763
+ key: key,
764
+ };
765
+ },
766
+ };
767
+ const jsonResults = IrisApiEngine_1.callIrisApi.call(this, apiType, jsonParams);
768
+ return jsonResults.result;
769
+ }
770
+ getApiTypeFromGetVideoEffectIntParam(option, key) {
771
+ return 'VideoEffectObject_getVideoEffectIntParam_ccad422';
772
+ }
773
+ getVideoEffectBoolParam(option, key) {
774
+ const apiType = this.getApiTypeFromGetVideoEffectBoolParam(option, key);
775
+ const jsonParams = {
776
+ option: option,
777
+ key: key,
778
+ toJSON: () => {
779
+ return {
780
+ option: option,
781
+ key: key,
782
+ };
783
+ },
784
+ };
785
+ const jsonResults = IrisApiEngine_1.callIrisApi.call(this, apiType, jsonParams);
786
+ return jsonResults.result;
787
+ }
788
+ getApiTypeFromGetVideoEffectBoolParam(option, key) {
789
+ return 'VideoEffectObject_getVideoEffectBoolParam_ccad422';
790
+ }
791
+ }
792
+ exports.IVideoEffectObjectImpl = IVideoEffectObjectImpl;
593
793
  function processIMetadataObserver(handler, event, jsonParams) {
594
794
  switch (event) {
595
795
  case 'onMetadataReceived':
@@ -1089,6 +1289,38 @@ class IRtcEngineImpl {
1089
1289
  getApiTypeFromSetFilterEffectOptions(enabled, options, type = AgoraMediaBase_1.MediaSourceType.PrimaryCameraSource) {
1090
1290
  return 'RtcEngine_setFilterEffectOptions_53b4be3';
1091
1291
  }
1292
+ createVideoEffectObject(bundlePath, type = AgoraMediaBase_1.MediaSourceType.PrimaryCameraSource) {
1293
+ const apiType = this.getApiTypeFromCreateVideoEffectObject(bundlePath, type);
1294
+ const jsonParams = {
1295
+ bundlePath: bundlePath,
1296
+ type: type,
1297
+ toJSON: () => {
1298
+ return {
1299
+ bundlePath: bundlePath,
1300
+ type: type,
1301
+ };
1302
+ },
1303
+ };
1304
+ const jsonResults = IrisApiEngine_1.callIrisApi.call(this, apiType, jsonParams);
1305
+ return jsonResults.result;
1306
+ }
1307
+ getApiTypeFromCreateVideoEffectObject(bundlePath, type = AgoraMediaBase_1.MediaSourceType.PrimaryCameraSource) {
1308
+ return 'RtcEngine_createVideoEffectObject_65bd50d';
1309
+ }
1310
+ destroyVideoEffectObject(videoEffectObject) {
1311
+ const apiType = this.getApiTypeFromDestroyVideoEffectObject(videoEffectObject);
1312
+ const jsonParams = {
1313
+ videoEffectObject: videoEffectObject,
1314
+ toJSON: () => {
1315
+ return {};
1316
+ },
1317
+ };
1318
+ const jsonResults = IrisApiEngine_1.callIrisApi.call(this, apiType, jsonParams);
1319
+ return jsonResults.result;
1320
+ }
1321
+ getApiTypeFromDestroyVideoEffectObject(videoEffectObject) {
1322
+ return 'RtcEngine_destroyVideoEffectObject_66d092b';
1323
+ }
1092
1324
  setLowlightEnhanceOptions(enabled, options, type = AgoraMediaBase_1.MediaSourceType.PrimaryCameraSource) {
1093
1325
  const apiType = this.getApiTypeFromSetLowlightEnhanceOptions(enabled, options, type);
1094
1326
  const jsonParams = {
@@ -9,6 +9,7 @@ const json_bigint_1 = __importDefault(require("json-bigint"));
9
9
  const JSON = (0, json_bigint_1.default)({ storeAsString: true });
10
10
  const AgoraSdk_1 = __importDefault(require("../../AgoraSdk"));
11
11
  const Utils_1 = require("../../Utils");
12
+ const AgoraMediaBase_1 = require("../AgoraMediaBase");
12
13
  const AgoraBaseImpl_1 = require("../impl/AgoraBaseImpl");
13
14
  const AgoraMediaBaseImpl_1 = require("../impl/AgoraMediaBaseImpl");
14
15
  const IAgoraH265TranscoderImpl_1 = require("../impl/IAgoraH265TranscoderImpl");
@@ -200,6 +201,32 @@ exports.EVENT_PROCESSORS = {
200
201
  case 'onStreamMessageEx':
201
202
  data.data = buffers[0];
202
203
  break;
204
+ case 'onLocalVideoStats':
205
+ if (data) {
206
+ let rendererManager = Utils_1.AgoraEnv.AgoraRendererManager;
207
+ if (rendererManager) {
208
+ let sourceType = data.sourceType;
209
+ let connection = data.connection;
210
+ let rendererCaches = rendererManager.getRendererCachesBySourceType(sourceType);
211
+ rendererCaches.forEach((cache) => {
212
+ cache.setCallbackContext(connection, sourceType);
213
+ });
214
+ }
215
+ }
216
+ break;
217
+ case 'onRemoteVideoStats':
218
+ if (data) {
219
+ let rendererManager = Utils_1.AgoraEnv.AgoraRendererManager;
220
+ if (rendererManager) {
221
+ let connection = data.connection;
222
+ const sourceType = AgoraMediaBase_1.VideoSourceType.VideoSourceRemote;
223
+ let rendererCaches = rendererManager.getRendererCachesBySourceType(sourceType);
224
+ rendererCaches.forEach((cache) => {
225
+ cache.setCallbackContext(connection, sourceType);
226
+ });
227
+ }
228
+ }
229
+ break;
203
230
  }
204
231
  },
205
232
  handlers: (event, data) => RtcEngineExInternal_1.RtcEngineExInternal._event_handlers,
@@ -298,12 +325,15 @@ function callIrisApi(funcName, params) {
298
325
  // frame.buffer
299
326
  buffers.push(params.frame.buffer);
300
327
  // frame.eglContext
328
+ // @ts-ignore
301
329
  buffers.push(Buffer.from(''));
302
330
  // frame.metadata_buffer
331
+ // @ts-ignore
303
332
  buffers.push(Buffer.from(''));
304
333
  // frame.alphaBuffer
305
334
  buffers.push(params.frame.alphaBuffer);
306
335
  // frame.d3d11_texture_2d
336
+ // @ts-ignore
307
337
  buffers.push(Buffer.from(''));
308
338
  break;
309
339
  case 'MediaEngine_pushEncodedVideoImage_e71452b':
@@ -321,6 +351,14 @@ function callIrisApi(funcName, params) {
321
351
  return { ...json, playerId: params.mediaPlayerId };
322
352
  };
323
353
  }
354
+ else if (funcName.startsWith('VideoEffectObject_')) {
355
+ params.videoEffectObjectId = // @ts-ignore
356
+ this.getVideoEffectObjectId();
357
+ const json = params.toJSON?.call();
358
+ params.toJSON = function () {
359
+ return { ...json, objectId: params.videoEffectObjectId };
360
+ };
361
+ }
324
362
  else if (funcName.startsWith('MediaRecorder_')) {
325
363
  // @ts-ignore
326
364
  params.nativeHandle = this.nativeHandle;
@@ -353,6 +391,13 @@ function callIrisApi(funcName, params) {
353
391
  return { playerId: params.mediaPlayerId };
354
392
  };
355
393
  break;
394
+ case 'RtcEngine_destroyVideoEffectObject_66d092b':
395
+ params.videoEffectObjectId =
396
+ params.videoEffectObject.getVideoEffectObjectId();
397
+ params.toJSON = function () {
398
+ return { objectId: params.videoEffectObjectId };
399
+ };
400
+ break;
356
401
  case 'RtcEngine_destroyMediaRecorder_95cdef5':
357
402
  // @ts-ignore
358
403
  params.nativeHandle = params.mediaRecorder.nativeHandle;
@@ -34,6 +34,7 @@ const MediaEngineInternal_1 = require("./MediaEngineInternal");
34
34
  const MediaPlayerInternal_1 = require("./MediaPlayerInternal");
35
35
  const MediaRecorderInternal_1 = require("./MediaRecorderInternal");
36
36
  const MusicContentCenterInternal_1 = require("./MusicContentCenterInternal");
37
+ const VideoEffectObjectInternal_1 = require("./VideoEffectObjectInternal");
37
38
  const checkers = (0, ts_interface_checker_1.createCheckers)(AgoraBase_ti_1.default, AgoraMediaBase_ti_1.default, IAgoraRtcEngine_ti_1.default);
38
39
  class RtcEngineExInternal extends IAgoraRtcEngineExImpl_1.IRtcEngineExImpl {
39
40
  constructor() {
@@ -44,6 +45,11 @@ class RtcEngineExInternal extends IAgoraRtcEngineExImpl_1.IRtcEngineExImpl {
44
45
  this._music_content_center = new MusicContentCenterInternal_1.MusicContentCenterInternal();
45
46
  this._local_spatial_audio_engine = new LocalSpatialAudioEngineInternal_1.LocalSpatialAudioEngineInternal();
46
47
  this._h265_transcoder = new AgoraH265TranscoderInternal_1.H265TranscoderInternal();
48
+ this.performanceInterval = 6000;
49
+ this.VideoRemoteRenderMeanFpsCounterId = 537;
50
+ this.VideoRemoteRenderDrawCostCounterId = 576;
51
+ this.VideoLocalRenderMeanFpsCounterId = 526;
52
+ this.VideoLocalRenderDrawCostCounterId = 577;
47
53
  }
48
54
  initialize(context) {
49
55
  const ret = super.initialize(context);
@@ -59,6 +65,59 @@ class RtcEngineExInternal extends IAgoraRtcEngineExImpl_1.IRtcEngineExImpl {
59
65
  if (Utils_1.AgoraEnv.CapabilityManager === undefined && CapabilityManager) {
60
66
  Utils_1.AgoraEnv.CapabilityManager = new CapabilityManager();
61
67
  }
68
+ if (Utils_1.AgoraEnv.enableArgusCounters) {
69
+ try {
70
+ this.performanceIntervalFunc = setInterval(() => {
71
+ let rendererManager = Utils_1.AgoraEnv.AgoraRendererManager;
72
+ let counters = [];
73
+ if (rendererManager) {
74
+ rendererManager.getRendererCaches().forEach((cache) => {
75
+ const isRemote = cache.callbackContext.sourceType ===
76
+ AgoraMediaBase_1.VideoSourceType.VideoSourceRemote;
77
+ if (cache.callbackContext.connection?.channelId &&
78
+ (cache.callbackContext.connection?.localUid || isRemote)) {
79
+ let counter = counters.find((counter) => counter.connection.channelId ===
80
+ cache.callbackContext.connection.channelId &&
81
+ counter.connection.localUid ===
82
+ cache.callbackContext.connection.localUid);
83
+ let data = {
84
+ counters: [
85
+ {
86
+ counterId: isRemote
87
+ ? this.VideoRemoteRenderMeanFpsCounterId
88
+ : this.VideoLocalRenderMeanFpsCounterId,
89
+ value: Math.floor(cache.actualFps),
90
+ },
91
+ {
92
+ counterId: isRemote
93
+ ? this.VideoRemoteRenderDrawCostCounterId
94
+ : this.VideoLocalRenderDrawCostCounterId,
95
+ value: Math.floor(cache.avgFrameInterval),
96
+ },
97
+ ],
98
+ uid: isRemote ? cache.cacheContext.uid : 0,
99
+ };
100
+ if (!counter) {
101
+ counters.push({
102
+ data: [data],
103
+ connection: cache.callbackContext.connection,
104
+ });
105
+ }
106
+ else {
107
+ counter.data.push(data);
108
+ }
109
+ }
110
+ });
111
+ }
112
+ counters.forEach((counter) => {
113
+ this.setParameters(JSON.stringify({ 'rtc.report.argus_counters': counter }));
114
+ });
115
+ }, this.performanceInterval);
116
+ }
117
+ catch (error) {
118
+ (0, Utils_1.logDebug)('argus counters report error', error);
119
+ }
120
+ }
62
121
  }
63
122
  return ret;
64
123
  }
@@ -85,6 +144,10 @@ class RtcEngineExInternal extends IAgoraRtcEngineExImpl_1.IRtcEngineExImpl {
85
144
  this.removeAllListeners();
86
145
  Utils_1.AgoraEnv.CapabilityManager?.release();
87
146
  Utils_1.AgoraEnv.CapabilityManager = undefined;
147
+ if (this.performanceIntervalFunc) {
148
+ clearInterval(this.performanceIntervalFunc);
149
+ this.performanceIntervalFunc = undefined;
150
+ }
88
151
  super.release(sync);
89
152
  }
90
153
  _addListenerPreCheck(eventType) {
@@ -209,10 +272,6 @@ class RtcEngineExInternal extends IAgoraRtcEngineExImpl_1.IRtcEngineExImpl {
209
272
  RtcEngineExInternal._metadata_observer.filter((value) => value !== observer);
210
273
  return super.unregisterMediaMetadataObserver(observer, type);
211
274
  }
212
- setVideoEncoderConfiguration(config) {
213
- Utils_1.AgoraEnv.encodeAlpha = config?.advanceOptions?.encodeAlpha ?? false;
214
- return super.setVideoEncoderConfiguration(config);
215
- }
216
275
  getApiTypeFromJoinChannel(token, channelId, uid, options) {
217
276
  if (Utils_1.AgoraEnv.AgoraRendererManager) {
218
277
  Utils_1.AgoraEnv.AgoraRendererManager.defaultChannelId = channelId;
@@ -318,12 +377,14 @@ class RtcEngineExInternal extends IAgoraRtcEngineExImpl_1.IRtcEngineExImpl {
318
377
  value.thumbImage.buffer = undefined;
319
378
  }
320
379
  else {
380
+ // @ts-ignore
321
381
  value.thumbImage.buffer = IrisApiEngine_1.AgoraElectronBridge.GetBuffer(value.thumbImage.buffer, value.thumbImage.length);
322
382
  }
323
383
  if (!value.iconImage?.buffer || !value.iconImage?.length) {
324
384
  value.iconImage.buffer = undefined;
325
385
  }
326
386
  else {
387
+ // @ts-ignore
327
388
  value.iconImage.buffer = IrisApiEngine_1.AgoraElectronBridge.GetBuffer(value.iconImage.buffer, value.iconImage.length);
328
389
  }
329
390
  value.sourceDisplayId = (0, Utils_1.parseIntPtr2Number)(value.sourceDisplayId);
@@ -421,6 +482,15 @@ class RtcEngineExInternal extends IAgoraRtcEngineExImpl_1.IRtcEngineExImpl {
421
482
  uid,
422
483
  });
423
484
  }
485
+ createVideoEffectObject(bundlePath, type) {
486
+ // @ts-ignore
487
+ const videoEffectObjectId = super.createVideoEffectObject(bundlePath, type);
488
+ return new VideoEffectObjectInternal_1.VideoEffectObjectInternal(videoEffectObjectId);
489
+ }
490
+ destroyVideoEffectObject(videoEffectObject) {
491
+ const ret = super.destroyVideoEffectObject(videoEffectObject);
492
+ return ret;
493
+ }
424
494
  }
425
495
  exports.RtcEngineExInternal = RtcEngineExInternal;
426
496
  RtcEngineExInternal._event_handlers = [];
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.VideoEffectObjectInternal = void 0;
4
+ const IAgoraRtcEngineImpl_1 = require("../impl/IAgoraRtcEngineImpl");
5
+ class VideoEffectObjectInternal extends IAgoraRtcEngineImpl_1.IVideoEffectObjectImpl {
6
+ constructor(videoEffectObjectId) {
7
+ super();
8
+ this._videoEffectObjectId = videoEffectObjectId;
9
+ }
10
+ getVideoEffectObjectId() {
11
+ return this._videoEffectObjectId;
12
+ }
13
+ }
14
+ exports.VideoEffectObjectInternal = VideoEffectObjectInternal;
@@ -53,6 +53,7 @@ exports.IRtcEngineEventHandler = t.iface([], {
53
53
  "onFirstLocalVideoFramePublished": t.opt(t.func("void", t.param("connection", "RtcConnection"), t.param("elapsed", "number"))),
54
54
  "onFirstRemoteVideoDecoded": t.opt(t.func("void", t.param("connection", "RtcConnection"), t.param("remoteUid", "number"), t.param("width", "number"), t.param("height", "number"), t.param("elapsed", "number"))),
55
55
  "onVideoSizeChanged": t.opt(t.func("void", t.param("connection", "RtcConnection"), t.param("sourceType", "VideoSourceType"), t.param("uid", "number"), t.param("width", "number"), t.param("height", "number"), t.param("rotation", "number"))),
56
+ "onLocalVideoEvent": t.opt(t.func("void", t.param("source", "VideoSourceType"), t.param("event", "LocalVideoEventType"))),
56
57
  "onLocalVideoStateChanged": t.opt(t.func("void", t.param("source", "VideoSourceType"), t.param("state", "LocalVideoStreamState"), t.param("reason", "LocalVideoStreamReason"))),
57
58
  "onRemoteVideoStateChanged": t.opt(t.func("void", t.param("connection", "RtcConnection"), t.param("remoteUid", "number"), t.param("state", "RemoteVideoState"), t.param("reason", "RemoteVideoStateReason"), t.param("elapsed", "number"))),
58
59
  "onFirstRemoteVideoFrame": t.opt(t.func("void", t.param("connection", "RtcConnection"), t.param("remoteUid", "number"), t.param("width", "number"), t.param("height", "number"), t.param("elapsed", "number"))),
@@ -125,6 +126,7 @@ exports.IRtcEngineEventHandler = t.iface([], {
125
126
  "onExtensionStoppedWithContext": t.opt(t.func("void", t.param("context", "ExtensionContext"))),
126
127
  "onExtensionErrorWithContext": t.opt(t.func("void", t.param("context", "ExtensionContext"), t.param("error", "number"), t.param("message", "string"))),
127
128
  "onSetRtmFlagResult": t.opt(t.func("void", t.param("connection", "RtcConnection"), t.param("code", "number"))),
129
+ "onMultipathStats": t.opt(t.func("void", t.param("connection", "RtcConnection"), t.param("stats", "MultipathStats"))),
128
130
  });
129
131
  exports.IMetadataObserver = t.iface([], {
130
132
  "onMetadataReceived": t.opt(t.func("void", t.param("metadata", "Metadata"))),