[Webkit-unassigned] [Bug 179363] New: iOS calling getUserMedia() again kills video display of first getUserMedia()

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Nov 6 23:16:54 PST 2017


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

            Bug ID: 179363
           Summary: iOS calling getUserMedia() again kills video display
                    of first getUserMedia()
           Product: WebKit
           Version: Safari 11
          Hardware: iPhone / iPad
                OS: iOS 11
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: WebRTC
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: webkit at xylil.com
                CC: youennf at gmail.com

Verified by the reference code below:

On iOS, a second call to getUserMedia() kills the display of a video stream obtained by an earlier call to getUserMedia(). The original stream displays fine until the subsequent getUserMedia() call, then goes black.

Note that this doesn't happen on Desktop Safari, only on iOS Safari in my tests.

Reference code:

<!DOCTYPE html>
<html>
  <body>
    <div>
      <video id="video1" autoplay playsinline></video>
    </div>
    <script type="text/javascript">
      var constraints1 = {
        audio: false,
        video: {
          height: {
            max: 480,
          },
          width: {
            max: 640,
          },
        },
      };
      navigator.mediaDevices.getUserMedia(constraints1).then(function(stream) {
        var video1 = document.getElementById('video1');
        video1.srcObject = stream;
      }).catch(function(err) {
        console.error("Device access checks failed: ", err, constraints1);
      });
      var constraints2 = {
        audio: false,
        video: true,
      };
      navigator.mediaDevices.getUserMedia(constraints2).then(function(stream) {
      }).catch(function(err) {
        console.error("Device access checks failed: ", err, constraints2);
      });
    </script>
  </body>
</html>

-- 
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/20171107/05db9d9d/attachment.html>


More information about the webkit-unassigned mailing list