Paradone is an Open-Source, peer-to-peer powered overlay network for media diffusion in the browser. Its aim is to reduce bandwidth cost of media file diffusion for the server and ISPs while providing a better service quality to the end user.
- It uses a mesh overlay network to share media directly between the users
- It uses the new WebRTC API to provide full P2P capabilities directly inside the web browser
- It uses the new Media Source Extension API to play video with HTML5
- It's a full JavaScript solution which needs no plugin and is invisible to end users
- It's Open-Source and free to use, share and modify
The project was created for and is laureate of the Boost Your Code 2014 contest.
Get more information about the project on:
Paradone is licensed under the AGPLv3. See the LICENSE file for more information.
You can either download one of the releases or clone the project and build the script from source with git and npm.
# Get the project
git clone https://github.com/Paradone/Paradone.git
cd Paradone
# Install dependencies
npm install
# Build the script
npm run buildCopy the file ./dist/paradone.min.js in your project directory and add it to your
website.
<script src="./some/path/to/paradone.min.js"></script>
<script>
paradone.start(options)
</script>The peer element should now be available as paradone.peer. You can also
directly create your own peer instance with new paradone.Peer(options). The
options argument is the same as for paradone.start.
The user will need an up-to-date web browser supporting both WebRTC and Media Source Extension. It can either be Firefox, Google Chrome (or Chromium) or Opera.
The video served to the client must be played within a HTML5 Video tag. You will need to check the codec of your files.
Firefox users need to turn the property media.mediasource.webm.enabled to
true in about:config
The system needs a signaling server allowing users to initiate the communication between them. WebRTC lets you choose your preferred technology for signaling (websocket, xhr, email...).
You can use the tracker system as signaling server.
The project is written in JavaScript and uses npm to manage all dependencies.
Different scripts are available with npm run <cmd> where <cmd> can be one of
the following options:
buildConcatenate and minify the script to generate the filedist/paradone.min.jscleanRemove temporary files and generated builds and docdebugAuto-build on file change with source-map support. Generates the filedist/paradone.jsdocGenerate the documentation of the project indoc/helpDisplay the available commands and their descriptiontestRun all tests oncewatchRun tests on each file change
Every element of the project is referenced under the paradone namespace. Once
the start function called, the script will find the video tags and share the
media between users through the mesh. You can pass options as arguments to the
start function, see the API
for more detailed informations.