|
virtual void | onUserSubStreamVideoStart (uid_t uid, NERtcVideoProfileType max_profile) |
|
virtual void | onUserSubStreamVideoStop (uid_t uid) |
|
virtual void | onScreenCaptureStatus (NERtcScreenCaptureStatus status) |
|
virtual void | onUserVideoProfileUpdate (uid_t uid, NERtcVideoProfileType max_profile) |
|
virtual void | onUserAudioMute (uid_t uid, bool mute) |
|
virtual void | onUserVideoMute (uid_t uid, bool mute) |
|
virtual void | onAudioDeviceStateChanged (const char device_id[kNERtcMaxDeviceIDLength], NERtcAudioDeviceType device_type, NERtcAudioDeviceState device_state) |
|
virtual void | onAudioDefaultDeviceChanged (const char device_id[kNERtcMaxDeviceIDLength], NERtcAudioDeviceType device_type) |
|
virtual void | onVideoDeviceStateChanged (const char device_id[kNERtcMaxDeviceIDLength], NERtcVideoDeviceType device_type, NERtcVideoDeviceState device_state) |
|
virtual void | onFirstAudioDataReceived (uid_t uid) |
|
virtual void | onFirstVideoDataReceived (uid_t uid) |
|
virtual void | onFirstAudioFrameDecoded (uid_t uid) |
|
virtual void | onFirstVideoFrameDecoded (uid_t uid, uint32_t width, uint32_t height) |
|
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) |
|
virtual void | onAudioMixingStateChanged (NERtcAudioMixingState state, NERtcAudioMixingErrorCode error_code) |
|
virtual void | onAudioMixingTimestampUpdate (uint64_t timestamp_ms) |
|
virtual void | onAudioEffectFinished (uint32_t effect_id) |
|
virtual void | onLocalAudioVolumeIndication (int volume) |
|
virtual void | onRemoteAudioVolumeIndication (const NERtcAudioVolumeInfo *speakers, unsigned int speaker_number, int total_volume) |
|
virtual void | onAddLiveStreamTask (const char *task_id, const char *url, int error_code) |
|
virtual void | onUpdateLiveStreamTask (const char *task_id, const char *url, int error_code) |
|
virtual void | onRemoveLiveStreamTask (const char *task_id, int error_code) |
|
virtual void | onLiveStreamState (const char *task_id, const char *url, NERtcLiveStreamStateCode state) |
|
virtual void | onAudioHowling (bool howling) |
|
virtual void | onRecvSEIMsg (uid_t uid, const char *data, uint32_t dataSize) |
|
virtual void | onAudioRecording (NERtcAudioRecordingCode code, const char *file_path) |
|
virtual void | onMediaRelayStateChanged (NERtcChannelMediaRelayState state, const char *channel_name) |
|
virtual void | onMediaRelayEvent (NERtcChannelMediaRelayEvent event, const char *channel_name, NERtcErrorCode error) |
|
virtual void | onLocalPublishFallbackToAudioOnly (bool is_fallback, NERtcVideoStreamType stream_type) |
|
virtual void | onRemoteSubscribeFallbackToAudioOnly (uid_t uid, bool is_fallback, NERtcVideoStreamType stream_type) |
|
Public 成员函数 继承自 nertc::IRtcEngineEventHandler |
virtual void | onError (int error_code, const char *msg) |
|
virtual void | onWarning (int warn_code, const char *msg) |
|
virtual void | onReleasedHwResources (NERtcErrorCode result) |
|
virtual void | onJoinChannel (channel_id_t cid, uid_t uid, NERtcErrorCode result, uint64_t elapsed) |
|
virtual void | onReconnectingStart (channel_id_t cid, uid_t uid) |
|
virtual void | onConnectionStateChange (NERtcConnectionStateType state, NERtcReasonConnectionChangedType reason) |
|
virtual void | onRejoinChannel (channel_id_t cid, uid_t uid, NERtcErrorCode result, uint64_t elapsed) |
|
virtual void | onLeaveChannel (NERtcErrorCode result) |
|
virtual void | onDisconnect (NERtcErrorCode reason) |
|
virtual void | onClientRoleChanged (NERtcClientRole oldRole, NERtcClientRole newRole) |
|
virtual void | onUserJoined (uid_t uid, const char *user_name) |
|
virtual void | onUserLeft (uid_t uid, NERtcSessionLeaveReason reason) |
|
virtual void | onUserAudioStart (uid_t uid) |
|
virtual void | onUserAudioStop (uid_t uid) |
|
virtual void | onUserVideoStart (uid_t uid, NERtcVideoProfileType max_profile) |
|
virtual void | onUserVideoStop (uid_t uid) |
|
IRtcEngineEventHandlerEx callback interface class is used to send callback event notifications to the app from SDK. The app gets event notifications from the SDK through inheriting the interface class.
All methods in this interface class have their (empty) default implementations, and the application can inherit only some of the required events instead of all of them. When calling a callback method, the application must not implement time-consuming operations or call blocking-triggered APIs. For example, if you want to enable audio and video, the SDK may be affected in the runtime.
virtual void nertc::IRtcEngineEventHandlerEx::onLocalAudioVolumeIndication |
( |
int |
volume | ) |
|
|
inlinevirtual |
Occurs when the system prompts current local audio volume.
This callback is disabled by default. You can enable the callback by calling the enableAudioVolumeIndication method.
After the callback is enabled, if a local user speaks, the SDK triggers the callback based on the time interval specified in the enableAudioVolumeIndication method.
If a local user sets a mute by calling muteLocalAudioStream, the SDK sets the value of volume as 0, and calls back to the application layer.
- 参数
-
volume | The volume of audio mixing. Value range: 0 to 100. |
virtual void nertc::IRtcEngineEventHandlerEx::onRemoteAudioVolumeIndication |
( |
const NERtcAudioVolumeInfo * |
speakers, |
|
|
unsigned int |
speaker_number, |
|
|
int |
total_volume |
|
) |
| |
|
inlinevirtual |
Occurs when the system prompts the active speaker and the audio volume.
By default, the callback is disabled. You can enable the callback by calling the enableAudioVolumeIndication method. After the callback is enabled, if a local user speaks, the SDK triggers the callback based on the time interval specified in the enableAudioVolumeIndication method.
In the array of speakers returned:
- If a uid is contained in the array returned in the last response but not in the array returned in the current response. The remote user with the uid does not speak by default.
- If the volume is 0, the user does not speak.
- If the array is empty, the remote user does not speak.
- 参数
-
speakers | The array that contains the information about user IDs and volumes is NERtcAudioVolumeInfo. |
speaker_number | The size of speakers array, which indicates the number of speakers. |
total_volume | The total volume (after audio mixing). Value range: 0 to 100. |
virtual void nertc::IRtcEngineEventHandlerEx::onRemoteSubscribeFallbackToAudioOnly |
( |
uid_t |
uid, |
|
|
bool |
is_fallback, |
|
|
NERtcVideoStreamType |
stream_type |
|
) |
| |
|
inlinevirtual |
Occurs when the subscribed remote media stream falls back to an audio-only stream due to poor network conditions or switches back to the audio and video stream after the network condition improves.
If you call setLocalPublishFallbackOption and set option to kNERtcStreamFallbackAudioOnly, this callback is triggered when the locally published stream falls back to audio-only mode due to poor uplink network conditions, or when the audio stream switches back to the audio and video stream after the uplink network condition improves.
- 自从
- V4.3.0
- 参数
-
uid | The ID of a remote user. |
is_fallback | The subscribed remote media stream falls back to audio-only mode or switches back to the audio and video stream.
- true: The subscribed remote media stream falls back to audio-only mode due to poor downstream network conditions.
- false: The subscribed remote media stream switches back to the audio and video stream after the downstream network condition improves.
|
stream_type | The type of the video stream, such as bigstream and substream. |