Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

WebRTC (getUserMedia) on CEF not working. But it works on Chrome. Any ideas?

I have a bare bones web video chat page that works on Chrome. Kind of like apprtc.appspot.com But I want to embed this functionality on c++/c# my application.

So I tried Chromium Embedded Framework (in short, CEF, using cefclient.exe) and WebRTC (getUserMedia) but webcam connectivity is not working at all. I get an error "Failed to get access to local media. Error code was 1."

But in the CEF wiki, it is claimed that WebRTC was added to CEF. The CEF version I am trying out is 3.1364.1094 for Windows.

Any ideas? Does WebRTC really work with CEF? Maybe I may have missed out some steps to make WebRTC work on CEF.

Another observation is that CEF does not show the permissions bar when running a WebRTC webcam demo. I hope this might be the clue though.

like image 677
juliuscarvajal21 Avatar asked Oct 21 '22 17:10

juliuscarvajal21


1 Answers

You can pass CEF a list of command line arguments. I think the one you want might be:

--enable-media-stream

though you could also try

--enable-usermedia-screen-capturing

like image 54
sandover Avatar answered Oct 24 '22 11:10

sandover