NERtc Linux SDK  V5.4.10
nertc_engine_event_handler_ex.h
浏览该文件的文档.
1 
7 #ifndef NERTC_ENGINE_EVENT_HANDLER_EX_H
8 #define NERTC_ENGINE_EVENT_HANDLER_EX_H
9 
10 #include "nertc_base_types.h"
11 #include "nertc_engine_defines.h"
13 
18 namespace nertc
19 {
31 {
32 public:
33  virtual ~IRtcEngineEventHandlerEx() {}
34 
48  virtual void onUserSubStreamVideoStart(uid_t uid, NERtcVideoProfileType max_profile) {
49  (void)uid;
50  (void)max_profile;
51  }
63  virtual void onUserSubStreamVideoStop(uid_t uid) {
64  (void)uid;
65  }
66 
83 
100 
112  virtual void onUserVideoProfileUpdate(uid_t uid, NERtcVideoProfileType max_profile) {
113  (void)uid;
114  (void)max_profile;
115  }
128  virtual void onUserSubStreamAudioStart(uid_t uid) {
129  (void)uid;
130  }
143  virtual void onUserSubStreamAudioStop(uid_t uid) {
144  (void)uid;
145  }
159  virtual void onUserAudioMute(uid_t uid, bool mute) {
160  (void)uid;
161  (void)mute;
162  }
181  virtual void onUserSubStreamAudioMute(uid_t uid, bool mute) {
182  (void)uid;
183  (void)mute;
184  }
201  virtual void onUserVideoMute(uid_t uid, bool mute) {
202  (void)uid;
203  (void)mute;
204  }
205 
236  virtual void onUserVideoMute(NERtcVideoStreamType videoStreamType, uid_t uid, bool mute) {
237  (void)videoStreamType;
238  (void)uid;
239  (void)mute;
240  }
241 
256  virtual void onAudioDeviceStateChanged(const char device_id[kNERtcMaxDeviceIDLength],
257  NERtcAudioDeviceType device_type,
258  NERtcAudioDeviceState device_state) {
259  (void)device_id;
260  (void)device_type;
261  (void)device_state;
262  }
263 
276  virtual void onAudioDefaultDeviceChanged(const char device_id[kNERtcMaxDeviceIDLength],
277  NERtcAudioDeviceType device_type) {
278  (void)device_id;
279  (void)device_type;
280  }
281 
296  virtual void onVideoDeviceStateChanged(const char device_id[kNERtcMaxDeviceIDLength],
297  NERtcVideoDeviceType device_type,
298  NERtcVideoDeviceState device_state) {
299  (void)device_id;
300  (void)device_type;
301  (void)device_state;
302  }
303 
314  virtual void onFirstAudioDataReceived(uid_t uid) {
315  (void)uid;
316  }
317 
330  virtual void onFirstVideoDataReceived(uid_t uid) {
331  (void)uid;
332  }
333 
360  (void)uid;
361  (void)type;
362  }
363 
402  virtual void onRemoteVideoReceiveSizeChanged(uid_t uid, NERtcVideoStreamType type, uint32_t width, uint32_t height) {
403  (void)uid;
404  (void)type;
405  (void)width;
406  (void)height;
407  }
408 
442  virtual void onLocalVideoRenderSizeChanged(NERtcVideoStreamType type, uint32_t width, uint32_t height) {
443  (void)type;
444  (void)width;
445  (void)height;
446  }
447 
458  virtual void onFirstAudioFrameDecoded(uid_t uid) {
459  (void)uid;
460  }
461 
479  virtual void onFirstVideoFrameDecoded(uid_t uid, uint32_t width, uint32_t height) {
480  (void)uid;
481  (void)width;
482  (void)height;
483  }
484 
520  virtual void onFirstVideoFrameDecoded(NERtcVideoStreamType type, uid_t uid, uint32_t width, uint32_t height) {
521  (void)type;
522  (void)uid;
523  (void)width;
524  (void)height;
525  }
526 
553  virtual void onCaptureVideoFrame(void *data,
554  NERtcVideoType type,
555  uint32_t width,
556  uint32_t height,
557  uint32_t count,
558  uint32_t offset[kNERtcMaxPlaneCount],
559  uint32_t stride[kNERtcMaxPlaneCount],
560  NERtcVideoRotation rotation) {
561  (void)data;
562  (void)type;
563  (void)width;
564  (void)height;
565  (void)count;
566  (void)offset;
567  (void)stride;
568  (void)rotation;
569  }
570 
592  (void)state;
593  (void)error_code;
594  }
595 
608  virtual void onAudioMixingTimestampUpdate(uint64_t timestamp_ms) {
609  (void)timestamp_ms;
610  }
611 
646  virtual void onAudioEffectTimestampUpdate(uint32_t effect_id, uint64_t timestamp_ms) {
647  (void)effect_id;
648  (void)timestamp_ms;
649  }
650 
663  virtual void onAudioEffectFinished(uint32_t effect_id) {
664  (void)effect_id;
665  }
666 
685  virtual void onLocalAudioVolumeIndication(int volume) {
686  (void)volume;
687  }
688 
707  virtual void onLocalAudioVolumeIndication(int volume, bool enable_vad) {
708  (void)volume;
709  (void)enable_vad;
710  }
711 
736  virtual void onRemoteAudioVolumeIndication(const NERtcAudioVolumeInfo *speakers, unsigned int speaker_number, int total_volume) {
737  (void)speakers;
738  (void)speaker_number;
739  (void)total_volume;
740  }
741 
762  virtual void onAddLiveStreamTask(const char* task_id, const char* url, int error_code) {
763  (void)task_id;
764  (void)url;
765  (void)error_code;
766  }
767 
788  virtual void onUpdateLiveStreamTask(const char* task_id, const char* url, int error_code) {
789  (void)task_id;
790  (void)url;
791  (void)error_code;
792  }
793 
812  virtual void onRemoveLiveStreamTask(const char* task_id, int error_code) {
813  (void)task_id;
814  (void)error_code;
815  }
816 
839  virtual void onLiveStreamState(const char* task_id, const char* url, NERtcLiveStreamStateCode state) {
840  (void)task_id;
841  (void)url;
842  (void)state;
843  }
844 
865  virtual void onAudioHowling(bool howling) {
866  (void)howling;
867  }
868 
885  virtual void onRecvSEIMsg(uid_t uid, const char* data, uint32_t dataSize) {
886  (void)uid;
887  (void)data;
888  (void)dataSize;
889  }
890 
903  virtual void onAudioRecording(NERtcAudioRecordingCode code, const char* file_path) {
904  (void)code;
905  (void)file_path;
906  }
907 
922  virtual void onMediaRelayStateChanged(NERtcChannelMediaRelayState state, const char* channel_name) {
923  (void)state;
924  (void)channel_name;
925  }
926 
943  virtual void onMediaRelayEvent(NERtcChannelMediaRelayEvent event, const char* channel_name, NERtcErrorCode error) {
944  (void)event;
945  (void)channel_name;
946  (void)error;
947  }
948 
969  virtual void onLocalPublishFallbackToAudioOnly(bool is_fallback, NERtcVideoStreamType stream_type) {
970  (void)is_fallback;
971  }
972 
995  virtual void onRemoteSubscribeFallbackToAudioOnly(uid_t uid, bool is_fallback, NERtcVideoStreamType stream_type) {
996  (void)uid;
997  (void)is_fallback;
998  }
999 
1016  (void)quality;
1017  }
1018 
1035  virtual void onLastmileProbeResult(const NERtcLastmileProbeResult& result) {
1036  (void)result;
1037  };
1038 
1061  virtual void onMediaRightChange(bool is_audio_banned, bool is_video_banned) {
1062  (void)is_audio_banned;
1063  (void)is_video_banned;
1064  }
1065 
1079  (void)result;
1080  }
1081 
1108  (void)enabled;
1109  (void)reason;
1110  }
1111 
1129  (void)videoStreamType;
1130  (void)state;
1131  }
1132 
1154  virtual void onPermissionKeyWillExpire() {}
1155 
1194  virtual void onUpdatePermissionKey(const char* key, NERtcErrorCode error, int timeout) {
1195  (void)key;
1196  (void)error;
1197  (void)timeout;
1198  }
1199 
1214  virtual void onUserDataReceiveMessage(uid_t uid, void* pData, uint64_t size) {
1215  (void)uid;
1216  (void)pData;
1217  (void)size;
1218  };
1219 
1232  virtual void onUserDataStart(uid_t uid){
1233  (void)uid;
1234  };
1235 
1246  virtual void onUserDataStop(uid_t uid) {
1247  (void)uid;
1248  };
1249 
1260  virtual void onUserDataStateChanged(uid_t uid) {
1261  (void)uid;
1262  };
1263 
1276  virtual void onUserDataBufferedAmountChanged(uid_t uid, uint64_t previousAmount) {
1277  (void)uid;
1278  (void)previousAmount;
1279  };
1280 };
1281 } // namespace nertc
1282 
1283 #endif
Definition: nertc_engine_event_handler_ex.h:31
virtual void onLastmileQuality(NERtcNetworkQualityType quality)
Definition: nertc_engine_event_handler_ex.h:1015
virtual void onAudioRecording(NERtcAudioRecordingCode code, const char *file_path)
Definition: nertc_engine_event_handler_ex.h:903
virtual void onFirstVideoFrameDecoded(uid_t uid, uint32_t width, uint32_t height)
Definition: nertc_engine_event_handler_ex.h:479
virtual void onLocalPublishFallbackToAudioOnly(bool is_fallback, NERtcVideoStreamType stream_type)
Definition: nertc_engine_event_handler_ex.h:969
virtual void onMediaRightChange(bool is_audio_banned, bool is_video_banned)
Definition: nertc_engine_event_handler_ex.h:1061
virtual void onRemoveLiveStreamTask(const char *task_id, int error_code)
Definition: nertc_engine_event_handler_ex.h:812
virtual void onFirstAudioFrameDecoded(uid_t uid)
Definition: nertc_engine_event_handler_ex.h:458
virtual void onAudioMixingStateChanged(NERtcAudioMixingState state, NERtcAudioMixingErrorCode error_code)
Definition: nertc_engine_event_handler_ex.h:591
virtual void onUserAudioMute(uid_t uid, bool mute)
Definition: nertc_engine_event_handler_ex.h:159
virtual void onAudioHowling(bool howling)
Definition: nertc_engine_event_handler_ex.h:865
virtual void onRemoteSubscribeFallbackToAudioOnly(uid_t uid, bool is_fallback, NERtcVideoStreamType stream_type)
Definition: nertc_engine_event_handler_ex.h:995
virtual void onFirstVideoFrameDecoded(NERtcVideoStreamType type, uid_t uid, uint32_t width, uint32_t height)
Definition: nertc_engine_event_handler_ex.h:520
virtual void onUserVideoMute(NERtcVideoStreamType videoStreamType, uid_t uid, bool mute)
Definition: nertc_engine_event_handler_ex.h:236
virtual void onFirstVideoDataReceived(uid_t uid)
Definition: nertc_engine_event_handler_ex.h:330
virtual void onUserSubStreamVideoStart(uid_t uid, NERtcVideoProfileType max_profile)
Definition: nertc_engine_event_handler_ex.h:48
virtual void onPermissionKeyWillExpire()
Definition: nertc_engine_event_handler_ex.h:1154
virtual void onMediaRelayEvent(NERtcChannelMediaRelayEvent event, const char *channel_name, NERtcErrorCode error)
Definition: nertc_engine_event_handler_ex.h:943
virtual void onVideoDeviceStateChanged(const char device_id[kNERtcMaxDeviceIDLength], NERtcVideoDeviceType device_type, NERtcVideoDeviceState device_state)
Definition: nertc_engine_event_handler_ex.h:296
virtual void onLastmileProbeResult(const NERtcLastmileProbeResult &result)
Definition: nertc_engine_event_handler_ex.h:1035
virtual void onUpdateLiveStreamTask(const char *task_id, const char *url, int error_code)
Definition: nertc_engine_event_handler_ex.h:788
virtual void onRemoteAudioVolumeIndication(const NERtcAudioVolumeInfo *speakers, unsigned int speaker_number, int total_volume)
Definition: nertc_engine_event_handler_ex.h:736
virtual void onFirstVideoDataReceived(NERtcVideoStreamType type, uid_t uid)
Definition: nertc_engine_event_handler_ex.h:359
virtual void onVirtualBackgroundSourceEnabled(bool enabled, NERtcVirtualBackgroundSourceStateReason reason)
Definition: nertc_engine_event_handler_ex.h:1107
virtual void onUserDataStateChanged(uid_t uid)
Definition: nertc_engine_event_handler_ex.h:1260
virtual void onUserDataReceiveMessage(uid_t uid, void *pData, uint64_t size)
Definition: nertc_engine_event_handler_ex.h:1214
virtual void onCheckNECastAudioDriverResult(NERtcInstallCastAudioDriverResult result)
Definition: nertc_engine_event_handler_ex.h:1078
virtual void onAudioEffectFinished(uint32_t effect_id)
Definition: nertc_engine_event_handler_ex.h:663
virtual void onLocalAudioVolumeIndication(int volume, bool enable_vad)
Definition: nertc_engine_event_handler_ex.h:707
virtual void onAudioDefaultDeviceChanged(const char device_id[kNERtcMaxDeviceIDLength], NERtcAudioDeviceType device_type)
Definition: nertc_engine_event_handler_ex.h:276
virtual void onScreenCaptureStatus(NERtcScreenCaptureStatus status)
Definition: nertc_engine_event_handler_ex.h:82
virtual void onLocalAudioVolumeIndication(int volume)
Definition: nertc_engine_event_handler_ex.h:685
virtual void onRecvSEIMsg(uid_t uid, const char *data, uint32_t dataSize)
Definition: nertc_engine_event_handler_ex.h:885
virtual void onLocalVideoRenderSizeChanged(NERtcVideoStreamType type, uint32_t width, uint32_t height)
Definition: nertc_engine_event_handler_ex.h:442
virtual void onUserDataStop(uid_t uid)
Definition: nertc_engine_event_handler_ex.h:1246
virtual void onUserDataStart(uid_t uid)
Definition: nertc_engine_event_handler_ex.h:1232
virtual void onAudioEffectTimestampUpdate(uint32_t effect_id, uint64_t timestamp_ms)
Definition: nertc_engine_event_handler_ex.h:646
virtual void onAudioDeviceStateChanged(const char device_id[kNERtcMaxDeviceIDLength], NERtcAudioDeviceType device_type, NERtcAudioDeviceState device_state)
Definition: nertc_engine_event_handler_ex.h:256
virtual void onMediaRelayStateChanged(NERtcChannelMediaRelayState state, const char *channel_name)
Definition: nertc_engine_event_handler_ex.h:922
virtual void onLiveStreamState(const char *task_id, const char *url, NERtcLiveStreamStateCode state)
Definition: nertc_engine_event_handler_ex.h:839
virtual void onUpdatePermissionKey(const char *key, NERtcErrorCode error, int timeout)
Definition: nertc_engine_event_handler_ex.h:1194
virtual void onUserSubStreamAudioStop(uid_t uid)
Definition: nertc_engine_event_handler_ex.h:143
virtual void onUserSubStreamVideoStop(uid_t uid)
Definition: nertc_engine_event_handler_ex.h:63
virtual void onUserSubStreamAudioStart(uid_t uid)
Definition: nertc_engine_event_handler_ex.h:128
virtual void onUserSubStreamAudioMute(uid_t uid, bool mute)
Definition: nertc_engine_event_handler_ex.h:181
virtual void onUserVideoMute(uid_t uid, bool mute)
Definition: nertc_engine_event_handler_ex.h:201
virtual void onAddLiveStreamTask(const char *task_id, const char *url, int error_code)
Definition: nertc_engine_event_handler_ex.h:762
virtual void onFirstAudioDataReceived(uid_t uid)
Definition: nertc_engine_event_handler_ex.h:314
virtual void onLocalVideoWatermarkState(NERtcVideoStreamType videoStreamType, NERtcLocalVideoWatermarkState state)
Definition: nertc_engine_event_handler_ex.h:1128
virtual void onCaptureVideoFrame(void *data, NERtcVideoType type, uint32_t width, uint32_t height, uint32_t count, uint32_t offset[kNERtcMaxPlaneCount], uint32_t stride[kNERtcMaxPlaneCount], NERtcVideoRotation rotation)
Definition: nertc_engine_event_handler_ex.h:553
virtual void onAudioMixingTimestampUpdate(uint64_t timestamp_ms)
Definition: nertc_engine_event_handler_ex.h:608
virtual void onRemoteVideoReceiveSizeChanged(uid_t uid, NERtcVideoStreamType type, uint32_t width, uint32_t height)
Definition: nertc_engine_event_handler_ex.h:402
virtual void onUserDataBufferedAmountChanged(uid_t uid, uint64_t previousAmount)
Definition: nertc_engine_event_handler_ex.h:1276
virtual void onUserVideoProfileUpdate(uid_t uid, NERtcVideoProfileType max_profile)
Definition: nertc_engine_event_handler_ex.h:112
virtual void onScreenCaptureSourceDataUpdate(NERtcScreenCaptureSourceData data)
Definition: nertc_engine_event_handler_ex.h:99
Definition: nertc_engine_event_handler.h:33
namespace nertc
NERtcLocalVideoWatermarkState
Definition: nertc_engine_defines.h:6310
NERtcAudioDeviceState
Definition: nertc_engine_defines.h:1774
NERtcChannelMediaRelayState
Definition: nertc_engine_defines.h:5935
NERtcVideoStreamType
Definition: nertc_engine_defines.h:5677
NERtcAudioDeviceType
Definition: nertc_engine_defines.h:1736
uint64_t uid_t
Definition: nertc_engine_defines.h:183
NERtcVideoRotation
Definition: nertc_engine_defines.h:5081
NERtcVideoProfileType
Definition: nertc_engine_defines.h:1631
NERtcAudioMixingErrorCode
Definition: nertc_error_code.h:898
NERtcVideoDeviceState
Definition: nertc_engine_defines.h:2045
NERtcScreenCaptureStatus
Definition: nertc_engine_defines.h:3864
NERtcVideoType
Definition: nertc_engine_defines.h:5025
NERtcAudioRecordingCode
Definition: nertc_engine_defines.h:7194
NERtcNetworkQualityType
Definition: nertc_engine_defines.h:3271
NERtcLiveStreamStateCode
Definition: nertc_engine_defines.h:1049
NERtcVirtualBackgroundSourceStateReason
Definition: nertc_engine_defines.h:7613
NERtcInstallCastAudioDriverResult
Definition: nertc_engine_defines.h:7573
NERtcAudioMixingState
Definition: nertc_engine_defines.h:5399
NERtcErrorCode
Definition: nertc_error_code.h:26
NERtcVideoDeviceType
Definition: nertc_engine_defines.h:2016
NERtcChannelMediaRelayEvent
Definition: nertc_engine_defines.h:5982
NERtc SDK definitions.
#define kNERtcMaxPlaneCount
Definition: nertc_engine_defines.h:19
#define kNERtcMaxDeviceIDLength
Definition: nertc_engine_defines.h:61
The interface header file of expansion callback of the NERTC SDK. All parameter descriptions of the N...
Definition: nertc_engine_defines.h:2401
Definition: nertc_engine_defines.h:7505
Definition: nertc_engine_defines.h:4042