NERtc Android SDK  V4.5.0
Public Member Functions | List of all members
com.netease.lava.nertc.sdk.AbsNERtcCallbackEx Class Referenceabstract
Inheritance diagram for com.netease.lava.nertc.sdk.AbsNERtcCallbackEx:
com.netease.lava.nertc.sdk.NERtcCallbackEx com.netease.lava.nertc.sdk.NERtcCallback

Public Member Functions

abstract void onJoinChannel (int result, long channelId, long elapsed, long uid)
 
abstract void onLeaveChannel (int result)
 
abstract void onUserJoined (long uid)
 
abstract void onUserLeave (long uid, int reason)
 
abstract void onUserAudioStart (long uid)
 
abstract void onUserAudioStop (long uid)
 
abstract void onUserVideoStart (long uid, int maxProfile)
 
abstract void onUserVideoStop (long uid)
 
abstract void onDisconnect (int reason)
 
abstract void onError (int code)
 
void onClientRoleChange (int oldRole, int newRole)
 
void onUserSubStreamVideoStart (long uid, int maxProfile)
 
void onUserSubStreamVideoStop (long uid)
 
void onUserAudioMute (long uid, boolean muted)
 
void onUserVideoMute (long uid, boolean muted)
 
void onFirstAudioDataReceived (long uid)
 
void onFirstVideoDataReceived (long uid)
 
void onFirstAudioFrameDecoded (long userID)
 
void onFirstVideoFrameDecoded (long userID, int width, int height)
 
void onUserVideoProfileUpdate (long uid, int maxProfile)
 
void onAudioDeviceChanged (final int selected)
 
void onAudioDeviceStateChange (int deviceType, int deviceState)
 
void onVideoDeviceStageChange (int deviceState)
 
void onConnectionTypeChanged (int newConnectionType)
 
void onReconnectingStart ()
 
void onReJoinChannel (int result, long channelId)
 
void onAudioMixingStateChanged (int reason)
 
void onAudioMixingTimestampUpdate (long timestampMs)
 
void onAudioEffectFinished (int effectId)
 
void onLocalAudioVolumeIndication (int volume)
 
void onRemoteAudioVolumeIndication (NERtcAudioVolumeInfo[] volumeArray, int totalVolume)
 
void onLiveStreamState (String taskId, String pushUrl, int liveState)
 
void onConnectionStateChanged (int state, int reason)
 
void onCameraFocusChanged (Rect rect)
 
void onCameraExposureChanged (Rect rect)
 
void onRecvSEIMsg (long userID, String seiMsg)
 
void onAudioRecording (int code, String filePath)
 
void onWarning (int code)
 
void onMediaRelayStatesChange (int state, String channelName)
 
void onMediaRelayReceiveEvent (int event, int code, String channelName)
 
void onLocalPublishFallbackToAudioOnly (boolean isFallback, NERtcVideoStreamType streamType)
 
void onRemoteSubscribeFallbackToAudioOnly (long uid, boolean isFallback, NERtcVideoStreamType streamType)
 
void onLastmileQuality (int quality)
 
void onLastmileProbeResult (LastmileProbeResult result)
 

Detailed Description

A simple implement for NERtcCallbackEx

Member Function Documentation

◆ onAudioDeviceChanged()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onAudioDeviceChanged ( final int  selected)

Occurs when the audio device is changed.

Parameters
selectedindicates the selected device. For more information, see NERtcConstants.AudioDevice.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onAudioDeviceStateChange()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onAudioDeviceStateChange ( int  deviceType,
int  deviceState 
)

Occurs when the state of the audio device is changed.

Parameters
deviceTypeindicates the type of the device. For more information, see NERtcConstants.AudioDeviceType.
deviceStateindicates the state of the audio device. For more information, see NERtcConstants.AudioDeviceState.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onAudioEffectFinished()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onAudioEffectFinished ( int  effectId)

Occurs when a music file finishes playing.

Parameters
effectIdindicates the ID of the specified audio effect. Each audio effect has a unique ID.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onAudioMixingStateChanged()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onAudioMixingStateChanged ( int  reason)

Occurs when the state of the operation on a local music file is changed.
If you call the startAudioMixing method to play a mixing music file and the state of the playing operation changes, the callback is triggered.

