Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/phoboslab/jsmpeg-vnc
A low latency, high framerate screen sharing server for Windows and client for browsers
https://github.com/phoboslab/jsmpeg-vnc
Last synced: 7 days ago
JSON representation
A low latency, high framerate screen sharing server for Windows and client for browsers
- Host: GitHub
- URL: https://github.com/phoboslab/jsmpeg-vnc
- Owner: phoboslab
- Created: 2015-07-27T11:45:28.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2023-09-01T04:31:54.000Z (over 1 year ago)
- Last Synced: 2024-11-29T18:04:10.150Z (14 days ago)
- Language: C
- Homepage:
- Size: 365 KB
- Stars: 2,391
- Watchers: 168
- Forks: 396
- Open Issues: 51
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome - jsmpeg-vnc - A low latency, high framerate screen sharing server for Windows and client for browsers (etc)
- awesome - jsmpeg-vnc - A low latency, high framerate screen sharing server for Windows and client for browsers (etc)
README
# jsmpeg-vnc
A low latency, high framerate screen sharing server and client, viewable in any modern browser.
[More Info & Demo Video](http://phoboslab.org/log/2015/07/play-gta-v-in-your-browser-sort-of)
[Download Binaries](https://github.com/phoboslab/jsmpeg-vnc/releases)
## Usage & Performance Considerations
```
jsmpeg-vnc.exe [options]Options:
-b bitrate in kilobit/s (default: estimated by output size)
-s output size as WxH. E.g: -s 640x480 (default: same as window size)
-f target framerate (default: 60)
-p port (default: 8080)
-c crop area in the captured window as X,Y,W,H. E.g.: -c 200,300,640,480
-i enable/disable remote input. E.g. -i 0 (default: 1)Use "desktop" as the window name to capture the whole Desktop. Use "cursor"
to capture the window at the current cursor position.Example:
jsmpeg-vnc.exe -b 2000 -s 640x480 -f 30 -p 9006 "Quake 3: Arena"To enable mouse lock in the browser (useful for games that require relative
mouse movements, not absolute ones), append "?mouselock" at the target URL
i.e: http://:8080/?mouselock
```For sharing the whole Desktop, Windows' Aero theme should be disabled as it slows down screen capture significantly. When serving a single window (e.g. games), Aero only has a marginal performance impact and can be left enabled.
Capturing and encoding 1920x1080 video narrowly amounts to 60fps on my system and occupies a whole CPU core. Capturing smaller windows significantly speeds up the process. Depending on your Wifi network quality you may also want to dial down the bitrate for large video sizes.
If Windows complains about a missing MSVCR100.dll, install the [Microsoft Visual C++ 2010 Redistributable Package](https://www.microsoft.com/en-us/download/details.aspx?id=5555).
## Technology & License
This App uses [ffmpeg](https://github.com/FFmpeg/FFmpeg) for encoding, [libwebsockets](https://github.com/warmcat/libwebsockets) for the WebSocket server and [jsmpeg](https://github.com/phoboslab/jsmpeg) for decoding in the browser. Note that the jsmpeg version in this repository has been modified to get rid of an extra frame of latency. The server sends each frame with a custom header, so the resulting WebSocket stream is not a valid MPEG video anymore.
The client application (the thing that runs in the browser) is very rudimentary. In particular, the mobile version has some quirks with mouse input and only has touch buttons for the arrow keys, ESC and Enter, though this can be easily extended.
jsmpeg-vnc is published under the [GPLv3 License](http://www.gnu.org/licenses/gpl-3.0.en.html).
If you require my code under a different license, or need some consulting work regarding jsmpeg/jsmpeg-vnc, get in touch: [email protected]