yocontra / rtc-everywhere

Cross-everything WebRTC mega-project
http://rtc.works
MIT License
652 stars 40 forks source link

Camera switching #12

Closed openGeeksLab closed 8 years ago

openGeeksLab commented 8 years ago

Does this module support Camera switching (back, front modes)? If yes, could you show example? For React-Native

RangerMauve commented 8 years ago

The easiest way to do it is to use MediaStreamTrack.getSources to get a list of video sources you could use. Then create a new PeerConnection with the MediaStream from getUserMedia specifying the video property to be the video source you want.

yocontra commented 8 years ago

That ^