Nodejs + socket.io build webRTC signaling server to realize LAN audio and video chat

webRTC realizes audio and video chat in LAN

 

The two-way communication between two computers in the local area network is realized. Let us look at the effect first:

 

1. Download Demo

2. Make sure Node.js is installed. Install Node.js tutorial

3. Put the certificate in the project directory and modify the https certificate path in server.js

4. Modify the computer IP in server.js

3. Install dependencies in the project directory

npm install express
npm install socket.io

4. Start

node server.js

Enter the address in two browsers to call

PS: Use the http protocol (stand-alone version of the call) to replace part of the code in server.js

 

Reference link 1: http://www.imooc.com/article/details/id/284638

Reference link 2: https://www.jianshu.com/u/1b74853568da

 

 

 

 

 

 

 

 

 

 

 

Published 52 original articles · praised 34 · 10,000+ views

Guess you like

Origin blog.csdn.net/weixin_43789195/article/details/105705715