remoteTrackStopped

Emitted when any participant in the meeting room stop sharing their microphone, camera, or screen

This event is emitted when any remote participant in the meeting room stop shares their microphone, camera, or screen.

This event is used to remove the remote participant's video or audio from the current user's screen.

meeting.on("remoteTrackStopped", function(remoteTrackItem) {


});

Properties

remoteTrackItem is an object that contains the following properties:

Property

Description

streamId

uniqueId of the video or audio stream

type

type can be video or audio

participantSessionId

participantSessionId of the source Participant

track

MediaStreamTrack. This should be converted into MediaStream object before attaching to html video tag. see example below.

name

name/username of the source user

Example

meeting.on("remoteTrackStopped", function(remoteTrackItem) {
    console.log("remoteTrackStarted", remoteTrackItem);
    document.getElementById(remoteTrackItem.streamId).remove();
});