Agora RTC Objective-C API Reference Refactor

IAgoraService.h
Go to the documentation of this file.
1 // Agora SDK
2 //
3 // Copyright (c) 2018 Agora.io. All rights reserved.
4 //
5
6 #pragma once // NOLINT(build/header_guard)
7
8 #include "IAgoraLog.h"
9 #include "AgoraBase.h"
10 #include "AgoraOptional.h"
11 #include <api/cpp/aosl_ares_class.h>
12
13 namespace agora {
14 class ILocalDataChannel;
15 class IRemoteDataChannel;
16 struct DataChannelConfig;
17
18 namespace rtc {
19 class IRtcConnection;
20 class IRtmpConnection;
21 class ILocalUser;
22 class IMediaDeviceManager;
23 class INGAudioDeviceManager;
24 class INGVideoDeviceManager;
25 struct TConnectionInfo;
26 struct RtcConnectionConfiguration;
27 struct RtmpConnectionConfiguration;
28 class ILocalAudioTrack;
29 class IMediaPlayerSource;
30 class IMediaStreamingSource;
31 class ICameraCapturer;
32 class IScreenCapturer;
33 class IScreenCapturer2;
34 class IAudioPcmDataSender;
35 class IAudioEncodedFrameSender;
36 class IVideoFrameSender;
37 class IVideoEncodedImageSender;
38 class IVideoSourceNode;
39 class IVideoMixerSource;
40 class IVideoFrameTransceiver;
41 class ILocalVideoTrack;
42 class IMediaNodeFactory;
43 class IRecordingDeviceSource;
44 class IRemoteAudioMixerSource;
45 class IRtmpStreamingService;
46 class IMediaPacketSender;
47 class IMediaRelayService;
48 class IAudioDeviceManager;
49 class IAudioDeviceManagerObserver;
50
51 class IMediaExtensionObserver;
52 class IExtensionProvider;
53 class IFileUploaderService;
54 class IConfigCenter;
58 struct AudioEncoderConfiguration {
62 AUDIO_PROFILE_TYPE audioProfile;
63
64 AudioEncoderConfiguration() : audioProfile(AUDIO_PROFILE_DEFAULT) {}
65 };
66
67 } // namespace rtc
68
69 namespace rtm {
70 class IRtmService;
71 }
72
73 namespace base {
74 class IServiceObserver;
75 class ISyncClient;
76 struct SyncConfig;
77
83 struct AgoraServiceConfiguration {
89 bool enableAudioProcessor;
100 bool enableAudioDevice;
106 bool enableVideo;
112 void* context;
116 const char* appId;
117
121 unsigned int areaCode;
122
125 agora::CHANNEL_PROFILE_TYPE channelProfile;
126
130 const char* license;
131
135 rtc::AUDIO_SCENARIO_TYPE audioScenario;
139 commons::LogConfig logConfig;
143 bool useStringUid;
147 IServiceObserver* serviceObserver;
148
152 Optional<rtc::THREAD_PRIORITY_TYPE> threadPriority __deprecated;
159 bool useExternalEglContext;
160
166 bool domainLimit;
167
168 AgoraServiceConfiguration() : enableAudioProcessor(true),
169 enableAudioDevice(true),
170 enableVideo(false),
171 context(NULL),
172 appId(NULL),
173 areaCode(rtc::AREA_CODE_GLOB),
174 channelProfile(agora::CHANNEL_PROFILE_LIVE_BROADCASTING),
175 license(NULL),
176 audioScenario(rtc::AUDIO_SCENARIO_DEFAULT),
177 useStringUid(false),
178 serviceObserver(NULL),
179 useExternalEglContext(false),
180 domainLimit(false){}
181 };
187 struct AudioSessionConfiguration {
200 Optional<bool> playbackAndRecord;
209 Optional<bool> chatMode;
218 Optional<bool> defaultToSpeaker;
227 Optional<bool> overrideSpeaker;
236 Optional<bool> allowMixWithOthers;
245 Optional<bool> allowDuckOthers;
256 Optional<bool> allowBluetooth;
268 Optional<bool> allowBluetoothA2DP;
275 Optional<double> sampleRate;
282 Optional<double> ioBufferDuration;
286 Optional<int> inputNumberOfChannels;
290 Optional<int> outputNumberOfChannels;
291
292 #if defined(WEBRTC_IOS)
293
296 Optional<int> category;
297 #endif
298
299 void SetAll(const AudioSessionConfiguration& change) {
300 SetFrom(&playbackAndRecord, change.playbackAndRecord);
301 SetFrom(&chatMode, change.chatMode);
302 SetFrom(&defaultToSpeaker, change.defaultToSpeaker);
303 SetFrom(&overrideSpeaker, change.overrideSpeaker);
304 SetFrom(&allowMixWithOthers, change.allowMixWithOthers);
305 SetFrom(&allowDuckOthers, change.allowDuckOthers);
306 SetFrom(&allowBluetooth, change.allowBluetooth);
307 SetFrom(&allowBluetoothA2DP, change.allowBluetoothA2DP);
308 SetFrom(&sampleRate, change.sampleRate);
309 SetFrom(&ioBufferDuration, change.ioBufferDuration);
310 SetFrom(&inputNumberOfChannels, change.inputNumberOfChannels);
311 SetFrom(&outputNumberOfChannels, change.outputNumberOfChannels);
312 #if defined(WEBRTC_IOS)
313 SetFrom(&category, change.category);
314 #endif
315 }
316
317 bool operator==(const AudioSessionConfiguration& o) const {
318 return playbackAndRecord == o.playbackAndRecord && chatMode == o.chatMode &&
319 defaultToSpeaker == o.defaultToSpeaker && overrideSpeaker == o.overrideSpeaker &&
320 allowMixWithOthers == o.allowMixWithOthers && allowDuckOthers == o.allowDuckOthers &&
321 allowBluetooth == o.allowBluetooth && allowBluetoothA2DP == o.allowBluetoothA2DP && sampleRate == o.sampleRate &&
322 ioBufferDuration == o.ioBufferDuration &&
323 inputNumberOfChannels == o.inputNumberOfChannels &&
324 #if defined(WEBRTC_IOS)
325 outputNumberOfChannels == o.outputNumberOfChannels &&
326 category == o.category;
327 #else
328 outputNumberOfChannels == o.outputNumberOfChannels;
329 #endif
330 }
331 bool operator!=(const AudioSessionConfiguration& o) const { return !(*this == o); }
332
333 private:
334 template <typename T>
335 static void SetFrom(Optional<T>* s, const Optional<T>& o) {
336 if (o) {
337 *s = o;
338 }
339 }
340 };
344 enum TMixMode {
348 MIX_ENABLED,
352 MIX_DISABLED,
353 };
354
358 class IServiceObserver {
359 public:
360 virtual ~IServiceObserver() {}
361
366 virtual void onPermissionError(agora::rtc::PERMISSION_TYPE permissionType) {}
371 virtual void onAudioDeviceError(ERROR_CODE_TYPE error, const char* description) {}
383 virtual void onFetchConfigResult(int code, rtc::CONFIG_FETCH_TYPE configType, const char* configContent) {}
384
391 virtual void onLocalUserRegistered(rtc::uid_t uid, const char* userAccount) {}
392 };
393
404 class IAgoraService {
405 public:
417 virtual int initialize(const AgoraServiceConfiguration& config) = 0;
418
422 virtual int atExit(aosl_ref_t ares = AOSL_REF_INVALID) = 0;
423
431 virtual int release() = 0;
432
442 virtual int setAudioSessionPreset(agora::rtc::AUDIO_SCENARIO_TYPE scenario, aosl_ref_t ares = AOSL_REF_INVALID) = 0;
443
452 virtual int setAudioSessionConfiguration(const AudioSessionConfiguration& config, aosl_ref_t ares = AOSL_REF_INVALID) = 0;
453
462 virtual int getAudioSessionConfiguration(AudioSessionConfiguration* config) = 0;
463
483 virtual int setLogFile(const char* filePath, unsigned int fileSize, aosl_ref_t ares = AOSL_REF_INVALID) = 0;
502 virtual int setLogFilter(unsigned int filters, aosl_ref_t ares = AOSL_REF_INVALID) = 0;
503
512 virtual agora_refptr<rtc::IRtcConnection> createRtcConnection(
513 const rtc::RtcConnectionConfiguration& cfg) = 0;
514
515 virtual agora_refptr<rtc::IRtmpConnection> createRtmpConnection(
516 const rtc::RtmpConnectionConfiguration& cfg) = 0;
517
529 virtual agora_refptr<rtc::ILocalAudioTrack> createLocalAudioTrack() = 0;
530
540 virtual agora_refptr<rtc::ILocalAudioTrack> createLocalMixedAudioTrack() = 0;
541
553 virtual agora_refptr<rtc::ILocalAudioTrack> createCustomAudioTrack(
554 agora_refptr<rtc::IAudioPcmDataSender> audioSource) = 0;
555
568 virtual agora_refptr<rtc::ILocalAudioTrack> createDirectCustomAudioTrack(
569 agora_refptr<rtc::IAudioPcmDataSender> audioSource) = 0;
570
583 virtual agora_refptr<rtc::ILocalAudioTrack> createCustomAudioTrack(
584 agora_refptr<rtc::IAudioPcmDataSender> audioSource, bool enableAec) = 0;
585
597 virtual agora_refptr<rtc::ILocalAudioTrack> createCustomAudioTrack(
598 agora_refptr<rtc::IRemoteAudioMixerSource> audioSource) = 0;
599
612 virtual agora_refptr<rtc::ILocalAudioTrack> createCustomAudioTrack(
613 agora_refptr<rtc::IAudioEncodedFrameSender> audioSource, TMixMode mixMode) = 0;
615
626 virtual agora_refptr<rtc::ILocalAudioTrack> createCustomAudioTrack(
627 agora_refptr<rtc::IMediaPacketSender> source) = 0;
629
640 virtual agora_refptr<rtc::ILocalAudioTrack> createMediaPlayerAudioTrack(
641 agora_refptr<rtc::IMediaPlayerSource> audioSource) = 0;
642
654 virtual agora_refptr<rtc::ILocalAudioTrack> createMediaStreamingAudioTrack(
655 agora_refptr<rtc::IMediaStreamingSource> streamingSource) = 0;
656
669 virtual agora_refptr<rtc::ILocalAudioTrack> createRecordingDeviceAudioTrack(
670 agora_refptr<rtc::IRecordingDeviceSource> audioSource, bool enableAec, bool overlap) = 0;
671
679 virtual agora_refptr<rtc::INGAudioDeviceManager> createAudioDeviceManager() = 0;
680
681
689 virtual agora_refptr<rtc::INGVideoDeviceManager> createVideoDeviceManager() = 0;
690
698 virtual agora_refptr<rtc::IMediaNodeFactory> createMediaNodeFactory() = 0;
699
711 virtual agora_refptr<rtc::ILocalVideoTrack> createCameraVideoTrack(
712 agora_refptr<rtc::ICameraCapturer> videoSource, const char* id = OPTIONAL_NULLPTR) = 0;
713
725 virtual agora_refptr<rtc::ILocalVideoTrack> createMixedVideoTrack(agora_refptr<rtc::IVideoMixerSource> videoSource,
726 const char* id = OPTIONAL_NULLPTR) = 0;
727
739 virtual agora_refptr<rtc::ILocalVideoTrack> createTranscodedVideoTrack(agora_refptr<rtc::IVideoFrameTransceiver> transceiver,
740 const char* id = OPTIONAL_NULLPTR) = 0;
741
743
753 virtual agora_refptr<rtc::ILocalVideoTrack> createCustomVideoTrack(
754 agora_refptr<rtc::IVideoFrameSender> videoSource, const char* id = OPTIONAL_NULLPTR) = 0;
756
769 virtual agora_refptr<rtc::ILocalVideoTrack> createCustomVideoTrack(
770 agora_refptr<rtc::IVideoEncodedImageSender> videoSource,
771 const rtc::SenderOptions& options,
772 const char* id = OPTIONAL_NULLPTR) = 0;
773
774 #if defined(__ANDROID__) || (defined(TARGET_OS_IPHONE) && TARGET_OS_IPHONE)
775
786 virtual agora_refptr<rtc::ILocalVideoTrack> createScreenCaptureVideoTrack(
787 agora_refptr<rtc::IScreenCapturer2> screen) = 0;
788
800 virtual agora_refptr<rtc::ILocalAudioTrack> createScreenCaptureAudioTrack(
801 agora_refptr<rtc::IScreenCapturer2> screen) = 0;
802 #else
803
814 virtual agora_refptr<rtc::ILocalVideoTrack> createScreenCaptureVideoTrack(
815 agora_refptr<rtc::IScreenCapturer> screen, const char* id = OPTIONAL_NULLPTR) = 0;
816
817
829 virtual agora_refptr<rtc::ILocalAudioTrack> createScreenCaptureAudioTrack(
830 agora_refptr<rtc::IScreenCapturer> screen) = 0;
831 #endif
832
834
844 virtual agora_refptr<rtc::ILocalVideoTrack> createCustomVideoTrack(
845 agora_refptr<rtc::IMediaPacketSender> source, const char* id = OPTIONAL_NULLPTR) = 0;
847
857 virtual agora_refptr<rtc::ILocalVideoTrack> createMediaPlayerVideoTrack(
858 agora_refptr<rtc::IMediaPlayerSource> videoSource, const char* id = OPTIONAL_NULLPTR) = 0;
859
870 virtual agora_refptr<rtc::ILocalVideoTrack> createMediaStreamingVideoTrack(
871 agora_refptr<rtc::IMediaStreamingSource> streamingSource, const char* id = OPTIONAL_NULLPTR) = 0;
872
873
883 virtual agora_refptr<rtc::IRtmpStreamingService> createRtmpStreamingService(
884 agora_refptr<rtc::IRtcConnection> rtcConnection, const char* appId) = 0;
885
896 virtual agora_refptr<rtc::IMediaRelayService> createMediaRelayService(
897 agora_refptr<rtc::IRtcConnection> rtcConnection, const char* appId) = 0;
898
909 virtual agora_refptr<rtc::IFileUploaderService> createFileUploadService(
910 agora_refptr<rtc::IRtcConnection> rtcConnection, const char* appId) = 0;
911
919 virtual rtm::IRtmService* createRtmService() = 0;
920
921 virtual int addExtensionObserver(agora::agora_refptr<agora::rtc::IMediaExtensionObserver> observer, aosl_ref_t ares = AOSL_REF_INVALID) = 0;
922
923 virtual int removeExtensionObserver(agora::agora_refptr<agora::rtc::IMediaExtensionObserver> observer, aosl_ref_t ares = AOSL_REF_INVALID) = 0;
924
932 virtual agora_refptr<rtc::IAudioDeviceManager> createAudioDeviceManagerComponent(
933 rtc::IAudioDeviceManagerObserver *observer) = 0;
934
942 virtual agora_refptr<ILocalDataChannel> createLocalDataChannel(const DataChannelConfig& config) = 0;
943
952 virtual const char* getExtensionId(const char* provider_name, const char* extension_name) = 0;
953
954 #if defined (_WIN32) || defined(__linux__) || defined(__ANDROID__)
955
962 virtual int loadExtensionProvider(const char* path, bool unload_after_use = false) = 0;
963 #endif
964
977 virtual int enableExtension(
978 const char* provider_name, const char* extension_name, const char* track_id = NULL,
979 bool auto_enable_on_track = false, aosl_ref_t ares = AOSL_REF_INVALID) = 0;
991 virtual int disableExtension(
992 const char* provider_name, const char* extension_name, const char* track_id = NULL, aosl_ref_t ares = AOSL_REF_INVALID) = 0;
993
1001 virtual agora_refptr<base::IAgoraParameter> getAgoraParameter() = 0;
1002
1010 virtual agora_refptr<rtc::IConfigCenter> getConfigCenter() = 0;
1011
1019 virtual agora_refptr<base::ISyncClient> createSyncClient(const base::SyncConfig& config) = 0;
1020
1028 virtual int32_t setLogWriter(agora::commons::ILogWriter* logWriter) = 0;
1029
1036 virtual agora::commons::ILogWriter* releaseLogWriter() = 0;
1037
1038 protected:
1039 virtual ~IAgoraService() {}
1040 };
1041
1042 } // namespace base
1043 } // namespace agora
1044
1055 AGORA_API agora::base::IAgoraService* AGORA_CALL createAgoraService();
agora::base::AgoraServiceConfiguration::useExternalEglContext
bool useExternalEglContext
Definition: IAgoraService.h:159
agora::base::IAgoraService::createRtmService
virtual rtm::IRtmService * createRtmService()=0
agora::CHANNEL_PROFILE_LIVE_BROADCASTING
@ CHANNEL_PROFILE_LIVE_BROADCASTING
Definition: AgoraBase.h:279
agora::base::IAgoraService::addExtensionObserver
virtual int addExtensionObserver(agora::agora_refptr< agora::rtc::IMediaExtensionObserver > observer, aosl_ref_t ares=AOSL_REF_INVALID)=0
agora::base::IAgoraService::removeExtensionObserver
virtual int removeExtensionObserver(agora::agora_refptr< agora::rtc::IMediaExtensionObserver > observer, aosl_ref_t ares=AOSL_REF_INVALID)=0
agora::base::IAgoraService
Definition: IAgoraService.h:404
agora::ERROR_CODE_TYPE
ERROR_CODE_TYPE
Definition: AgoraBase.h:460
agora::rtc::SenderOptions
Definition: AgoraBase.h:1258
agora::base::IAgoraService::createCustomAudioTrack
virtual agora_refptr< rtc::ILocalAudioTrack > createCustomAudioTrack(agora_refptr< rtc::IAudioEncodedFrameSender > audioSource, TMixMode mixMode)=0
agora::base::IAgoraService::createMixedVideoTrack
virtual agora_refptr< rtc::ILocalVideoTrack > createMixedVideoTrack(agora_refptr< rtc::IVideoMixerSource > videoSource, const char *id=OPTIONAL_NULLPTR)=0
agora::base::AudioSessionConfiguration::outputNumberOfChannels
Optional< int > outputNumberOfChannels
Definition: IAgoraService.h:290
agora::base::AudioSessionConfiguration::ioBufferDuration
Optional< double > ioBufferDuration
Definition: IAgoraService.h:282
agora::base::AudioSessionConfiguration::allowDuckOthers
Optional< bool > allowDuckOthers
Definition: IAgoraService.h:245
agora::commons::ILogWriter
Definition: IAgoraLog.h:50
agora::base::IAgoraService::createFileUploadService
virtual agora_refptr< rtc::IFileUploaderService > createFileUploadService(agora_refptr< rtc::IRtcConnection > rtcConnection, const char *appId)=0
agora::base::IAgoraService::createDirectCustomAudioTrack
virtual agora_refptr< rtc::ILocalAudioTrack > createDirectCustomAudioTrack(agora_refptr< rtc::IAudioPcmDataSender > audioSource)=0
AgoraBase.h
agora::base::IAgoraService::createTranscodedVideoTrack
virtual agora_refptr< rtc::ILocalVideoTrack > createTranscodedVideoTrack(agora_refptr< rtc::IVideoFrameTransceiver > transceiver, const char *id=OPTIONAL_NULLPTR)=0
agora::base::IAgoraService::setLogFile
virtual int setLogFile(const char *filePath, unsigned int fileSize, aosl_ref_t ares=AOSL_REF_INVALID)=0
agora::rtc::uid_t
unsigned int uid_t
Definition: AgoraMediaBase.h:28
agora::base::IAgoraService::createRtmpStreamingService
virtual agora_refptr< rtc::IRtmpStreamingService > createRtmpStreamingService(agora_refptr< rtc::IRtcConnection > rtcConnection, const char *appId)=0
agora::agora_refptr
Definition: AgoraRefPtr.h:44
agora::base::IAgoraService::createScreenCaptureVideoTrack
virtual agora_refptr< rtc::ILocalVideoTrack > createScreenCaptureVideoTrack(agora_refptr< rtc::IScreenCapturer2 > screen)=0
agora::base::AgoraServiceConfiguration
Definition: IAgoraService.h:83
agora::base::IAgoraService::~IAgoraService
virtual ~IAgoraService()
Definition: IAgoraService.h:1039
agora::base::AgoraServiceConfiguration::domainLimit
bool domainLimit
Definition: IAgoraService.h:166
agora::base::IAgoraService::initialize
virtual int initialize(const AgoraServiceConfiguration &config)=0
agora::base::MIX_DISABLED
@ MIX_DISABLED
Definition: IAgoraService.h:352
agora::rtc::CONFIG_FETCH_TYPE
CONFIG_FETCH_TYPE
Definition: AgoraBase.h:7059
agora::base::AudioSessionConfiguration::allowBluetoothA2DP
Optional< bool > allowBluetoothA2DP
Definition: IAgoraService.h:268
agora::rtm::IRtmService
Definition: IAgoraRtmService.h:637
agora::base::IAgoraService::createVideoDeviceManager
virtual agora_refptr< rtc::INGVideoDeviceManager > createVideoDeviceManager()=0
agora::base::AudioSessionConfiguration::playbackAndRecord
Optional< bool > playbackAndRecord
Definition: IAgoraService.h:200
agora::base::AudioSessionConfiguration::sampleRate
Optional< double > sampleRate
Definition: IAgoraService.h:275
agora::base::AgoraServiceConfiguration::appId
const char * appId
Definition: IAgoraService.h:116
agora::base::AgoraServiceConfiguration::channelProfile
agora::CHANNEL_PROFILE_TYPE channelProfile
Definition: IAgoraService.h:125
agora::base::AudioSessionConfiguration::chatMode
Optional< bool > chatMode
Definition: IAgoraService.h:209
agora::base::IAgoraService::createAudioDeviceManagerComponent
virtual agora_refptr< rtc::IAudioDeviceManager > createAudioDeviceManagerComponent(rtc::IAudioDeviceManagerObserver *observer)=0
agora::base::IAgoraService::setAudioSessionPreset
virtual int setAudioSessionPreset(agora::rtc::AUDIO_SCENARIO_TYPE scenario, aosl_ref_t ares=AOSL_REF_INVALID)=0
agora::base::IServiceObserver
Definition: IAgoraService.h:358
agora::base::IAgoraService::setLogFilter
virtual int setLogFilter(unsigned int filters, aosl_ref_t ares=AOSL_REF_INVALID)=0
agora::base::IServiceObserver::onFetchConfigResult
virtual void onFetchConfigResult(int code, rtc::CONFIG_FETCH_TYPE configType, const char *configContent)
Definition: IAgoraService.h:383
agora::base::AudioSessionConfiguration::operator!=
bool operator!=(const AudioSessionConfiguration &o) const
Definition: IAgoraService.h:331
agora::rtc::AUDIO_SCENARIO_DEFAULT
@ AUDIO_SCENARIO_DEFAULT
Definition: AgoraBase.h:2795
agora::base::IAgoraService::getExtensionId
virtual const char * getExtensionId(const char *provider_name, const char *extension_name)=0
Get the ID of the registered extension.
agora::rtc::RtmpConnectionConfiguration
Definition: NGIAgoraRtmpConnection.h:231
agora::base::AudioSessionConfiguration::allowBluetooth
Optional< bool > allowBluetooth
Definition: IAgoraService.h:256
createAgoraService
AGORA_API agora::base::IAgoraService *AGORA_CALL createAgoraService()
agora::base::AgoraServiceConfiguration::enableAudioProcessor
bool enableAudioProcessor
Definition: IAgoraService.h:89
agora::base::IAgoraService::getConfigCenter
virtual agora_refptr< rtc::IConfigCenter > getConfigCenter()=0
agora::base::AudioSessionConfiguration::defaultToSpeaker
Optional< bool > defaultToSpeaker
Definition: IAgoraService.h:218
agora::rtc::AudioEncoderConfiguration::AudioEncoderConfiguration
AudioEncoderConfiguration()
Definition: IAgoraService.h:64
agora
Definition: AgoraAtomicOps.h:21
agora::base::IAgoraService::releaseLogWriter
virtual agora::commons::ILogWriter * releaseLogWriter()=0
agora::base::IAgoraService::createCustomAudioTrack
virtual agora_refptr< rtc::ILocalAudioTrack > createCustomAudioTrack(agora_refptr< rtc::IMediaPacketSender > source)=0
agora::base::IAgoraService::createMediaStreamingVideoTrack
virtual agora_refptr< rtc::ILocalVideoTrack > createMediaStreamingVideoTrack(agora_refptr< rtc::IMediaStreamingSource > streamingSource, const char *id=OPTIONAL_NULLPTR)=0
agora::base::AgoraServiceConfiguration::logConfig
commons::LogConfig logConfig
Definition: IAgoraService.h:139
agora::base::SyncConfig
Definition: NGIAgoraSyncClient.h:79
agora::rtc::PERMISSION_TYPE
PERMISSION_TYPE
Definition: AgoraBase.h:6735
agora::base::IAgoraService::createCustomVideoTrack
virtual agora_refptr< rtc::ILocalVideoTrack > createCustomVideoTrack(agora_refptr< rtc::IMediaPacketSender > source, const char *id=OPTIONAL_NULLPTR)=0
agora::base::IAgoraService::createRtmpConnection
virtual agora_refptr< rtc::IRtmpConnection > createRtmpConnection(const rtc::RtmpConnectionConfiguration &cfg)=0
agora::base::AgoraServiceConfiguration::areaCode
unsigned int areaCode
Definition: IAgoraService.h:121
agora::base::IAgoraService::createCustomVideoTrack
virtual agora_refptr< rtc::ILocalVideoTrack > createCustomVideoTrack(agora_refptr< rtc::IVideoEncodedImageSender > videoSource, const rtc::SenderOptions &options, const char *id=OPTIONAL_NULLPTR)=0
agora::base::AgoraServiceConfiguration::serviceObserver
IServiceObserver * serviceObserver
Definition: IAgoraService.h:147
agora::base::AudioSessionConfiguration
Definition: IAgoraService.h:187
agora::CHANNEL_PROFILE_TYPE
CHANNEL_PROFILE_TYPE
Definition: AgoraBase.h:267
agora::rtc::AudioEncoderConfiguration::audioProfile
AUDIO_PROFILE_TYPE audioProfile
Definition: IAgoraService.h:62
agora::base::IAgoraService::createScreenCaptureAudioTrack
virtual agora_refptr< rtc::ILocalAudioTrack > createScreenCaptureAudioTrack(agora_refptr< rtc::IScreenCapturer2 > screen)=0
agora::base::IAgoraService::createCustomVideoTrack
virtual agora_refptr< rtc::ILocalVideoTrack > createCustomVideoTrack(agora_refptr< rtc::IVideoFrameSender > videoSource, const char *id=OPTIONAL_NULLPTR)=0
agora::base::IAgoraService::getAgoraParameter
virtual agora_refptr< base::IAgoraParameter > getAgoraParameter()=0
agora::base::IAgoraService::getAudioSessionConfiguration
virtual int getAudioSessionConfiguration(AudioSessionConfiguration *config)=0
AGORA_API
#define AGORA_API
Definition: AgoraBase.h:70
agora::base::IAgoraService::createMediaPlayerVideoTrack
virtual agora_refptr< rtc::ILocalVideoTrack > createMediaPlayerVideoTrack(agora_refptr< rtc::IMediaPlayerSource > videoSource, const char *id=OPTIONAL_NULLPTR)=0
agora::base::IAgoraService::createMediaRelayService
virtual agora_refptr< rtc::IMediaRelayService > createMediaRelayService(agora_refptr< rtc::IRtcConnection > rtcConnection, const char *appId)=0
agora::base::IServiceObserver::onPermissionError
virtual void onPermissionError(agora::rtc::PERMISSION_TYPE permissionType)
Definition: IAgoraService.h:366
agora::base::AgoraServiceConfiguration::enableAudioDevice
bool enableAudioDevice
Definition: IAgoraService.h:100
agora::base::IAgoraService::createMediaPlayerAudioTrack
virtual agora_refptr< rtc::ILocalAudioTrack > createMediaPlayerAudioTrack(agora_refptr< rtc::IMediaPlayerSource > audioSource)=0
agora::base::AudioSessionConfiguration::inputNumberOfChannels
Optional< int > inputNumberOfChannels
Definition: IAgoraService.h:286
agora::base::IAgoraService::setLogWriter
virtual int32_t setLogWriter(agora::commons::ILogWriter *logWriter)=0
agora::base::IAgoraService::createRecordingDeviceAudioTrack
virtual agora_refptr< rtc::ILocalAudioTrack > createRecordingDeviceAudioTrack(agora_refptr< rtc::IRecordingDeviceSource > audioSource, bool enableAec, bool overlap)=0
agora::base::IAgoraService::createCameraVideoTrack
virtual agora_refptr< rtc::ILocalVideoTrack > createCameraVideoTrack(agora_refptr< rtc::ICameraCapturer > videoSource, const char *id=OPTIONAL_NULLPTR)=0
agora::commons::LogConfig
Definition: IAgoraLog.h:83
IAgoraLog.h
agora::rtc::AUDIO_SCENARIO_TYPE
AUDIO_SCENARIO_TYPE
Definition: AgoraBase.h:2790
agora::base::IAgoraService::atExit
virtual int atExit(aosl_ref_t ares=AOSL_REF_INVALID)=0
agora::base::AgoraServiceConfiguration::license
const char * license
Definition: IAgoraService.h:130
agora::base::IAgoraService::createRtcConnection
virtual agora_refptr< rtc::IRtcConnection > createRtcConnection(const rtc::RtcConnectionConfiguration &cfg)=0
agora::base::AgoraServiceConfiguration::threadPriority
Optional< rtc::THREAD_PRIORITY_TYPE > threadPriority
Definition: IAgoraService.h:152
AgoraOptional.h
agora::base::IAgoraService::disableExtension
virtual int disableExtension(const char *provider_name, const char *extension_name, const char *track_id=NULL, aosl_ref_t ares=AOSL_REF_INVALID)=0
agora::base::AgoraServiceConfiguration::enableVideo
bool enableVideo
Definition: IAgoraService.h:106
agora::rtc::IAudioDeviceManagerObserver
Definition: NGIAgoraAudioDeviceManager.h:91
agora::base::IAgoraService::createCustomAudioTrack
virtual agora_refptr< rtc::ILocalAudioTrack > createCustomAudioTrack(agora_refptr< rtc::IAudioPcmDataSender > audioSource, bool enableAec)=0
agora::base::IServiceObserver::~IServiceObserver
virtual ~IServiceObserver()
Definition: IAgoraService.h:360
agora::base::AgoraServiceConfiguration::AgoraServiceConfiguration
AgoraServiceConfiguration()
Definition: IAgoraService.h:168
agora::rtc::RtcConnectionConfiguration
Definition: NGIAgoraRtcConnection.h:90
__deprecated
#define __deprecated
Definition: AgoraBase.h:74
agora::base::IServiceObserver::onAudioDeviceError
virtual void onAudioDeviceError(ERROR_CODE_TYPE error, const char *description)
Definition: IAgoraService.h:371
agora::base::MIX_ENABLED
@ MIX_ENABLED
Definition: IAgoraService.h:348
agora::base::IAgoraService::createCustomAudioTrack
virtual agora_refptr< rtc::ILocalAudioTrack > createCustomAudioTrack(agora_refptr< rtc::IAudioPcmDataSender > audioSource)=0
agora::base::IAgoraService::setAudioSessionConfiguration
virtual int setAudioSessionConfiguration(const AudioSessionConfiguration &config, aosl_ref_t ares=AOSL_REF_INVALID)=0
agora::base::AgoraServiceConfiguration::useStringUid
bool useStringUid
Definition: IAgoraService.h:143
agora::rtc::AudioEncoderConfiguration
Definition: IAgoraService.h:58
agora::base::IAgoraService::createCustomAudioTrack
virtual agora_refptr< rtc::ILocalAudioTrack > createCustomAudioTrack(agora_refptr< rtc::IRemoteAudioMixerSource > audioSource)=0
OPTIONAL_NULLPTR
#define OPTIONAL_NULLPTR
Definition: AgoraBase.h:90
agora::base::AudioSessionConfiguration::operator==
bool operator==(const AudioSessionConfiguration &o) const
Definition: IAgoraService.h:317
agora::base::IAgoraService::enableExtension
virtual int enableExtension(const char *provider_name, const char *extension_name, const char *track_id=NULL, bool auto_enable_on_track=false, aosl_ref_t ares=AOSL_REF_INVALID)=0
agora::base::IAgoraService::createLocalMixedAudioTrack
virtual agora_refptr< rtc::ILocalAudioTrack > createLocalMixedAudioTrack()=0
agora::rtc::AUDIO_PROFILE_TYPE
AUDIO_PROFILE_TYPE
Definition: AgoraBase.h:2743
agora::base::AudioSessionConfiguration::SetFrom
static void SetFrom(Optional< T > *s, const Optional< T > &o)
Definition: IAgoraService.h:335
agora::base::IAgoraService::createSyncClient
virtual agora_refptr< base::ISyncClient > createSyncClient(const base::SyncConfig &config)=0
agora::base::IAgoraService::createLocalDataChannel
virtual agora_refptr< ILocalDataChannel > createLocalDataChannel(const DataChannelConfig &config)=0
agora::base::AgoraServiceConfiguration::context
void * context
Definition: IAgoraService.h:112
agora::base::ISyncClient
Definition: NGIAgoraSyncClient.h:90
agora::base::IServiceObserver::onLocalUserRegistered
virtual void onLocalUserRegistered(rtc::uid_t uid, const char *userAccount)
Definition: IAgoraService.h:391
agora::DataChannelConfig
Definition: NGIAgoraDataChannel.h:18
agora::base::IAgoraService::createLocalAudioTrack
virtual agora_refptr< rtc::ILocalAudioTrack > createLocalAudioTrack()=0
agora::base::AudioSessionConfiguration::SetAll
void SetAll(const AudioSessionConfiguration &change)
Definition: IAgoraService.h:299
agora::rtc::AREA_CODE_GLOB
@ AREA_CODE_GLOB
Definition: AgoraBase.h:6303
AGORA_CALL
#define AGORA_CALL
Definition: AgoraBase.h:72
agora::base::AudioSessionConfiguration::overrideSpeaker
Optional< bool > overrideSpeaker
Definition: IAgoraService.h:227
agora::base::AgoraServiceConfiguration::audioScenario
rtc::AUDIO_SCENARIO_TYPE audioScenario
Definition: IAgoraService.h:135
agora::base::TMixMode
TMixMode
Definition: IAgoraService.h:344
agora::base::IAgoraService::createMediaStreamingAudioTrack
virtual agora_refptr< rtc::ILocalAudioTrack > createMediaStreamingAudioTrack(agora_refptr< rtc::IMediaStreamingSource > streamingSource)=0
agora::base::IAgoraService::createMediaNodeFactory
virtual agora_refptr< rtc::IMediaNodeFactory > createMediaNodeFactory()=0
agora::base::IAgoraService::release
virtual int release()=0
agora::base::IAgoraService::createAudioDeviceManager
virtual agora_refptr< rtc::INGAudioDeviceManager > createAudioDeviceManager()=0
agora::Optional< rtc::THREAD_PRIORITY_TYPE >
agora::base::AudioSessionConfiguration::allowMixWithOthers
Optional< bool > allowMixWithOthers
Definition: IAgoraService.h:236
agora::rtc::AUDIO_PROFILE_DEFAULT
@ AUDIO_PROFILE_DEFAULT
Definition: AgoraBase.h:2753