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.
- package/CHANGELOG.md +39 -0
- package/README.md +6 -3
- package/js/example/src/renderer/examples/advanced/VideoEffect/videoEffectHelpers.js +395 -0
- package/js/{AgoraSdk.js → ts/AgoraSdk.js} +2 -12
- package/js/{Decoder → ts/Decoder}/index.js +1 -1
- package/js/{Private → ts/Private}/AgoraBase.js +829 -674
- package/js/{Private → ts/Private}/AgoraMediaBase.js +154 -151
- package/js/{Private → ts/Private}/AgoraMediaPlayerTypes.js +58 -54
- package/js/{Private → ts/Private}/IAgoraLog.js +13 -13
- package/js/{Private → ts/Private}/IAgoraMediaEngine.js +4 -4
- package/js/{Private → ts/Private}/IAgoraMediaPlayer.js +2 -2
- package/js/{Private → ts/Private}/IAgoraMusicContentCenter.js +1 -1
- package/js/{Private → ts/Private}/IAgoraRhythmPlayer.js +13 -13
- package/js/{Private → ts/Private}/IAgoraRtcEngine.js +150 -94
- package/js/{Private → ts/Private}/IAgoraRtcEngineEx.js +3 -3
- package/js/{Private → ts/Private}/IAgoraSpatialAudio.js +4 -4
- package/js/{Private → ts/Private}/IAudioDeviceManager.js +2 -2
- package/js/{Private → ts/Private}/impl/IAgoraMediaPlayerImpl.js +10 -0
- package/js/{Private → ts/Private}/impl/IAgoraRtcEngineExImpl.js +74 -0
- package/js/{Private → ts/Private}/impl/IAgoraRtcEngineImpl.js +233 -1
- package/js/{Private → ts/Private}/internal/IrisApiEngine.js +45 -0
- package/js/{Private → ts/Private}/internal/RtcEngineExInternal.js +74 -4
- package/js/ts/Private/internal/VideoEffectObjectInternal.js +14 -0
- package/js/{Private → ts/Private}/ti/IAgoraRtcEngine-ti.js +2 -0
- package/js/{Renderer → ts/Renderer}/AgoraView.js +19 -2
- package/js/{Renderer → ts/Renderer}/IRenderer.js +7 -4
- package/js/{Renderer → ts/Renderer}/IRendererCache.js +17 -1
- package/js/ts/Renderer/RendererCache.js +252 -0
- package/js/{Renderer → ts/Renderer}/RendererManager.js +13 -64
- package/js/{Renderer → ts/Renderer}/WebCodecsRenderer/index.js +5 -5
- package/js/{Renderer → ts/Renderer}/WebCodecsRendererCache.js +13 -1
- package/js/{Renderer → ts/Renderer}/WebGLRenderer/index.js +179 -26
- package/js/{Renderer → ts/Renderer}/YUVCanvasRenderer/index.js +12 -5
- package/js/{Utils.js → ts/Utils.js} +7 -7
- package/package.json +25 -12
- package/scripts/checkElectron.js +4 -2
- package/scripts/download.js +102 -0
- package/scripts/downloadPrebuild.js +2 -1
- package/scripts/synclib.js +2 -2
- package/ts/AgoraSdk.ts +2 -12
- package/ts/Decoder/index.ts +5 -1
- package/ts/Private/AgoraBase.ts +1259 -1060
- package/ts/Private/AgoraMediaBase.ts +351 -324
- package/ts/Private/AgoraMediaPlayerTypes.ts +94 -91
- package/ts/Private/IAgoraLog.ts +20 -18
- package/ts/Private/IAgoraMediaEngine.ts +86 -81
- package/ts/Private/IAgoraMediaPlayer.ts +196 -181
- package/ts/Private/IAgoraMediaPlayerSource.ts +40 -40
- package/ts/Private/IAgoraMusicContentCenter.ts +3 -3
- package/ts/Private/IAgoraRhythmPlayer.ts +15 -15
- package/ts/Private/IAgoraRtcEngine.ts +2492 -2047
- package/ts/Private/IAgoraRtcEngineEx.ts +434 -335
- package/ts/Private/IAgoraSpatialAudio.ts +43 -45
- package/ts/Private/IAudioDeviceManager.ts +106 -97
- package/ts/Private/impl/IAgoraMediaPlayerImpl.ts +12 -0
- package/ts/Private/impl/IAgoraRtcEngineExImpl.ts +138 -0
- package/ts/Private/impl/IAgoraRtcEngineImpl.ts +331 -0
- package/ts/Private/internal/IrisApiEngine.ts +47 -0
- package/ts/Private/internal/RtcEngineExInternal.ts +106 -9
- package/ts/Private/internal/VideoEffectObjectInternal.ts +14 -0
- package/ts/Private/ti/IAgoraRtcEngine-ti.ts +2 -0
- package/ts/Renderer/AgoraView.ts +32 -3
- package/ts/Renderer/IRenderer.ts +8 -3
- package/ts/Renderer/IRendererCache.ts +33 -0
- package/ts/Renderer/RendererCache.ts +211 -12
- package/ts/Renderer/RendererManager.ts +21 -99
- package/ts/Renderer/WebCodecsRenderer/index.ts +9 -6
- package/ts/Renderer/WebCodecsRendererCache.ts +17 -1
- package/ts/Renderer/WebGLRenderer/index.ts +246 -40
- package/ts/Renderer/YUVCanvasRenderer/index.ts +29 -16
- package/ts/Types.ts +14 -9
- package/ts/Utils.ts +8 -7
- package/types/example/src/renderer/examples/advanced/VideoEffect/videoEffectHelpers.d.ts +168 -0
- package/types/example/src/renderer/examples/advanced/VideoEffect/videoEffectHelpers.d.ts.map +1 -0
- package/types/{AgoraSdk.d.ts → ts/AgoraSdk.d.ts} +2 -12
- package/types/ts/AgoraSdk.d.ts.map +1 -0
- package/types/ts/Decoder/gpu-utils.d.ts.map +1 -0
- package/types/ts/Decoder/index.d.ts.map +1 -0
- package/types/ts/Private/AgoraBase.d.ts +5504 -0
- package/types/ts/Private/AgoraBase.d.ts.map +1 -0
- package/types/ts/Private/AgoraMediaBase.d.ts +1695 -0
- package/types/ts/Private/AgoraMediaBase.d.ts.map +1 -0
- package/types/ts/Private/AgoraMediaPlayerTypes.d.ts +456 -0
- package/types/ts/Private/AgoraMediaPlayerTypes.d.ts.map +1 -0
- package/types/ts/Private/IAgoraH265Transcoder.d.ts.map +1 -0
- package/types/ts/Private/IAgoraLog.d.ts +91 -0
- package/types/ts/Private/IAgoraLog.d.ts.map +1 -0
- package/types/ts/Private/IAgoraMediaEngine.d.ts +255 -0
- package/types/ts/Private/IAgoraMediaEngine.d.ts.map +1 -0
- package/types/ts/Private/IAgoraMediaPlayer.d.ts +662 -0
- package/types/ts/Private/IAgoraMediaPlayer.d.ts.map +1 -0
- package/types/ts/Private/IAgoraMediaPlayerSource.d.ts +109 -0
- package/types/ts/Private/IAgoraMediaPlayerSource.d.ts.map +1 -0
- package/types/ts/Private/IAgoraMediaRecorder.d.ts.map +1 -0
- package/types/ts/Private/IAgoraMediaStreamingSource.d.ts.map +1 -0
- package/types/{Private → ts/Private}/IAgoraMusicContentCenter.d.ts +3 -3
- package/types/ts/Private/IAgoraMusicContentCenter.d.ts.map +1 -0
- package/types/ts/Private/IAgoraRhythmPlayer.d.ts +65 -0
- package/types/ts/Private/IAgoraRhythmPlayer.d.ts.map +1 -0
- package/types/ts/Private/IAgoraRtcEngine.d.ts +6504 -0
- package/types/ts/Private/IAgoraRtcEngine.d.ts.map +1 -0
- package/types/ts/Private/IAgoraRtcEngineEx.d.ts +817 -0
- package/types/ts/Private/IAgoraRtcEngineEx.d.ts.map +1 -0
- package/types/ts/Private/IAgoraSpatialAudio.d.ts +194 -0
- package/types/ts/Private/IAgoraSpatialAudio.d.ts.map +1 -0
- package/types/ts/Private/IAudioDeviceManager.d.ts +321 -0
- package/types/ts/Private/IAudioDeviceManager.d.ts.map +1 -0
- package/types/ts/Private/extension/AgoraBaseExtension.d.ts.map +1 -0
- package/types/ts/Private/extension/AgoraMediaBaseExtension.d.ts.map +1 -0
- package/types/ts/Private/extension/AgoraMediaPlayerTypesExtension.d.ts.map +1 -0
- package/types/ts/Private/extension/IAgoraH265TranscoderExtension.d.ts.map +1 -0
- package/types/ts/Private/extension/IAgoraLogExtension.d.ts.map +1 -0
- package/types/ts/Private/extension/IAgoraMediaEngineExtension.d.ts.map +1 -0
- package/types/ts/Private/extension/IAgoraMediaPlayerExtension.d.ts.map +1 -0
- package/types/ts/Private/extension/IAgoraMediaPlayerSourceExtension.d.ts.map +1 -0
- package/types/ts/Private/extension/IAgoraMediaRecorderExtension.d.ts.map +1 -0
- package/types/ts/Private/extension/IAgoraMusicContentCenterExtension.d.ts.map +1 -0
- package/types/ts/Private/extension/IAgoraRhythmPlayerExtension.d.ts.map +1 -0
- package/types/ts/Private/extension/IAgoraRtcEngineExExtension.d.ts.map +1 -0
- package/types/ts/Private/extension/IAgoraRtcEngineExtension.d.ts.map +1 -0
- package/types/ts/Private/extension/IAgoraSpatialAudioExtension.d.ts.map +1 -0
- package/types/ts/Private/extension/IAudioDeviceManagerExtension.d.ts.map +1 -0
- package/types/ts/Private/impl/AgoraBaseImpl.d.ts.map +1 -0
- package/types/ts/Private/impl/AgoraMediaBaseImpl.d.ts.map +1 -0
- package/types/ts/Private/impl/IAgoraH265TranscoderImpl.d.ts.map +1 -0
- package/types/ts/Private/impl/IAgoraMediaEngineImpl.d.ts.map +1 -0
- package/types/{Private → ts/Private}/impl/IAgoraMediaPlayerImpl.d.ts +2 -0
- package/types/ts/Private/impl/IAgoraMediaPlayerImpl.d.ts.map +1 -0
- package/types/ts/Private/impl/IAgoraMediaPlayerSourceImpl.d.ts.map +1 -0
- package/types/ts/Private/impl/IAgoraMediaRecorderImpl.d.ts.map +1 -0
- package/types/ts/Private/impl/IAgoraMusicContentCenterImpl.d.ts.map +1 -0
- package/types/{Private → ts/Private}/impl/IAgoraRtcEngineExImpl.d.ts +7 -1
- package/types/ts/Private/impl/IAgoraRtcEngineExImpl.d.ts.map +1 -0
- package/types/{Private → ts/Private}/impl/IAgoraRtcEngineImpl.d.ts +27 -1
- package/types/ts/Private/impl/IAgoraRtcEngineImpl.d.ts.map +1 -0
- package/types/ts/Private/impl/IAgoraSpatialAudioImpl.d.ts.map +1 -0
- package/types/ts/Private/impl/IAudioDeviceManagerImpl.d.ts.map +1 -0
- package/types/ts/Private/internal/AgoraH265TranscoderInternal.d.ts.map +1 -0
- package/types/ts/Private/internal/AgoraMediaBaseInternal.d.ts.map +1 -0
- package/types/ts/Private/internal/AudioDeviceManagerInternal.d.ts.map +1 -0
- package/types/ts/Private/internal/IrisApiEngine.d.ts.map +1 -0
- package/types/ts/Private/internal/LocalSpatialAudioEngineInternal.d.ts.map +1 -0
- package/types/ts/Private/internal/MediaEngineInternal.d.ts.map +1 -0
- package/types/ts/Private/internal/MediaPlayerInternal.d.ts.map +1 -0
- package/types/ts/Private/internal/MediaRecorderInternal.d.ts.map +1 -0
- package/types/ts/Private/internal/MusicContentCenterInternal.d.ts.map +1 -0
- package/types/{Private → ts/Private}/internal/RtcEngineExInternal.d.ts +10 -4
- package/types/ts/Private/internal/RtcEngineExInternal.d.ts.map +1 -0
- package/types/ts/Private/internal/VideoEffectObjectInternal.d.ts +7 -0
- package/types/ts/Private/internal/VideoEffectObjectInternal.d.ts.map +1 -0
- package/types/{Private → ts/Private}/ipc/main.d.ts.map +1 -1
- package/types/ts/Private/ipc/renderer.d.ts.map +1 -0
- package/types/ts/Private/ti/AgoraBase-ti.d.ts.map +1 -0
- package/types/ts/Private/ti/AgoraMediaBase-ti.d.ts.map +1 -0
- package/types/ts/Private/ti/AgoraMediaPlayerTypes-ti.d.ts.map +1 -0
- package/types/ts/Private/ti/IAgoraH265Transcoder-ti.d.ts.map +1 -0
- package/types/ts/Private/ti/IAgoraLog-ti.d.ts.map +1 -0
- package/types/ts/Private/ti/IAgoraMediaEngine-ti.d.ts.map +1 -0
- package/types/ts/Private/ti/IAgoraMediaPlayer-ti.d.ts.map +1 -0
- package/types/ts/Private/ti/IAgoraMediaPlayerSource-ti.d.ts.map +1 -0
- package/types/ts/Private/ti/IAgoraMediaRecorder-ti.d.ts.map +1 -0
- package/types/ts/Private/ti/IAgoraMediaStreamingSource-ti.d.ts.map +1 -0
- package/types/ts/Private/ti/IAgoraMusicContentCenter-ti.d.ts.map +1 -0
- package/types/ts/Private/ti/IAgoraRhythmPlayer-ti.d.ts.map +1 -0
- package/types/ts/Private/ti/IAgoraRtcEngine-ti.d.ts.map +1 -0
- package/types/ts/Private/ti/IAgoraRtcEngineEx-ti.d.ts.map +1 -0
- package/types/ts/Private/ti/IAgoraSpatialAudio-ti.d.ts.map +1 -0
- package/types/ts/Private/ti/IAudioDeviceManager-ti.d.ts.map +1 -0
- package/types/{Renderer → ts/Renderer}/AgoraView.d.ts +6 -0
- package/types/ts/Renderer/AgoraView.d.ts.map +1 -0
- package/types/ts/Renderer/CapabilityManager.d.ts.map +1 -0
- package/types/{Renderer → ts/Renderer}/IRenderer.d.ts +2 -2
- package/types/ts/Renderer/IRenderer.d.ts.map +1 -0
- package/types/{Renderer → ts/Renderer}/IRendererCache.d.ts +21 -1
- package/types/ts/Renderer/IRendererCache.d.ts.map +1 -0
- package/types/{Renderer → ts/Renderer}/RendererCache.d.ts +27 -0
- package/types/ts/Renderer/RendererCache.d.ts.map +1 -0
- package/types/{Renderer → ts/Renderer}/RendererManager.d.ts +4 -17
- package/types/ts/Renderer/RendererManager.d.ts.map +1 -0
- package/types/{Renderer → ts/Renderer}/WebCodecsRenderer/index.d.ts +3 -3
- package/types/ts/Renderer/WebCodecsRenderer/index.d.ts.map +1 -0
- package/types/{Renderer → ts/Renderer}/WebCodecsRendererCache.d.ts +7 -0
- package/types/ts/Renderer/WebCodecsRendererCache.d.ts.map +1 -0
- package/types/{Renderer → ts/Renderer}/WebGLRenderer/index.d.ts +12 -2
- package/types/ts/Renderer/WebGLRenderer/index.d.ts.map +1 -0
- package/types/ts/Renderer/WebGLRenderer/webgl-utils.d.ts.map +1 -0
- package/types/ts/Renderer/YUVCanvasRenderer/index.d.ts +10 -0
- package/types/ts/Renderer/YUVCanvasRenderer/index.d.ts.map +1 -0
- package/types/ts/Renderer/index.d.ts.map +1 -0
- package/types/{Types.d.ts → ts/Types.d.ts} +11 -6
- package/types/ts/Types.d.ts.map +1 -0
- package/types/{Utils.d.ts → ts/Utils.d.ts} +1 -1
- package/types/ts/Utils.d.ts.map +1 -0
- package/js/Renderer/RendererCache.js +0 -100
- package/types/AgoraSdk.d.ts.map +0 -1
- package/types/Decoder/gpu-utils.d.ts.map +0 -1
- package/types/Decoder/index.d.ts.map +0 -1
- package/types/Private/AgoraBase.d.ts +0 -5310
- package/types/Private/AgoraBase.d.ts.map +0 -1
- package/types/Private/AgoraMediaBase.d.ts +0 -1668
- package/types/Private/AgoraMediaBase.d.ts.map +0 -1
- package/types/Private/AgoraMediaPlayerTypes.d.ts +0 -453
- package/types/Private/AgoraMediaPlayerTypes.d.ts.map +0 -1
- package/types/Private/IAgoraH265Transcoder.d.ts.map +0 -1
- package/types/Private/IAgoraLog.d.ts +0 -89
- package/types/Private/IAgoraLog.d.ts.map +0 -1
- package/types/Private/IAgoraMediaEngine.d.ts +0 -250
- package/types/Private/IAgoraMediaEngine.d.ts.map +0 -1
- package/types/Private/IAgoraMediaPlayer.d.ts +0 -648
- package/types/Private/IAgoraMediaPlayer.d.ts.map +0 -1
- package/types/Private/IAgoraMediaPlayerSource.d.ts +0 -109
- package/types/Private/IAgoraMediaPlayerSource.d.ts.map +0 -1
- package/types/Private/IAgoraMediaRecorder.d.ts.map +0 -1
- package/types/Private/IAgoraMediaStreamingSource.d.ts.map +0 -1
- package/types/Private/IAgoraMusicContentCenter.d.ts.map +0 -1
- package/types/Private/IAgoraRhythmPlayer.d.ts +0 -65
- package/types/Private/IAgoraRhythmPlayer.d.ts.map +0 -1
- package/types/Private/IAgoraRtcEngine.d.ts +0 -6103
- package/types/Private/IAgoraRtcEngine.d.ts.map +0 -1
- package/types/Private/IAgoraRtcEngineEx.d.ts +0 -741
- package/types/Private/IAgoraRtcEngineEx.d.ts.map +0 -1
- package/types/Private/IAgoraSpatialAudio.d.ts +0 -196
- package/types/Private/IAgoraSpatialAudio.d.ts.map +0 -1
- package/types/Private/IAudioDeviceManager.d.ts +0 -312
- package/types/Private/IAudioDeviceManager.d.ts.map +0 -1
- package/types/Private/extension/AgoraBaseExtension.d.ts.map +0 -1
- package/types/Private/extension/AgoraMediaBaseExtension.d.ts.map +0 -1
- package/types/Private/extension/AgoraMediaPlayerTypesExtension.d.ts.map +0 -1
- package/types/Private/extension/IAgoraH265TranscoderExtension.d.ts.map +0 -1
- package/types/Private/extension/IAgoraLogExtension.d.ts.map +0 -1
- package/types/Private/extension/IAgoraMediaEngineExtension.d.ts.map +0 -1
- package/types/Private/extension/IAgoraMediaPlayerExtension.d.ts.map +0 -1
- package/types/Private/extension/IAgoraMediaPlayerSourceExtension.d.ts.map +0 -1
- package/types/Private/extension/IAgoraMediaRecorderExtension.d.ts.map +0 -1
- package/types/Private/extension/IAgoraMusicContentCenterExtension.d.ts.map +0 -1
- package/types/Private/extension/IAgoraRhythmPlayerExtension.d.ts.map +0 -1
- package/types/Private/extension/IAgoraRtcEngineExExtension.d.ts.map +0 -1
- package/types/Private/extension/IAgoraRtcEngineExtension.d.ts.map +0 -1
- package/types/Private/extension/IAgoraSpatialAudioExtension.d.ts.map +0 -1
- package/types/Private/extension/IAudioDeviceManagerExtension.d.ts.map +0 -1
- package/types/Private/impl/AgoraBaseImpl.d.ts.map +0 -1
- package/types/Private/impl/AgoraMediaBaseImpl.d.ts.map +0 -1
- package/types/Private/impl/IAgoraH265TranscoderImpl.d.ts.map +0 -1
- package/types/Private/impl/IAgoraMediaEngineImpl.d.ts.map +0 -1
- package/types/Private/impl/IAgoraMediaPlayerImpl.d.ts.map +0 -1
- package/types/Private/impl/IAgoraMediaPlayerSourceImpl.d.ts.map +0 -1
- package/types/Private/impl/IAgoraMediaRecorderImpl.d.ts.map +0 -1
- package/types/Private/impl/IAgoraMusicContentCenterImpl.d.ts.map +0 -1
- package/types/Private/impl/IAgoraRtcEngineExImpl.d.ts.map +0 -1
- package/types/Private/impl/IAgoraRtcEngineImpl.d.ts.map +0 -1
- package/types/Private/impl/IAgoraSpatialAudioImpl.d.ts.map +0 -1
- package/types/Private/impl/IAudioDeviceManagerImpl.d.ts.map +0 -1
- package/types/Private/internal/AgoraH265TranscoderInternal.d.ts.map +0 -1
- package/types/Private/internal/AgoraMediaBaseInternal.d.ts.map +0 -1
- package/types/Private/internal/AudioDeviceManagerInternal.d.ts.map +0 -1
- package/types/Private/internal/IrisApiEngine.d.ts.map +0 -1
- package/types/Private/internal/LocalSpatialAudioEngineInternal.d.ts.map +0 -1
- package/types/Private/internal/MediaEngineInternal.d.ts.map +0 -1
- package/types/Private/internal/MediaPlayerInternal.d.ts.map +0 -1
- package/types/Private/internal/MediaRecorderInternal.d.ts.map +0 -1
- package/types/Private/internal/MusicContentCenterInternal.d.ts.map +0 -1
- package/types/Private/internal/RtcEngineExInternal.d.ts.map +0 -1
- package/types/Private/ipc/renderer.d.ts.map +0 -1
- package/types/Private/ti/AgoraBase-ti.d.ts.map +0 -1
- package/types/Private/ti/AgoraMediaBase-ti.d.ts.map +0 -1
- package/types/Private/ti/AgoraMediaPlayerTypes-ti.d.ts.map +0 -1
- package/types/Private/ti/IAgoraH265Transcoder-ti.d.ts.map +0 -1
- package/types/Private/ti/IAgoraLog-ti.d.ts.map +0 -1
- package/types/Private/ti/IAgoraMediaEngine-ti.d.ts.map +0 -1
- package/types/Private/ti/IAgoraMediaPlayer-ti.d.ts.map +0 -1
- package/types/Private/ti/IAgoraMediaPlayerSource-ti.d.ts.map +0 -1
- package/types/Private/ti/IAgoraMediaRecorder-ti.d.ts.map +0 -1
- package/types/Private/ti/IAgoraMediaStreamingSource-ti.d.ts.map +0 -1
- package/types/Private/ti/IAgoraMusicContentCenter-ti.d.ts.map +0 -1
- package/types/Private/ti/IAgoraRhythmPlayer-ti.d.ts.map +0 -1
- package/types/Private/ti/IAgoraRtcEngine-ti.d.ts.map +0 -1
- package/types/Private/ti/IAgoraRtcEngineEx-ti.d.ts.map +0 -1
- package/types/Private/ti/IAgoraSpatialAudio-ti.d.ts.map +0 -1
- package/types/Private/ti/IAudioDeviceManager-ti.d.ts.map +0 -1
- package/types/Renderer/AgoraView.d.ts.map +0 -1
- package/types/Renderer/CapabilityManager.d.ts.map +0 -1
- package/types/Renderer/IRenderer.d.ts.map +0 -1
- package/types/Renderer/IRendererCache.d.ts.map +0 -1
- package/types/Renderer/RendererCache.d.ts.map +0 -1
- package/types/Renderer/RendererManager.d.ts.map +0 -1
- package/types/Renderer/WebCodecsRenderer/index.d.ts.map +0 -1
- package/types/Renderer/WebCodecsRendererCache.d.ts.map +0 -1
- package/types/Renderer/WebGLRenderer/index.d.ts.map +0 -1
- package/types/Renderer/WebGLRenderer/webgl-utils.d.ts.map +0 -1
- package/types/Renderer/YUVCanvasRenderer/index.d.ts +0 -9
- package/types/Renderer/YUVCanvasRenderer/index.d.ts.map +0 -1
- package/types/Renderer/index.d.ts.map +0 -1
- package/types/Types.d.ts.map +0 -1
- package/types/Utils.d.ts.map +0 -1
- /package/js/{Decoder → ts/Decoder}/gpu-utils.js +0 -0
- /package/js/{Private → ts/Private}/IAgoraH265Transcoder.js +0 -0
- /package/js/{Private → ts/Private}/IAgoraMediaPlayerSource.js +0 -0
- /package/js/{Private → ts/Private}/IAgoraMediaRecorder.js +0 -0
- /package/js/{Private → ts/Private}/IAgoraMediaStreamingSource.js +0 -0
- /package/js/{Private → ts/Private}/extension/AgoraBaseExtension.js +0 -0
- /package/js/{Private → ts/Private}/extension/AgoraMediaBaseExtension.js +0 -0
- /package/js/{Private → ts/Private}/extension/AgoraMediaPlayerTypesExtension.js +0 -0
- /package/js/{Private → ts/Private}/extension/IAgoraH265TranscoderExtension.js +0 -0
- /package/js/{Private → ts/Private}/extension/IAgoraLogExtension.js +0 -0
- /package/js/{Private → ts/Private}/extension/IAgoraMediaEngineExtension.js +0 -0
- /package/js/{Private → ts/Private}/extension/IAgoraMediaPlayerExtension.js +0 -0
- /package/js/{Private → ts/Private}/extension/IAgoraMediaPlayerSourceExtension.js +0 -0
- /package/js/{Private → ts/Private}/extension/IAgoraMediaRecorderExtension.js +0 -0
- /package/js/{Private → ts/Private}/extension/IAgoraMusicContentCenterExtension.js +0 -0
- /package/js/{Private → ts/Private}/extension/IAgoraRhythmPlayerExtension.js +0 -0
- /package/js/{Private → ts/Private}/extension/IAgoraRtcEngineExExtension.js +0 -0
- /package/js/{Private → ts/Private}/extension/IAgoraRtcEngineExtension.js +0 -0
- /package/js/{Private → ts/Private}/extension/IAgoraSpatialAudioExtension.js +0 -0
- /package/js/{Private → ts/Private}/extension/IAudioDeviceManagerExtension.js +0 -0
- /package/js/{Private → ts/Private}/impl/AgoraBaseImpl.js +0 -0
- /package/js/{Private → ts/Private}/impl/AgoraMediaBaseImpl.js +0 -0
- /package/js/{Private → ts/Private}/impl/IAgoraH265TranscoderImpl.js +0 -0
- /package/js/{Private → ts/Private}/impl/IAgoraMediaEngineImpl.js +0 -0
- /package/js/{Private → ts/Private}/impl/IAgoraMediaPlayerSourceImpl.js +0 -0
- /package/js/{Private → ts/Private}/impl/IAgoraMediaRecorderImpl.js +0 -0
- /package/js/{Private → ts/Private}/impl/IAgoraMusicContentCenterImpl.js +0 -0
- /package/js/{Private → ts/Private}/impl/IAgoraSpatialAudioImpl.js +0 -0
- /package/js/{Private → ts/Private}/impl/IAudioDeviceManagerImpl.js +0 -0
- /package/js/{Private → ts/Private}/internal/AgoraH265TranscoderInternal.js +0 -0
- /package/js/{Private → ts/Private}/internal/AgoraMediaBaseInternal.js +0 -0
- /package/js/{Private → ts/Private}/internal/AudioDeviceManagerInternal.js +0 -0
- /package/js/{Private → ts/Private}/internal/LocalSpatialAudioEngineInternal.js +0 -0
- /package/js/{Private → ts/Private}/internal/MediaEngineInternal.js +0 -0
- /package/js/{Private → ts/Private}/internal/MediaPlayerInternal.js +0 -0
- /package/js/{Private → ts/Private}/internal/MediaRecorderInternal.js +0 -0
- /package/js/{Private → ts/Private}/internal/MusicContentCenterInternal.js +0 -0
- /package/js/{Private → ts/Private}/ipc/main.js +0 -0
- /package/js/{Private → ts/Private}/ipc/renderer.js +0 -0
- /package/js/{Private → ts/Private}/ti/AgoraBase-ti.js +0 -0
- /package/js/{Private → ts/Private}/ti/AgoraMediaBase-ti.js +0 -0
- /package/js/{Private → ts/Private}/ti/AgoraMediaPlayerTypes-ti.js +0 -0
- /package/js/{Private → ts/Private}/ti/IAgoraH265Transcoder-ti.js +0 -0
- /package/js/{Private → ts/Private}/ti/IAgoraLog-ti.js +0 -0
- /package/js/{Private → ts/Private}/ti/IAgoraMediaEngine-ti.js +0 -0
- /package/js/{Private → ts/Private}/ti/IAgoraMediaPlayer-ti.js +0 -0
- /package/js/{Private → ts/Private}/ti/IAgoraMediaPlayerSource-ti.js +0 -0
- /package/js/{Private → ts/Private}/ti/IAgoraMediaRecorder-ti.js +0 -0
- /package/js/{Private → ts/Private}/ti/IAgoraMediaStreamingSource-ti.js +0 -0
- /package/js/{Private → ts/Private}/ti/IAgoraMusicContentCenter-ti.js +0 -0
- /package/js/{Private → ts/Private}/ti/IAgoraRhythmPlayer-ti.js +0 -0
- /package/js/{Private → ts/Private}/ti/IAgoraRtcEngineEx-ti.js +0 -0
- /package/js/{Private → ts/Private}/ti/IAgoraSpatialAudio-ti.js +0 -0
- /package/js/{Private → ts/Private}/ti/IAudioDeviceManager-ti.js +0 -0
- /package/js/{Renderer → ts/Renderer}/CapabilityManager.js +0 -0
- /package/js/{Renderer → ts/Renderer}/WebGLRenderer/webgl-utils.js +0 -0
- /package/js/{Renderer → ts/Renderer}/index.js +0 -0
- /package/js/{Types.js → ts/Types.js} +0 -0
- /package/types/{Decoder → ts/Decoder}/gpu-utils.d.ts +0 -0
- /package/types/{Decoder → ts/Decoder}/index.d.ts +0 -0
- /package/types/{Private → ts/Private}/IAgoraH265Transcoder.d.ts +0 -0
- /package/types/{Private → ts/Private}/IAgoraMediaRecorder.d.ts +0 -0
- /package/types/{Private → ts/Private}/IAgoraMediaStreamingSource.d.ts +0 -0
- /package/types/{Private → ts/Private}/extension/AgoraBaseExtension.d.ts +0 -0
- /package/types/{Private → ts/Private}/extension/AgoraMediaBaseExtension.d.ts +0 -0
- /package/types/{Private → ts/Private}/extension/AgoraMediaPlayerTypesExtension.d.ts +0 -0
- /package/types/{Private → ts/Private}/extension/IAgoraH265TranscoderExtension.d.ts +0 -0
- /package/types/{Private → ts/Private}/extension/IAgoraLogExtension.d.ts +0 -0
- /package/types/{Private → ts/Private}/extension/IAgoraMediaEngineExtension.d.ts +0 -0
- /package/types/{Private → ts/Private}/extension/IAgoraMediaPlayerExtension.d.ts +0 -0
- /package/types/{Private → ts/Private}/extension/IAgoraMediaPlayerSourceExtension.d.ts +0 -0
- /package/types/{Private → ts/Private}/extension/IAgoraMediaRecorderExtension.d.ts +0 -0
- /package/types/{Private → ts/Private}/extension/IAgoraMusicContentCenterExtension.d.ts +0 -0
- /package/types/{Private → ts/Private}/extension/IAgoraRhythmPlayerExtension.d.ts +0 -0
- /package/types/{Private → ts/Private}/extension/IAgoraRtcEngineExExtension.d.ts +0 -0
- /package/types/{Private → ts/Private}/extension/IAgoraRtcEngineExtension.d.ts +0 -0
- /package/types/{Private → ts/Private}/extension/IAgoraSpatialAudioExtension.d.ts +0 -0
- /package/types/{Private → ts/Private}/extension/IAudioDeviceManagerExtension.d.ts +0 -0
- /package/types/{Private → ts/Private}/impl/AgoraBaseImpl.d.ts +0 -0
- /package/types/{Private → ts/Private}/impl/AgoraMediaBaseImpl.d.ts +0 -0
- /package/types/{Private → ts/Private}/impl/IAgoraH265TranscoderImpl.d.ts +0 -0
- /package/types/{Private → ts/Private}/impl/IAgoraMediaEngineImpl.d.ts +0 -0
- /package/types/{Private → ts/Private}/impl/IAgoraMediaPlayerSourceImpl.d.ts +0 -0
- /package/types/{Private → ts/Private}/impl/IAgoraMediaRecorderImpl.d.ts +0 -0
- /package/types/{Private → ts/Private}/impl/IAgoraMusicContentCenterImpl.d.ts +0 -0
- /package/types/{Private → ts/Private}/impl/IAgoraSpatialAudioImpl.d.ts +0 -0
- /package/types/{Private → ts/Private}/impl/IAudioDeviceManagerImpl.d.ts +0 -0
- /package/types/{Private → ts/Private}/internal/AgoraH265TranscoderInternal.d.ts +0 -0
- /package/types/{Private → ts/Private}/internal/AgoraMediaBaseInternal.d.ts +0 -0
- /package/types/{Private → ts/Private}/internal/AudioDeviceManagerInternal.d.ts +0 -0
- /package/types/{Private → ts/Private}/internal/IrisApiEngine.d.ts +0 -0
- /package/types/{Private → ts/Private}/internal/LocalSpatialAudioEngineInternal.d.ts +0 -0
- /package/types/{Private → ts/Private}/internal/MediaEngineInternal.d.ts +0 -0
- /package/types/{Private → ts/Private}/internal/MediaPlayerInternal.d.ts +0 -0
- /package/types/{Private → ts/Private}/internal/MediaRecorderInternal.d.ts +0 -0
- /package/types/{Private → ts/Private}/internal/MusicContentCenterInternal.d.ts +0 -0
- /package/types/{Private → ts/Private}/ipc/main.d.ts +0 -0
- /package/types/{Private → ts/Private}/ipc/renderer.d.ts +0 -0
- /package/types/{Private → ts/Private}/ti/AgoraBase-ti.d.ts +0 -0
- /package/types/{Private → ts/Private}/ti/AgoraMediaBase-ti.d.ts +0 -0
- /package/types/{Private → ts/Private}/ti/AgoraMediaPlayerTypes-ti.d.ts +0 -0
- /package/types/{Private → ts/Private}/ti/IAgoraH265Transcoder-ti.d.ts +0 -0
- /package/types/{Private → ts/Private}/ti/IAgoraLog-ti.d.ts +0 -0
- /package/types/{Private → ts/Private}/ti/IAgoraMediaEngine-ti.d.ts +0 -0
- /package/types/{Private → ts/Private}/ti/IAgoraMediaPlayer-ti.d.ts +0 -0
- /package/types/{Private → ts/Private}/ti/IAgoraMediaPlayerSource-ti.d.ts +0 -0
- /package/types/{Private → ts/Private}/ti/IAgoraMediaRecorder-ti.d.ts +0 -0
- /package/types/{Private → ts/Private}/ti/IAgoraMediaStreamingSource-ti.d.ts +0 -0
- /package/types/{Private → ts/Private}/ti/IAgoraMusicContentCenter-ti.d.ts +0 -0
- /package/types/{Private → ts/Private}/ti/IAgoraRhythmPlayer-ti.d.ts +0 -0
- /package/types/{Private → ts/Private}/ti/IAgoraRtcEngine-ti.d.ts +0 -0
- /package/types/{Private → ts/Private}/ti/IAgoraRtcEngineEx-ti.d.ts +0 -0
- /package/types/{Private → ts/Private}/ti/IAgoraSpatialAudio-ti.d.ts +0 -0
- /package/types/{Private → ts/Private}/ti/IAudioDeviceManager-ti.d.ts +0 -0
- /package/types/{Renderer → ts/Renderer}/CapabilityManager.d.ts +0 -0
- /package/types/{Renderer → ts/Renderer}/WebGLRenderer/webgl-utils.d.ts +0 -0
- /package/types/{Renderer → ts/Renderer}/index.d.ts +0 -0
|
@@ -16,7 +16,7 @@ import {
|
|
|
16
16
|
} from './AgoraMediaBase';
|
|
17
17
|
|
|
18
18
|
/**
|
|
19
|
-
*
|
|
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
|
|
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
|
|
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
|
|
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
|
-
*
|
|
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
|
|
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
|
|
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
|
|
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
|
|
74
|
+
* Registers a video frame observer for encoded video frames.
|
|
72
75
|
*
|
|
73
|
-
* If you only want to observe encoded video frames (
|
|
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
|
|
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
|
|
89
|
+
* Registers a face information observer.
|
|
87
90
|
*
|
|
88
|
-
* You can call this method to register the onFaceInfo callback to
|
|
89
|
-
*
|
|
90
|
-
* Before calling this method,
|
|
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
|
|
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
|
|
104
|
+
* Pushes external audio frames.
|
|
102
105
|
*
|
|
103
|
-
* Call this method to push external audio frames through
|
|
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
|
|
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
|
|
118
|
+
* Pulls remote audio data.
|
|
116
119
|
*
|
|
117
|
-
* After
|
|
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
|
-
*
|
|
121
|
-
*
|
|
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
|
-
*
|
|
131
|
+
* Sets the external video source.
|
|
127
132
|
*
|
|
128
|
-
* After calling this method to enable
|
|
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
|
|
131
|
-
* @param useTexture Whether to use
|
|
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.
|
|
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
|
|
157
|
+
* Sets external audio capture parameters.
|
|
153
158
|
*
|
|
154
|
-
* Deprecated: This method is deprecated
|
|
159
|
+
* Deprecated Deprecated: This method is deprecated. Use createCustomAudioTrack instead.
|
|
155
160
|
*
|
|
156
|
-
* @param enabled Whether to enable the external audio
|
|
157
|
-
* @param sampleRate
|
|
158
|
-
* @param channels
|
|
159
|
-
* @param localPlayback Whether to play the external audio source: true : Play
|
|
160
|
-
* @param publish Whether to publish audio to the remote
|
|
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
|
-
*
|
|
178
|
-
* Call this method to create
|
|
179
|
-
*
|
|
180
|
-
* Call pushAudioFrame and
|
|
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
|
|
183
|
-
* @param config
|
|
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
|
|
187
|
-
* If the method call fails, 0xffffffff
|
|
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
|
|
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
|
|
211
|
+
* Sets external audio rendering.
|
|
207
212
|
*
|
|
208
|
-
* After
|
|
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
|
|
211
|
-
* @param sampleRate The sample rate (Hz)
|
|
212
|
-
* @param channels The number of
|
|
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
|
-
*
|
|
240
|
+
* Publishes external raw video frames to the channel through a custom video track.
|
|
236
241
|
*
|
|
237
|
-
*
|
|
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
|
-
*
|
|
240
|
-
* Call this method and specify videoTrackId as the video track ID
|
|
241
|
-
* If you no longer need to capture external video data,
|
|
242
|
-
* If you only want to use the external video data for local preview and not publish it in the channel,
|
|
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
|
|
245
|
-
* @param videoTrackId The video track ID returned by
|
|
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
|
|
277
|
+
* Unregisters the audio frame observer.
|
|
273
278
|
*
|
|
274
|
-
* @param observer The audio frame observer
|
|
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
|
|
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
|
|
299
|
+
* Unregisters the video frame observer for encoded video frames.
|
|
295
300
|
*
|
|
296
|
-
* @param observer
|
|
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
|
|
312
|
+
* Unregisters the face information observer.
|
|
308
313
|
*
|
|
309
|
-
* @param observer
|
|
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
|
}
|