Parameters
reasonNERtcConstants.AudioMixingError#AUDIO_MIXING_FINISH indicates the music file finishes playing. Other status codes indicate that playing the music file fails. For more information, see NERtcConstants.AudioMixingError.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onAudioMixingTimestampUpdate()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onAudioMixingTimestampUpdate ( long  timestampMs)

Occurs when the timestamp of a playing music file is updated.
If you call the startAudioMixing method to play a mixing music file and the progress of the playing operation changes, the callback is triggered.

Parameters
timestampMsindicates the progress of the music file playing. Unit: milliseconds.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onAudioRecording()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onAudioRecording ( int  code,
String  filePath 
)

Occurs when displaying the state of audio recording.

Parameters
codeindicates the status code of the audio recording. For more information, see NERtcConstants.AudioRecordingCode.
filePathindicates the path based on which the recording file is stored.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onCameraExposureChanged()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onCameraExposureChanged ( Rect  rect)

Occurs when the camera exposure position changes.
The callback is triggered if a local user calls the setCameraExposurePosition method to change the exposure position.

Parameters
rectindicates the new exposure position.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onCameraFocusChanged()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onCameraFocusChanged ( Rect  rect)

Occurs when the camera focus position changes.
The callback indicates that the camera focus position changes.
The callback is triggered if a local user calls the setCameraFocusPosition method to change focus position.

Parameters
rectindicates the new focus position.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onClientRoleChange()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onClientRoleChange ( int  oldRole,
int  newRole 
)

Occurs when a user changes the role in live streaming.
After the user joins a room, the user can call the setClientRole method to change roles. Then, the callback is triggered. For example, switching from host to audience, or from audience to host.

Parameters
oldRoleindicates the role before the change. For more information, see NERtcConstants.UserRole.
newRoleindicates the role after the change. For more information, see NERtcConstants.UserRole.
Note
In live streaming, if you join a room and successfully call this method to change roles, the following callback functions are triggered.
  • If the role is changed from host to audience, the onClientRoleChange callback is locally triggered, and the onUserLeave callback is remotely triggered.
  • If the role is changed from audience to host, the onClientRoleChange callback is locally triggered, and the onUserJoined callback is remotely triggered.

Implements com.netease.lava.nertc.sdk.NERtcCallback.

◆ onConnectionStateChanged()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onConnectionStateChanged ( int  state,
int  reason 
)

Occurs when the channel connection state is changed.
The callback is triggered when the channel connection state is changed. The callback returns the current channel connection state and the reason why the state changes.

Parameters
state        indicates the channel connection state. For more information, see NERtcConstants.ConnectionState.
reason       indicates the reason why the channel state changes. For more information, see NERtcConstants.ConnectionStateChangeReason.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onConnectionTypeChanged()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onConnectionTypeChanged ( int  newConnectionType)

Occurs when the local network type is changed.
If the connection type of the local network changes, the callback is triggered and returns the network connection type that is being used.

Parameters
newConnectionTypeindicates the current local network type. For more information, see NERtcConstants.ConnectionType.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onDisconnect()

abstract void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onDisconnect ( int  reason)
abstract

Indicates that connection breaks down and the SDK fails to connect to the server three consecutive times.

Parameters
reasonindicates the reason for network disconnection. For more information, see NERtcConstants.ErrorCode.
Note
- The callback function is triggered if the SDK fails to connect to the server three consecutive times after the joinChannel is successfully called.
  • If the SDK fails to connect to the server three consecutive times, the SDK stops retries.

Implements com.netease.lava.nertc.sdk.NERtcCallback.

◆ onError()

abstract void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onError ( int  code)
abstract

Occurs when an error occurs.
The callback is triggered to report an error related to network or media during SDK runtime.
In most cases, the SDK cannot fix the issue and resume running. The SDK requires the app to take action or informs the user about the issue.

Parameters
codeNERtcConstants.RuntimeError

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onFirstAudioDataReceived()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onFirstAudioDataReceived ( long  uid)

Occurs when the first audio frame from a remote user is received.

Parameters
uidindicates the ID of a remote user whose audio streams are sent.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onFirstAudioFrameDecoded()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onFirstAudioFrameDecoded ( long  userID)

Occurs when the first audio frame from a remote user is decoded.

Parameters
userIDindicates the ID of a remote user whose audio streams are sent.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onFirstVideoDataReceived()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onFirstVideoDataReceived ( long  uid)

Occurs when the first video frame from a remote user is received.
If the first video frame from a remote user is displayed in the view, the callback is triggered.

