OpenTelecom / WKWebViewRTC

MIT License
94 stars 30 forks source link

What now? #13

Closed bjenkinsgit closed 3 years ago

bjenkinsgit commented 3 years ago

I have a dumb question. I've downloaded the latest and got it working on a couple of iPhones. I was expecting that there would be a way to point to a STUN or TURN server to be able to communicate with another user on their iPhone. What do I have to implement to make that happen?

noahmehl commented 3 years ago

@bjenkinsgit, to be honest, this is not really a function of this project. In theory, you would deliver the standard WebRTC functionality in a URL that the WkWebView session would open. In other words, if it would work in Safari and/or Chrome on the desktop, then it should work on an iPhone/iPad, etc.

Another option is to use something like sip.js to provide structure around creating and using sessions, and around using STUN/TURN.

bjenkinsgit commented 3 years ago

@noahmehl Thanks for the fast reply. Do you happen to have a white paper or something that tells what IS the function of this project and how to use this code? When you say "deliver the standard WebRTC functionality in a URL..." is that what is happening with the following line of code in the ViewController.viewDidLoad() method webView.load(URLRequest(url: URL(string: "https://cordova-rtc.github.io/cordova-plugin-iosrtc-sample/index.html")!))

noahmehl commented 3 years ago

@bjenkinsgit, no, there is no white paper. The readme is the only documentation regarding what the project does.

And yes, the URL: https://cordova-rtc.github.io/cordova-plugin-iosrtc-sample/index.html is a webpage that utilizes the standard browser WebRTC methods, such as:

RTCPeerConnection() is where ICE/STUN/TURN happens.

bjenkinsgit commented 3 years ago

@noahmehl Think on this more, I must...Thx.

sungger commented 3 years ago

video show is black。wkwebviewrtc is not camera。please tell me ???

noahmehl commented 3 years ago

@bjenkinsgit Do you need anything further here?