DataChannel Webrtc Swift
问题 I want to create an data channel. But I'm having some difficulties to implement this. I have added the code that runs on the "caller side": func initWebRTC() { RTCInitializeSSL() peerConnectionFactory = RTCPeerConnectionFactory() let mandatoryConstraints = ["OfferToReceiveAudio": "true", "OfferToReceiveVideo": "false"] let optionalConstraints = [ "DtlsSrtpKeyAgreement": "true", "RtpDataChannels" : "true"] mediaConstraints = RTCMediaConstraints.init(mandatoryConstraints: mandatoryConstraints,