Parameters
uidindicates the ID of a remote user whose audio streams are sent.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onFirstVideoFrameDecoded()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onFirstVideoFrameDecoded ( long  userID,
int  width,
int  height 
)

Occurs when the first video frame from a remote user is received.
If the engine receives the first frame of remote video streams, the callback is triggered. The callback allows the app to set the video canvas.

Parameters
userIDindicates the ID of a remote user whose video streams are sent.
widthindicates the width of the first video frame. Unit: px.
heightindicates the height of the first video frame. Unit: px.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onJoinChannel()

abstract void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onJoinChannel ( int  result,
long  channelId,
long  elapsed,
long  uid 
)
abstract

Occurs when a user joins a room. The callback indicates that the client has already signed in.

Parameters
resultA value of 0 indicates that a user joins a room. Otherwise, the user fails to join a room. For more information, see NERtcConstants.ErrorCode.
channelIdThe ID of the room that the client joins.
elapsedThe time consumed from calling the joinChannel method to the time when the event occurs. Unit: milliseconds.
uidUser ID.

Implements com.netease.lava.nertc.sdk.NERtcCallback.

◆ onLastmileProbeResult()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onLastmileProbeResult ( LastmileProbeResult  result)

Reports the last-mile network probe result.
This callback describes a detailed last-mile network detection report of a local user before joining a channel. The report provides objective data about the upstream and downstream network quality, including network jitter and packet loss rate. You can use the report to objectively predict the network status of local users during an audio and video call.
The SDK triggers this callback within 30 seconds after the app calls the startLastmileProbeTest method.

Since
V4.5.0
Parameters
resultThe uplink and downlink last-mile network probe test result. For more information, see LastmileProbeResult.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onLastmileQuality()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onLastmileQuality ( int  quality)

Reports the last mile network quality of the local user once every two seconds before the user joins the channel.
After the application calls the startLastmileProbeTest method, this callback reports once every five seconds the uplink and downlink last mile network conditions of the local user before the user joins the channel.

Since
V4.5.0
Parameters
qualityThe last mile network quality.
  • QUALITY_UNKNOWN(0):Unknown network quality.
  • QUALITY_EXCELLENT(1):Excellent network quality.
  • QUALITY_GOOD(2):Good network quality is close to the excellent level but has the bitrate is lower an excellent network.
  • QUALITY_POOR(3):Poor network does not affect communication.
  • QUALITY_BAD(4):Users can communicate with each other without smoothness.
  • QUALITY_VBAD(5):The network quality is very poor. Basically users are unable to communicate.
  • QUALITY_DOWN(6):Users are unable to communicate with each other.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onLeaveChannel()

abstract void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onLeaveChannel ( int  result)
abstract

Occurs when a user leaves a room.
After an app calls the leaveChannel method, SDK prompts whether the app successfully exits the room.

Parameters
result0 indicates success. Other values indicate failure. For more information about error codes, see NERtcConstants.ErrorCode. When a user switches rooms, the code parameter takes NERtcConstants.ErrorCode::LEAVE_CHANNEL_FOR_SWITCH.

Implements com.netease.lava.nertc.sdk.NERtcCallback.

◆ onLiveStreamState()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onLiveStreamState ( String  taskId,
String  pushUrl,
int  liveState 
)

Occurs when the state of live streams is changed.

Parameters
taskIdindicates the ID of the push task.
pushUrlindicates the URL of the push task.
liveStateindicates the state of live streams. For more information, see NERtcConstants.LiveStreamState.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onLocalAudioVolumeIndication()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onLocalAudioVolumeIndication ( int  volume)

Occurs when the system prompts the current local 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.

Parameters
volumeindicates the audio volume. Value range: 0 to 100.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onLocalPublishFallbackToAudioOnly()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onLocalPublishFallbackToAudioOnly ( boolean  isFallback,
NERtcVideoStreamType  streamType 
)

Occurs when the published local media stream falls back to an audio-only stream due to poor network conditions or switches back to audio and video stream after the network conditions improve.
If you call setLocalPublishFallbackOption and set the option to AUDIO_ONLY, this callback is triggered when the locally published stream falls back to the audio-only mode due to poor upstream network conditions, or when the audio stream switches back to the audio and video stream after the upstream network conditions improve.

