Jump to content
  • 0

Missing videoTrack in a multitrack stream


krishnaps
 Share

Question

Hi There,

We have a Multitrack web conference implementation using AMS 2.4.1 version. Its working great for our use case, except in one scenario. When there are N (< 3) number of users and they on there camera simultaneously, then few remote users are not rendered as we don't receive the video tracks for those users in `newStreamAvailable`.  We only receive the audio track for those users. We are able to reproduce this quite frequently. 

As a backup, I am trying to poll AMS using getTrackList with main track Id to get all available streams, but I am not getting any message trackList

var jsCmd =
{
    command : "getTrackList",
    streamId : streamId,         // this is roomId or main track id
    token : token
}
 
 

Any insight would be helpful.

Thanks,

 

Edited by krishnaps
Link to comment
Share on other sites

4 answers to this question

Recommended Posts

  • 0

1. N number of users (N > 3) joined a multitrack web conference. 
2. Either initially or later on during the session, all users have there camera turned off.
3. Now all users simultaneously or within a second turned on there camera.
4. Some random users video tracks are not received by remote peers. The audio tracks does get received in newStreamAvailable message for such users.

Some observations:

1. For say 3 users N1, N2 and N3, mostly the user that turned on there camera last there video tracks are not received by all or some of the peers.
2. The publish message is being sent like

 var jsCmd = {
      command: 'publish',
      streamId: streamId,
      token: token,
      video: thiz.localStream.getVideoTracks().length > 0 ? true : false,
      audio: thiz.localStream.getAudioTracks().length > 0 ? true : false,
      mainTrack: RoomID,
    };


    
So we are basically adding the individual streams in the main track.

3. We are trying to get all the tracks from the main track using following command

var jsCmd =
        {
                command : "getTrackList",
                streamId : RoomID,
                token : token,
        }


    
4. We are listening for trackList message, but unfortunately never receives this message from AMS.

5. We are polling the getRoomInfo and in the receiving message in roomInformation message we does get streamId for all peers.

  var jsCmd = {
        command: 'getRoomInfo',
        streamId: streamId,
        room: roomName,
      };

Does our above mentioned implementation make sense for checking all tracks on main track? Any feedback or reference might help us to unblock us.

 

Thanks

Link to comment
Share on other sites

  • 0

I am able to resolve the issue, referred to https://github.com/ant-media/StreamApp/blob/fix/cluster-multi-track-play/src/main/webapp/conference.html.

Following code snippet in `roomInformation` worked for me

 

//Play new streams in list
    if (obj.streams != null) {
        obj.streams.forEach(function(item) {
            tempRoomStreamList.push(item);
            console.log("Stream joined with ID: " + item);
            webRTCAdaptor.play(item, token,
                roomNameBox.value);
        });
    }

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...