This commit is contained in:
yumoqing 2024-08-21 14:24:24 +08:00
parent 7d25d29337
commit 34de714364

View File

@ -157,6 +157,7 @@ bricks.RTCClient = class extends bricks.VBox {
}));
}
send_candidate(event){
console.log('send_candidate(), event=', event);
if (event.candidate) {
this.socket.send(JSON.stringify({
type: 'iceCandidate',
@ -299,6 +300,7 @@ bricks.RTCClient = class extends bricks.VBox {
this.pc.ontrack = event => {
this.remoteVideo.set_stream(event.streams[0]);
};
console.log('createPeerConnection() finished');
}
}