Parameters
isFallbackindicates that the locally published stream falls back to the audio-only mode or switches back to audio and video stream.
  • true: The locally published stream falls back to the audio-only mode due to poor upstream network conditions.
  • false: The audio stream switches back to the audio and video stream after the upstream network conditions improve.
streamTypeindicates the type of the video stream, such as mainstream and secondary stream.
Since
V4.3.0

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onMediaRelayReceiveEvent()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onMediaRelayReceiveEvent ( int  event,
int  code,
String  channelName 
)

Reports events during the media stream relay.

Parameters
eventindicates the media stream relay event. For more information, see NERtcConstants.ChannelMediaRelayEvent.
codeindicates an error code. For more information, see NERtcConstants.ErrorCode.
channelNamethe name of the destination room where the media streams are forwarded.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onMediaRelayStatesChange()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onMediaRelayStatesChange ( int  state,
String  channelName 
)

Occurs when the state of the media stream relay changes.

Parameters
stateindicates the state of the media stream relay. For more information, see NERtcConstants.ChannelMediaRelayState.
channelNamethe name of the destination room where the media streams are forwarded.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onReconnectingStart()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onReconnectingStart ( )

Occurs when reconnection starts.
If a client is disconnected from the server, the SDK starts reconnecting. The callback is triggered when the reconnection starts. For more information about reconnection, see onReJoinChannel and onDisconnect.

See also
com.netease.lava.nertc.sdk.NERtcCallbackEx::onReJoinChannel(int, long)
com.netease.lava.nertc.sdk.NERtcCallbackEx::onDisconnect(int)

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onRecvSEIMsg()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onRecvSEIMsg ( long  userID,
String  seiMsg 
)

Occurs when the content of remote Supplemental Enhancement Information (SEI) is received.
After a remote client successfully sends SEI, the local client receives a message returned by the callback.

Parameters
userIDindicates the ID of the user that sends SEI.
seiMsgindicates the message that contains SEI.
See also
NERtcEx::sendSEIMsg(String)

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onReJoinChannel()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onReJoinChannel ( int  result,
long  channelId 
)

Occurs when a user rejoins a room.
If a client is disconnected from the server due to poor network quality, the SDK starts reconnecting. If the client and server are reconnected, the callback is triggered.

Parameters
resultA value of 0 indicates success. Other values indicate that the user fails to rejoin the room. For more information about error codes, see NERtcConstants.ErrorCode.
channelIdindicates the ID of the room that the client joins.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onRemoteAudioVolumeIndication()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onRemoteAudioVolumeIndication ( NERtcAudioVolumeInfo[]  volumeArray,
int  totalVolume 
)

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 returned array:

  • If a uid is contained in the array returned in the last response but not in the array returned in the current time. The remote user with the uid does not speak.
  • If the volume is 0, the user does not speak.
  • If the array is empty, the remote user does not speak.
    Parameters
    volumeArrayindicates the array that contains the information about user IDs and volumes. For more information, see stats.NERtcAudioVolumeInfo.
    totalVolumeindicates the volume of mixed audio. Value range: 0 to 100.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onRemoteSubscribeFallbackToAudioOnly()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onRemoteSubscribeFallbackToAudioOnly ( long  uid,
boolean  isFallback,
NERtcVideoStreamType  streamType 
)

Occurs when the subscribed remote media stream falls back to audio-only stream due to poor network conditions or switches back to video stream after the network conditions improve.
If you call setRemoteSubscribeFallbackOption and set the option to AUDIO_ONLY, this callback is triggered when the subscribed remote media stream falls back to the audio-only mode due to poor downstream network conditions, or when the subscribed remote media stream switches back to the audio and video stream after the downstream network conditions improve.

Since
V4.3.0
Parameters
uidindicates the ID of a remote user.
isFallbackindicates that the subscribed remote media stream falls back to the audio-only mode or switches back to the audio and video stream.
  • true: The subscribed remote media stream falls back to the 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 conditions improve.
streamTypeindicates the type of the video stream, such as mainstream and secondary stream.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onUserAudioMute()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onUserAudioMute ( long  uid,
boolean  muted 
)

Occurs when a remote user stops/resumes sending audio streams.

Parameters
uidindicates the ID of the user whose audio streams are sent.
mutedspecifies whether to stop sending audio streams.
  • true: The user stops sending audio streams.
  • false: The user resumes sending audio streams.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onUserAudioStart()

