WebRTC: Cannot do Peer to Peer connection. Browser Does not ask to Grant permission for Microphone/ Webcam

StackOverflow https://stackoverflow.com/questions/22524318

Pregunta

I am trying to make a 2 person video calling application using WebRTC. The code seems to be bug free, the only problem I am having is that the browser is not asking a prompt to allow for access to Webcam and Mic.

I have hosted the website here and the relevant files are here.

I have checked if the problem is not with the site and just with the Camera/ Mic, but that is not so. When I host my video. The problem is not there.

What is the problem that when I try a peer to peer Web Video call, there is no prompt for access to webcam/ Mic by the browser?

¿Fue útil?

Solución

You haven't included the ps-webrtc-peerjs-final.js in your index.html file. Add the line

<script src="ps-webrtc-peerjs-final.js"></script>

just after the include of peer.min.js and everything will work fine... :D

Otros consejos

Because you are using https,if your using http it will show prompt every time because of security reason,but you are using https its ask only once(means first time )

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top