Bug 271313

Summary: disconnecting bluetooth device rendered in DOM breaks video track
Product: WebKit Reporter: Pontus Fagerström <pontus.fagerstrom>
Component: WebRTCAssignee: Nobody <webkit-unassigned>
Status: RESOLVED DUPLICATE    
Severity: Normal CC: youennf
Priority: P2    
Version: Safari 17   
Hardware: Mac (Apple Silicon)   
OS: macOS 14   

Pontus Fagerström
Reported 2024-03-20 06:36:58 PDT
When a bluetooth device, being rendered in DOM in an HTMLAudioElement, is removed it breaks video track, obtained from navigator.mediaDevices.getUserMedia(). Reproduce like this: 1. https://webrtc.github.io/samples/src/content/devices/input-output/ 2. Use bluetooth microphone (I tested with AirPods A2031 and Sennheiser Momentum 3, version 96.8.3) 3. Make the device disconnect from the computer (I put the Airpods back in the case / turned off the Sennheiser Momentum 3 headphones) 4. See the video image freeze When I reproduce locally in a small lab/experiment project the video tile turns black instead of freezing. I've tested using RTCPeerConnections and on the remote end the incoming video bitrate drops and the video tile turns black. If you do the same thing with an audio device connected via USB the video is not affected. If you don't render the audio in DOM the video is not affected when the bluetooth device is disconnected. I render it like this: 1. create a HTMLAudioElement 2. create a MediaStream 3. add the audio track to the MediaStream 4. do audioElement.srcObject = stream
Attachments
Pontus Fagerström
Comment 1 2024-03-20 06:55:47 PDT
It does not seem to matter if the video and audio tracks were obtained in the same or in separate getUserMedia calls.
youenn fablet
Comment 2 2024-03-22 09:23:10 PDT
I believe this is fixed in bug 270522. Please reopen otherwise. *** This bug has been marked as a duplicate of bug 270522 ***
Pontus Fagerström
Comment 3 2024-08-05 21:55:44 PDT
I understand this might not be the best place to ask, but I'm struggling to find documentation. The issue seems to be fixed in Safari technology preview Release 200 (Safari 18, Webkit 19620.1.1) but not in recently released Safari 17.6 on Sonoma 14.6. The PR that should fix it was merged in March https://github.com/WebKit/WebKit/pull/25487. How do I learn when the PR that was merged is included in a specific Safari version?
Note You need to log in before you can comment on or make changes to this bug.