abstract void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onUserAudioStart ( long  uid)
abstract

Occurs when a remote user enables audio.

Parameters
uidindicates the ID of the user that leaves the room.

Implements com.netease.lava.nertc.sdk.NERtcCallback.

◆ onUserAudioStop()

abstract void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onUserAudioStop ( long  uid)
abstract

Occurs when a remote user disables audio.

Parameters
uidindicates the ID of the user that leaves the room.

Implements com.netease.lava.nertc.sdk.NERtcCallback.

◆ onUserJoined()

abstract void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onUserJoined ( long  uid)
abstract

Occurs when a remote user joins the current room.
The callback function prompts that a remote user joins the room and returns the ID of the user that joins the room. If the user ID already exists, the remote user also receives a message that the user already joins the room, which is returned by the callback function.
The callback function will be triggered in the following cases:

  • A remote user joins the room by calling the joinChannel method.
  • A remote user rejoins the room after the client is disconnected.
    Parameters
    uidindicates the ID of the user that joins the room.

Implements com.netease.lava.nertc.sdk.NERtcCallback.

◆ onUserLeave()

abstract void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onUserLeave ( long  uid,
int  reason 
)
abstract

Occurs when a remote user leaves a room.
Prompts that a remote user leaves the room or becomes disconnected.
A user leaves a room due to the following reasons: the user exit the room or connections time out.

  • If a user exit the room, the user will receive a message that the user leaves the room.
  • If connections time out, the user does not receive any data packets for a period of 40 to 50 seconds, then the user becomes disconnected.
    Parameters
    uidindicates the ID of the user that leaves the room.
    reasonThe reason why user leaves the channel.

Implements com.netease.lava.nertc.sdk.NERtcCallback.

◆ onUserSubStreamVideoStart()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onUserSubStreamVideoStart ( long  uid,
int  maxProfile 
)

Occurs when a remote user enables screen sharing substream channel.

Parameters
uidindicates the ID of a remote user.
maxProfileindicates the resolution of the remote video. For more information, see NERtcConstants.VideoProfile.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onUserSubStreamVideoStop()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onUserSubStreamVideoStop ( long  uid)

Occurs when a remote user stops screen sharing using the substream channel.

Parameters
uidindicates the ID of a remote user.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onUserVideoMute()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onUserVideoMute ( long  uid,
boolean  muted 
)

Occurs when a remote user stops or resumes sending video streams.

Parameters
uidindicates the ID of the user whose video streams are sent.
mutedspecifies whether to stop sending video streams.
  • true: The user stops sending video streams.
  • false: The user resumes sending video streams.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onUserVideoProfileUpdate()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onUserVideoProfileUpdate ( long  uid,
int  maxProfile 
)

Occurs when the profile of the video streams from a remote user is updated.

Parameters
uidindicates the ID of a remote user.
maxProfilesets the video parameters. For more information, see NERtcConstants.VideoProfile.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onUserVideoStart()

abstract void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onUserVideoStart ( long  uid,
int  maxProfile 
)
abstract

Occurs when a remote user enables video.

Parameters
uidindicates the ID of the user that sends the video streams.
maxProfilesets the video parameters. For more information, see NERtcConstants.VideoProfile.

Implements com.netease.lava.nertc.sdk.NERtcCallback.

◆ onUserVideoStop()

abstract void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onUserVideoStop ( long  uid)
abstract

Occurs when a remote user disables video.

Parameters
uidindicates the ID of a remote user.

Implements com.netease.lava.nertc.sdk.NERtcCallback.

◆ onVideoDeviceStageChange()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onVideoDeviceStageChange ( int  deviceState)

Occurs when the state of the video device is changed.
The callback returns that the state of the video device changes. For example, the device is unplugged or removed. If an external camera that the device uses is unplugged, the video streaming is interrupted.

Parameters
deviceStateindicates the state of the audio device. For more information, see NERtcConstants.VideoDeviceState.

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.

◆ onWarning()

void com.netease.lava.nertc.sdk.AbsNERtcCallbackEx.onWarning ( int  code)

Reports an error.
The callback is triggered to report a warning related to network or media during SDK runtime.
In most cases, the app ignores the warning message and the SDK resumes running.

Parameters
codeindicates the waring code. NERtcConstants.WarningCode

Implements com.netease.lava.nertc.sdk.NERtcCallbackEx.


The documentation for this class was generated from the following file: