Skip to content
Projects

About

A multi-source, multi-protocol hybrid P2P-CDN streaming player with WebRTC support

Design & Media

How these counts are measured

Measured star growth

in 24h
0
in 7 days
-1
in 15 days
-2
in 1 month
Collecting history

Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.

README_EN.md

Original


PearPlayer.js

A multi-protocol, multi-source and hybrid P2P-CDN streaming media player

. npm jsdelivr License


English

PearPlayer (梨享播放器) [Demo] is a streaming media player framework written completely with HTML5 and JavaScript. Combining HTTP (including HTTPS, HTTP2) and WebRTC, PearPlayer accelerates media streaming on the Web. It supports multiple protocols, multiple sources, and achieves low latency and high bandwidth utilization. With the help of H5 MSE (Media Source Extension) technology, it receives buffers from multiple source nodes and delivers to the player. Finely designed algorithms are adopted to achieve the best scheduling effect and to handle abnormal situations. Thus, PearPlayer can provide end-users with wonderful video watching experience while maximizing the P2P ratio at the same time.

PearPlayer

multisources

Simply import pear-player.min.js to HTML via the <script> tag. Refer to code examples below, or consult /examples/player-test.html or get-started for usages.

Features

  • Plugin-free thanks to the P2P ability based on WebRTC
  • Multi-protocol (HTTP, HTTPS, WebRTC) and multi-source
  • Customized algorithms that provide users with wonderful video watching experience while maximizing the P2P ratio at the same time.
  • Parameter-free by default (dynamic adaptive internally according to bitrate, etc.). Clients can fill in their preferred parameters in advanced mode.
  • Buffers are limited to save bandwidth/traffic for CP users.
  • Support Chrome, Firefox, Opera, IE, Edge and other mainstream browsers; will support Safari, Tencent WeChat and X5/TBS (multi-source transmission is enabled; media playback issues will be well resolved when MSE is supported)
  • Optional access to low cost, high availability Pear Fog CDN
  • Fully encrypted via TLS/DTLS by default, no DPI features; statistical characteristics can be further eliminated using dynamic port mapping of Pear Fog Suite.
  • As easy as using HTML5 <video> tag; easy to integrate with popular player frameworks like video.js
  • With Browser-to-Browser P2P ability (based on WebTorrent)

bitmap

Quick Start

Please copy the following codes into Web HTML5 code, and then open the webpage. Now, it's time to witness the miracle.

<video id="video" controls></video>
<script>
  var player = new PearPlayer('#video', { src: 'https://qq.webrtc.win/tv/Pear-Demo-Yosemite_National_Park.mp4' });
</script>

Usages

Import js file and bind to video tag

First import the

Explore related projects

Loading…