GitHub - parsec-cloud/web-client: Parsec client that runs in the browser
source link: https://github.com/parsec-cloud/web-client
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
README.md
Overview
The Parsec web client allows you to connect to a Parsec host via Chrome 69+. It is written in vanilla ES2018 and has no development or runtime dependencies.
Usage
import {Client} from './client.js'; const client = new Client(videoElement); client.connect(sessionId, serverId, { encoder_bitrate: 15, server_resolution_x: 1366, server_resolution_y: 768, ... });
The constructor takes an HTML5 <video>
element and can take an optional second callback argument that can receive events such as connect
, exit
, and shutter
. The connect
method's third argument is the usual Parsec configuration file in JSON format.
For a more detailed example, check out the example directory.
Development
You'll need Node.js to run the development server. This project was tested with node 8.12.0 LTS
.
git clone https://github.com/parsec-cloud/web-client.git
cd web-client
npm start
The development server will be running on port 443, and should be accessed via https://devlocal.info
.
Contributing
Please make sure eslint
is not throwing any errors before submitting a PR. You can run eslint
with --fix
to automatically clean up the style.
npm install -g eslint
eslint web-client/src/*
We hope to see your username on our list of contributors soon! ???
Bugs & Known Issues
- The audio may crackle when using macOS. We will be switching to MSE for Opus with the release of Chrome 70.
Resources
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK