Skip to content

LorDisturbia/webrtc-demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

6 Commits
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

WebRTC Demo

This project is a simple WebRTC demo that establishes a direct P2P WebRTC connection between two clients to exchange video streams. It consists of two parts:

  • WebRTC client: A simple WebRTC client written in React. It connects to the signalling server via WebSocket to broadcast its availability. When two clients are available, they establish a direct P2P WebRTC connection to exchange video streams.
  • WebRTC server: A very simple WebRTC signalling server in NodeJS. It accepts WebSocket connections from clients and broadcasts their availability to other clients. When two clients are available, they establish a direct P2P WebRTC connection to exchange video streams.

You can find more details in the README files of each part, and in this Notion page.

๐ŸŒ Making this work across networks

This demo works out of the box on localhost.

If you want to make it work across different machines on the same network, you simply need to change the WebSocketServer URL in the client to point to the IP address of the machine running the server.

Making this work across the internet is much more difficult, because of NATs and firewalls. You would need to use a STUN/TURN server to relay the WebRTC traffic. You can read more about such sorcery here.

About

A demo client/server architecture for WebRTC

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published