Add your description here
Project description
WhipPyWeb
WhipPyWeb is a Python tool that allows you to stream your desktop to a web browser using WebRTC. It is designed with OBS in mind.
Installation
You can install WhipPyWeb using pipx:
pipx install whippyweb
whippyweb run
or using Docker:
docker run -p 8080:8080 whippyweb
Features
- Stream from OBS to a (single) web browser
- Very low latency between OBS and web browser
- You only need the Python server to establish the connection, audio and video are streamed directly from OBS to the web browser - there's no overhead of any Python processing (which can be slow).
How it works
sequenceDiagram
participant OBS as OBS
participant WPW as WhipPyWeb
participant BRS as Web Browser
BRS->>WPW: Create websocket connection
activate BRS
activate WPW
Note over OBS,BRS: Stream start
OBS->>WPW: WebRTC offer
activate WPW
WPW->>BRS: WebRTC offer (over websocket)
BRS->>BRS: Create WebRTC Answer
BRS->>WPW: WebRTC answer (over websocket)
WPW->>OBS: WebRTC answer
deactivate WPW
OBS->>BRS: Video and audio stream
Note over OBS,BRS: Stream stop
OBS->>WPW: WebRTC close
activate WPW
WPW->>BRS: WebRTC close (over websocket)
BRS->>BRS: Close WebRTC connection
deactivate BRS
WPW->>OBS: OK
deactivate WPW
deactivate WPW
How I got here
I wanted to improve the experience of an event I'm hosting. I wanted to stream my desktop to a web browser, to share the screen with my audience both in the same room (Projector with a Chromecast) and remotely (Google Meet sharescreen).
Tried RTMP, HLS but the latency was too much - imagine talking about a slide that is 3-12 seconds away from being visible on the screen...
Eventually stumbled upon this Medium article which pointed me to Broadcast-box. Broadcast-box in turn, directed me to OBS2Browser.
Since I wanted to make some changes and I never written a line of code in GO, I decided to write a Python version of OBS2Browser. WhipPyWeb is the result.
Now I can stream from OBS to a web browser, with very low latency.
flowchart LR
gl(Guest Laptop) --HDMI-to-USB-C--> ml(My Laptop with OBS)
ml --With WhipPyWeb--> br(Web Browser)
br --WiFi--> cc(Chromecast) --HDMI--> pr(Projector)
br --> gm(Google Meet)
Usage
Once whippyweb
is running, you can access the player at http://localhost:8080/player
. There you will see instructions on how to configure your OBS instance.
Contributing
Contributions are welcome! Please open an issue or submit a pull request.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file whippyweb-1.0.0.tar.gz
.
File metadata
- Download URL: whippyweb-1.0.0.tar.gz
- Upload date:
- Size: 296.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 122fdb783c846f44d7bdfd9c4f186e4141d8432adec243ece7bbf00b14d853b8 |
|
MD5 | d58afd84f2b833fb9b241f8fadf03c0b |
|
BLAKE2b-256 | 1ffad0768aa9ea64d50af220e1f7f4423106935756f7e812d652bb5b5f0fea54 |
File details
Details for the file whippyweb-1.0.0-py3-none-any.whl
.
File metadata
- Download URL: whippyweb-1.0.0-py3-none-any.whl
- Upload date:
- Size: 296.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 88850e5131c807dbfe507c452879e8b3a488c1d3bf1b784deba11e8c9aad03ae |
|
MD5 | cb93de4c31739dc484ce9ef71ae233cb |
|
BLAKE2b-256 | afaf64301608770311b81f87cc6da11c3c95835a2de21433126d0f0fd04cf249 |