NERtc Linux SDK  V5.4.10
nertc_channel.h
浏览该文件的文档.
1 
8 #ifndef NERTC_CHANNEL_H
9 #define NERTC_CHANNEL_H
10 
11 #include "nertc_base.h"
12 #include "nertc_base_types.h"
13 #include "nertc_engine_defines.h"
16 
21 namespace nertc
22 {
23 
33 {
34 public:
35  virtual ~IRtcChannel() {}
36 
47  virtual void release() = 0;
48 
65  virtual const char* getChannelName() = 0;
66 
89 
148  virtual int joinChannel(const char* token) = 0;
149 
213  virtual int joinChannel(const char* token, uid_t uid) = 0;
214 
273  virtual int joinChannel(const char* token, uid_t uid, NERtcJoinChannelOptions channel_options) = 0;
274 
315  virtual int leaveChannel() = 0;
316 
335  virtual int setStatsObserver(IRtcMediaStatsObserver* observer) = 0;
336 
396  virtual int enableLocalAudio(bool enabled) = 0;
397 
424  virtual int enableLocalSubStreamAudio(bool enabled) = 0;
425 
485  virtual int muteLocalAudioStream(bool mute) = 0;
486 
513  virtual int muteLocalSubStreamAudio(bool mute) = 0;
514 
573  virtual int enableLocalVideo(bool enabled) = 0;
574 
639  virtual int enableLocalVideo(NERtcVideoStreamType type, bool enabled) = 0;
640 
641 
700  virtual int muteLocalVideoStream(bool mute) = 0;
701 
760  virtual int muteLocalVideoStream(NERtcVideoStreamType type, bool mute) = 0;
761 
786  virtual IScreenCaptureSourceList* getScreenCaptureSources(const NERtcSize& thumbSize, const NERtcSize& iconSize, const bool includeScreen) = 0;
787 
821  virtual int startScreenCaptureByScreenRect(const NERtcRectangle& screen_rect, const NERtcRectangle& region_rect, const NERtcScreenCaptureParameters& capture_params) = 0;
822 
854  virtual int startScreenCaptureByDisplayId(source_id_t display_id, const NERtcRectangle& region_rect, const NERtcScreenCaptureParameters& capture_params) = 0;
855 
890  virtual int startScreenCaptureByWindowId(source_id_t window_id, const NERtcRectangle& region_rect, const NERtcScreenCaptureParameters& capture_params) = 0;
891 
906  virtual int32_t setScreenCaptureSource(const NERtcScreenCaptureSourceInfo& source, const NERtcRectangle& region_rect, const NERtcScreenCaptureParameters& capture_params) = 0;
907 
928  virtual int updateScreenCaptureRegion(const NERtcRectangle& region_rect) = 0;
929 
952  virtual int setScreenCaptureMouseCursor(bool capture_cursor) = 0;
953 
989  virtual int stopScreenCapture() = 0;
990 
1010  virtual int pauseScreenCapture() = 0;
1011 
1029  virtual int resumeScreenCapture() = 0;
1030 
1031 
1057  virtual int setExcludeWindowList(source_id_t* window_list, int count) = 0;
1058 
1102 
1156  virtual int setupLocalVideoCanvas(NERtcVideoCanvas* canvas) = 0;
1157 
1158 
1183 
1227  virtual int setLocalRenderMode(NERtcVideoScalingMode scaling_mode) = 0;
1228 
1253 
1279  virtual int setLocalVideoMirrorMode(NERtcVideoMirrorMode mirror_mode) = 0;
1280 
1332 
1393  virtual int setupRemoteVideoCanvas(uid_t uid, NERtcVideoCanvas* canvas) = 0;
1394 
1460 
1483  virtual int setRemoteRenderMode(uid_t uid, NERtcVideoScalingMode scaling_mode) = 0;
1484 
1508  virtual int setRemoteSubSteamRenderMode(uid_t uid, NERtcVideoScalingMode scaling_mode) = 0;
1509 
1573  virtual int setClientRole(NERtcClientRole role) = 0;
1574 
1632  virtual int setLocalMediaPriority(NERtcMediaPriorityType priority, bool is_preemptive) = 0;
1633 
1647 
1703  virtual int setCameraCaptureConfig(const NERtcCameraCaptureConfig& config) = 0;
1704 
1756 
1818  virtual int setVideoConfig(const NERtcVideoConfig& config) = 0;
1819 
1872  virtual int setVideoConfig(NERtcVideoStreamType type, const NERtcVideoConfig& config) = 0;
1873 
1923  virtual int enableDualStreamMode(bool enable) = 0;
1924 
1983  virtual int subscribeRemoteAudioStream(uid_t uid, bool subscribe) = 0;
1984 
2044  virtual int subscribeRemoteSubStreamAudio(uid_t uid, bool subscribe) = 0;
2045 
2096  virtual int subscribeAllRemoteAudioStream(bool subscribe) = 0;
2097 
2128  virtual int setAudioSubscribeOnlyBy(uid_t* uid_array, uint32_t size) = 0;
2129 
2193  virtual int subscribeRemoteVideoStream(uid_t uid, NERtcRemoteVideoStreamType type, bool subscribe) = 0;
2194 
2258  virtual int subscribeRemoteVideoSubStream(uid_t uid, bool subscribe) = 0;
2259 
2344  virtual int addLiveStreamTask(const NERtcLiveStreamTaskInfo& info) = 0;
2345 
2398  virtual int updateLiveStreamTask(const NERtcLiveStreamTaskInfo& info) = 0;
2399 
2453  virtual int removeLiveStreamTask(const char* task_id) = 0;
2454 
2493  virtual int sendSEIMsg(const char* data, int length, NERtcVideoStreamType type) = 0;
2494 
2533  virtual int sendSEIMsg(const char* data, int length) = 0;
2534 
2565  virtual int takeLocalSnapshot(NERtcVideoStreamType stream_type, NERtcTakeSnapshotCallback *callback) = 0;
2566 
2597  virtual int takeRemoteSnapshot(uid_t uid, NERtcVideoStreamType stream_type, NERtcTakeSnapshotCallback *callback) = 0;
2598 
2657  virtual int adjustUserPlaybackSignalVolume(uid_t uid, int volume) = 0;
2658 
2688  virtual int adjustChannelPlaybackSignalVolume(uint32_t volume) = 0;
2689 
2719 
2743 
2773  virtual int stopChannelMediaRelay() = 0;
2774 
2800 
2826 
2859  virtual int setRemoteHighPriorityAudioStream(bool enabled, uid_t uid) = 0;
2860 
2885  virtual int setExternalVideoSource(bool enabled) = 0;
2886 
2914  virtual int setExternalVideoSource(NERtcVideoStreamType type, bool enabled) = 0;
2915 
2936  virtual int pushExternalVideoFrame(NERtcVideoFrame* frame) = 0;
2937 
2959 
2960 
3001  virtual int enableMediaPub(bool enabled, NERtcMediaPubType media_type) = 0;
3002 
3045  virtual int updatePermissionKey(const char* key) = 0;
3055  virtual int reportCustomEvent(const char* event_name, const char* custom_identify, const char* parameters) = 0;
3119  virtual int enableAudioVolumeIndication(bool enable, uint64_t interval, bool enable_vad) = 0;
3155  virtual int updateSpatializerAudioRecvRange(int audible_distance,
3156  int conversational_distance,
3157  NERtcDistanceRolloffModel roll_off) = 0;
3158 
3196 
3209  virtual int enableSpatializerRoomEffects(bool enable) = 0;
3222  virtual int setSpatializerRoomProperty(const NERtcSpatializerRoomProperty& room_property) = 0;
3223 
3250  virtual int enableSpatializer(bool enable) = 0;
3251 };
3252 } //namespace nertc
3253 
3254 #endif
Definition: nertc_channel_event_handler.h:34
Definition: nertc_channel.h:33
virtual int enableDualStreamMode(bool enable)=0
virtual int setSpatializerRoomProperty(const NERtcSpatializerRoomProperty &room_property)=0
virtual int muteLocalVideoStream(bool mute)=0
virtual int subscribeAllRemoteAudioStream(bool subscribe)=0
virtual int setChannelEventHandler(IRtcChannelEventHandler *handler)=0
virtual int stopChannelMediaRelay()=0
virtual int setRemoteRenderMode(uid_t uid, NERtcVideoScalingMode scaling_mode)=0
virtual int setupRemoteVideoCanvas(uid_t uid, NERtcVideoCanvas *canvas)=0
virtual int setClientRole(NERtcClientRole role)=0
virtual int sendSEIMsg(const char *data, int length)=0
virtual int resumeScreenCapture()=0
virtual int enableAudioVolumeIndication(bool enable, uint64_t interval, bool enable_vad)=0
virtual int updateLiveStreamTask(const NERtcLiveStreamTaskInfo &info)=0
virtual int subscribeRemoteVideoStream(uid_t uid, NERtcRemoteVideoStreamType type, bool subscribe)=0
virtual int enableSpatializerRoomEffects(bool enable)=0
virtual int sendSEIMsg(const char *data, int length, NERtcVideoStreamType type)=0
virtual int pushExternalVideoFrame(NERtcVideoFrame *frame)=0
virtual int updateSpatializerSelfPosition(const NERtcSpatializerPositionInfo &info)=0
virtual int setSpatializerRenderMode(NERtcSpatializerRenderMode mode)=0
virtual int setupLocalVideoCanvas(NERtcVideoCanvas *canvas)=0
virtual int addLiveStreamTask(const NERtcLiveStreamTaskInfo &info)=0
virtual int setRemoteSubSteamRenderMode(uid_t uid, NERtcVideoScalingMode scaling_mode)=0
virtual int setScreenCaptureMouseCursor(bool capture_cursor)=0
virtual int startScreenCaptureByWindowId(source_id_t window_id, const NERtcRectangle &region_rect, const NERtcScreenCaptureParameters &capture_params)=0
virtual int updateSpatializerAudioRecvRange(int audible_distance, int conversational_distance, NERtcDistanceRolloffModel roll_off)=0
virtual int setStatsObserver(IRtcMediaStatsObserver *observer)=0
virtual int subscribeRemoteAudioStream(uid_t uid, bool subscribe)=0
virtual int enableLocalVideo(NERtcVideoStreamType type, bool enabled)=0
virtual int muteLocalAudioStream(bool mute)=0
virtual int setLocalPublishFallbackOption(NERtcStreamFallbackOption option)=0
virtual int takeLocalSnapshot(NERtcVideoStreamType stream_type, NERtcTakeSnapshotCallback *callback)=0
virtual int setRemoteSubscribeFallbackOption(NERtcStreamFallbackOption option)=0
virtual int muteLocalVideoStream(NERtcVideoStreamType type, bool mute)=0
virtual int updateScreenCaptureParameters(const nertc::NERtcScreenCaptureParameters &captureParams)=0
virtual int setupRemoteSubStreamVideoCanvas(uid_t uid, NERtcVideoCanvas *canvas)=0
virtual int setCameraCaptureConfig(NERtcVideoStreamType type, const NERtcCameraCaptureConfig &config)=0
virtual NERtcConnectionStateType getConnectionState()=0
virtual IScreenCaptureSourceList * getScreenCaptureSources(const NERtcSize &thumbSize, const NERtcSize &iconSize, const bool includeScreen)=0
virtual int joinChannel(const char *token, uid_t uid, NERtcJoinChannelOptions channel_options)=0
virtual int muteLocalSubStreamAudio(bool mute)=0
virtual int setRemoteHighPriorityAudioStream(bool enabled, uid_t uid)=0
virtual int pauseScreenCapture()=0
virtual int setVideoConfig(NERtcVideoStreamType type, const NERtcVideoConfig &config)=0
virtual int setAudioSubscribeOnlyBy(uid_t *uid_array, uint32_t size)=0
virtual int adjustChannelPlaybackSignalVolume(uint32_t volume)=0
virtual int stopScreenCapture()=0
virtual int setLocalVideoMirrorMode(NERtcVideoMirrorMode mirror_mode)=0
virtual int setExcludeWindowList(source_id_t *window_list, int count)=0
virtual int enableSpatializer(bool enable)=0
virtual const char * getChannelName()=0
virtual int setLocalRenderMode(NERtcVideoScalingMode scaling_mode)=0
virtual int updatePermissionKey(const char *key)=0
virtual int enableLocalVideo(bool enabled)=0
virtual int adjustUserPlaybackSignalVolume(uid_t uid, int volume)=0
virtual int enableLocalSubStreamAudio(bool enabled)=0
virtual int startChannelMediaRelay(NERtcChannelMediaRelayConfiguration *config)=0
virtual int enableLocalAudio(bool enabled)=0
virtual int leaveChannel()=0
virtual int setLocalSubStreamRenderMode(NERtcVideoScalingMode scaling_mode)=0
virtual int startScreenCaptureByScreenRect(const NERtcRectangle &screen_rect, const NERtcRectangle &region_rect, const NERtcScreenCaptureParameters &capture_params)=0
virtual int subscribeRemoteVideoSubStream(uid_t uid, bool subscribe)=0
virtual int joinChannel(const char *token)=0
virtual int32_t setScreenCaptureSource(const NERtcScreenCaptureSourceInfo &source, const NERtcRectangle &region_rect, const NERtcScreenCaptureParameters &capture_params)=0
virtual int subscribeRemoteSubStreamAudio(uid_t uid, bool subscribe)=0
virtual void release()=0
virtual int enableMediaPub(bool enabled, NERtcMediaPubType media_type)=0
virtual int updateChannelMediaRelay(NERtcChannelMediaRelayConfiguration *config)=0
virtual int updateScreenCaptureRegion(const NERtcRectangle &region_rect)=0
virtual int pushExternalVideoFrame(NERtcVideoStreamType type, NERtcVideoFrame *frame)=0
virtual int setLocalMediaPriority(NERtcMediaPriorityType priority, bool is_preemptive)=0
virtual int joinChannel(const char *token, uid_t uid)=0
virtual int setCameraCaptureConfig(const NERtcCameraCaptureConfig &config)=0
virtual int setVideoConfig(const NERtcVideoConfig &config)=0
virtual int reportCustomEvent(const char *event_name, const char *custom_identify, const char *parameters)=0
virtual int setLocalVideoMirrorMode(NERtcVideoStreamType type, NERtcVideoMirrorMode mirror_mode)=0
virtual int setupLocalSubStreamVideoCanvas(NERtcVideoCanvas *canvas)=0
virtual int removeLiveStreamTask(const char *task_id)=0
virtual int startScreenCaptureByDisplayId(source_id_t display_id, const NERtcRectangle &region_rect, const NERtcScreenCaptureParameters &capture_params)=0
virtual int takeRemoteSnapshot(uid_t uid, NERtcVideoStreamType stream_type, NERtcTakeSnapshotCallback *callback)=0
virtual int setExternalVideoSource(bool enabled)=0
virtual int setExternalVideoSource(NERtcVideoStreamType type, bool enabled)=0
Definition: nertc_engine_media_stats_observer.h:30
Definition: nertc_engine_defines.h:8255
Definition: nertc_engine_defines.h:6809
namespace nertc
NERtcClientRole
Definition: nertc_engine_defines.h:244
NERtcStreamFallbackOption
Definition: nertc_engine_defines.h:7254
NERtcVideoScalingMode
Definition: nertc_engine_defines.h:2074
NERtcVideoStreamType
Definition: nertc_engine_defines.h:5677
NERtcMediaPriorityType
Definition: nertc_engine_defines.h:306
NERtcConnectionStateType
Definition: nertc_engine_defines.h:2205
uint64_t uid_t
Definition: nertc_engine_defines.h:183
NERtcSpatializerRenderMode
Definition: nertc_engine_defines.h:8426
void * source_id_t
Definition: nertc_engine_defines.h:204
NERtcVideoMirrorMode
Definition: nertc_engine_defines.h:2116
NERtcMediaPubType
Definition: nertc_engine_defines.h:7862
NERtcDistanceRolloffModel
Definition: nertc_engine_defines.h:8452
NERtcRemoteVideoStreamType
Definition: nertc_engine_defines.h:1698
Defines macro output. The file only defines macro output instead of anything else.
NERTC SDK IRtcChannel回调接口头文件。 NERTC SDK所有接口参数说明: 所有与字符串相关的参数(char *)全部为UTF-8编码。
NERtc SDK definitions.
The interface header file of expansion callback of the NERTC SDK. All parameter descriptions of the N...
Definition: nertc_engine_defines.h:1572
Definition: nertc_engine_defines.h:6108
Definition: nertc_engine_defines.h:7823
Definition: nertc_engine_defines.h:964
Definition: nertc_engine_defines.h:3942
Definition: nertc_engine_defines.h:4193
Definition: nertc_engine_defines.h:8205
Definition: nertc_engine_defines.h:8159
Definition: nertc_engine_defines.h:8470
Definition: nertc_engine_defines.h:8492
Definition: nertc_engine_defines.h:4416
Definition: nertc_engine_defines.h:3561
Definition: nertc_engine_defines.h:5128