[Webkit-unassigned] [Bug 211483] New: WebRTC replaceTrack adding latency

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue May 5 19:46:17 PDT 2020


https://bugs.webkit.org/show_bug.cgi?id=211483

            Bug ID: 211483
           Summary: WebRTC replaceTrack adding latency
           Product: WebKit
           Version: Safari 13
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: WebRTC
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: marc at launchinteractive.com.au
                CC: youennf at gmail.com

I'm using the following code to switch cameras on iOS. It works, however it seems to add around 1s of latency to the video. Each time I switch cameras it appears to grow. I have managed to replicate it in Safari Technology Preview.

navigator.mediaDevices
  .getUserMedia({
    video: {
      deviceId: {
        exact: selectedCamera
      }
    }
  })
  .then(function(stream) {
    let videoTrack = stream.getVideoTracks()[0];
      var sender = pc.getSenders().find(function(s) {
        return s.track.kind == videoTrack.kind;
      });
      sender.replaceTrack(videoTrack);
  })
  .catch(function(err) {
    console.error('Error happens:', err);
  });

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20200506/365e98cf/attachment-0001.htm>


More information about the webkit-unassigned mailing list