-
-
Notifications
You must be signed in to change notification settings - Fork 25
Incorrect video feed for UVC devices in Chrome on Linux and ChromeOS #14
Comments
Can you verify that the problem device isn't present in the array printed by this code: window.navigator.mediaDevices.enumerateDevices().then(devices => console.log(devices)) |
Sorry, is the issue that you can see the device in the sources list, but the feed is from the default camera? |
Yes, sorry I didn't make that more clear. That's exactly it, I have 2 UVC devices, they both show up in the sources list but selecting them just displays the built-in webcams actual video content. |
Alright, let's make sure WBS isn't just grabbing the wrong stream. Get the device ID of the UVC device with the above snippet, and plug it into here (with dev console): DEVICE = '78da83489276ec70f0068cba07fa4b6d797afd8b131017f72f11cb4308980ef8'; //<-- deviceId
window.navigator.getUserMedia({audio:{exact:DEVICE}, video:{exact:DEVICE}}, (stream) => {
var vid = document.createElement('video');
vid.srcObject = stream
vid.controls = true
document.body.appendChild(vid)
}, (err) => console.error(err)) If the created video element shows your UVC stream, we know it's just a logic bug. Otherwise, we have a nice way to reproduce with Chrome. |
Thanks. I don't have access to the devices at the moment so I'll try this once I have them again tomorrow. |
Sorry to take so long to reply, I didn't have access to my gear for a little while. I've done some tests with the snippets above and it shows the same (first video src) each time, despite using a different videoinputs deviceId. However I have been able to hack up a version of the webrtc sample demo which does allow me to ahve both video inputs displaying in separate I'll keep investigating more the next time a have a chance. |
Hi it seems that UVC attached devices such as usb webcams or in my case hdmi->usb
dongles are not even working properly in Chrome, both on a couple of Chromebooks I have here (pixelbook on beta channel v68) and on a ubuntu 16.04 laptop running Chrome 69, though the devices are accessible just fine via native linux apps (eg. OBS) in ubuntu on same laptop. I can't try OBS on the Pixelbook as the linux container functionality there does not yet supported access to usb devies within the containers.
Interesting thing is that in Chrome on Ubuntu and on the Pixelbook, using the live demo for WBS the UVC device does show up in the list of available audio/video sources, but if selected, the video feed that is displayed is actually just for the builtin webcam not from the UVC source.
I suspect this is a bug in Chrome, but wanted to raise this here in case this is due to a bug in WBS, before I went ahead and filed bugs reports in the Chromium bugtracker.
The text was updated successfully, but these errors were encountered: