Participant
class Participant
Represents a participant in a Meeting.
A Participant can be either a local participant (the current user) or a remote participant. Each participant has an id, display name, mode, and a set of media Streams (audio, video, screen-share).
Use addEventListener to listen for stream and state-change events on this participant.
Obtaining a Participant:
- Local participant: getLocalParticipant
- Remote participants: getParticipants or onParticipantJoined
Code Example:
// Listen for stream events on a remote participant
participant.addEventListener(object : ParticipantEventListener() {
override fun onStreamEnabled(stream: Stream) {
if (stream.kind.equals("video", ignoreCase = true)) {
// Attach video track to a VideoView
}
}
override fun onStreamDisabled(stream: Stream) {
if (stream.kind.equals("video", ignoreCase = true)) {
// Detach video track
}
}
})
Content copied to clipboard
See also
Properties
Functions
Link copied to clipboard
This method can be used to register a ParticipantEventListener on this participant to receive callbacks for stream and state-change events.
Link copied to clipboard
This method can be used to capture a snapshot image from the local participant's webcam.
Link copied to clipboard
This method can be used to request a remote participant to disable their microphone.
Link copied to clipboard
This method can be used to request a remote participant to disable their webcam.
Link copied to clipboard
This method can be used to request a remote participant to enable their webcam.
Link copied to clipboard
This method can be used to get the audio statistics for this participant.
Link copied to clipboard
This method can be used to get the screen-share statistics for this participant.
Link copied to clipboard
This method can be used to get the video statistics for this participant.
Link copied to clipboard
This method can be used to remove all registered ParticipantEventListeners from this participant.
Link copied to clipboard
This method can be used to unregister a previously added ParticipantEventListener.
Link copied to clipboard
This method can be used to set the viewport dimensions for adaptive video quality.