From ba8f5071684ec1e921fcc9eccdef77a45c8548bb Mon Sep 17 00:00:00 2001 From: "xie.bx" Date: Fri, 25 Nov 2022 19:00:11 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A7=86=E9=A2=91=E8=81=8A=E5=A4=A9=E5=8A=9F?= =?UTF-8?q?=E8=83=BD-=E5=BC=80=E5=8F=91=E4=B8=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/components/chat/ChatPrivateVideo.vue | 30 +++++++++++++++---- 1 file changed, 25 insertions(+), 5 deletions(-) diff --git a/im-ui/src/components/chat/ChatPrivateVideo.vue b/im-ui/src/components/chat/ChatPrivateVideo.vue index 7e84ce1..6d2dfa8 100644 --- a/im-ui/src/components/chat/ChatPrivateVideo.vue +++ b/im-ui/src/components/chat/ChatPrivateVideo.vue @@ -49,10 +49,27 @@ candidates: [], configuration: { iceServers: [{ - 'url': 'turn:www.boxim.online:3478', - 'credential': 'admin123', - 'username': 'admin' - }] + 'url': 'turn:www.boxim.online:3478', + 'credential': 'admin123', + 'username': 'admin' + }, + { + url: 'stun:stun.l.google.com:19302' + }, + { + url: 'stun:stun.anyfirewall.com:3478' + }, + { + url: 'turn:turn.bistri.com:80', + credential: 'homeo', + username: 'homeo' + }, + { + url: 'turn:turn.anyfirewall.com:443?transport=tcp', + credential: 'webrtc', + username: 'webrtc' + } + ] } } }, @@ -134,7 +151,10 @@ this.peerConnection.addTrack(track, stream); }); } - this.peerConnection.IceConnectionStateChange + this.peerConnection.oniceconnectionstatechange = function(event) { + console.log("ICE connection status changed : " + event.target.iceConnectionState) + }; + }, handleMessage(msg) { if (msg.type == this.$enums.MESSAGE_TYPE.RTC_ACCEPT) {