cdnbye 0.4.1

  • Readme
  • Changelog
  • Example
  • Installing
  • 70

English | 简体中文

cdnbye logo

Live/VOD P2P Engine for Flutter

pub

Features #

  • Support iOS and Android platform
  • Support live and VOD streams over HLS protocol(m3u8)
  • Support encrypted HLS stream
  • Support cache to avoid repeating the download of TS file
  • Very easy to integrate with an existing flutter project
  • Support any flutter player
  • Efficient scheduling policies to enhance the performance of P2P streaming
  • Highly configurable
  • Use IP database to group up peers by ISP and regions

Screenshot #

Environment Configuration #

See documentation

Example #

import 'package:flutter/material.dart';
import 'package:video_player/video_player.dart';
import 'package:cdnbye/cdnbye.dart';

// Init p2p engine
_initEngine();

// Start playing video
_loadVideo();

_initEngine() async {
    await Cdnbye.init(
      YOUR_TOKEN,
      config: P2pConfig.byDefault()
    );
}

_loadVideo() async {
    var url = YOUR_STREAM_URL;
    url = await Cdnbye.parseStreamURL(url);           // Parse your stream url
    player = VideoPlayerController.network(url);
    player.play();
}

Obtain Token #

See here

Consloe #

Register your AppId at https://oms.cdnbye.com, where you can view p2p-related information.

Issue & Feature Request

  • If you found a bug, open an issue.
  • If you have a feature request, open an issue.

FAQ #

We have collected some frequently asked questions. Before reporting an issue, please search if the FAQ has the answer to your problem.

Contact Us #

Email:service@cdnbye.com

0.1.0 #

Formal release

0.2.0 #

Update Android native SDK to 0.6.2

0.3.0 #

Add new APIs

0.4.0 #

Update Android and iOS SDK

0.4.1 #

Update Android SDK

example/README.md

cdnbye_example #

Demonstrates how to use the cdnbye plugin.

Getting Started #

This project is a starting point for a Flutter application.

A few resources to get you started if this is your first Flutter project:

For help getting started with Flutter, view our online documentation, which offers tutorials, samples, guidance on mobile development, and a full API reference.

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  cdnbye: ^0.4.1

2. Install it

You can install packages from the command line:

with Flutter:


$ flutter pub get

Alternatively, your editor might support flutter pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:cdnbye/cdnbye.dart';
  
Popularity:
Describes how popular the package is relative to other packages. [more]
45
Health:
Code health derived from static analysis. [more]
99
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
90
Overall:
Weighted score of the above. [more]
70
Learn more about scoring.

We analyzed this package on Nov 20, 2019, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.6.0
  • pana: 0.12.21
  • Flutter: 1.9.1+hotfix.6

Platforms

Detected platforms: Flutter

References Flutter, and has no conflicting libraries.

Health issues and suggestions

Document public APIs. (-1 points)

34 out of 34 API elements have no dartdoc comment.Providing good documentation for libraries, classes, functions, and other API elements improves code readability and helps developers find and use your API.

Maintenance suggestions

The description is too long. (-10 points)

Search engines display only the first part of the description. Try to keep the value of the description field in your package's pubspec.yaml file between 60 and 180 characters.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.1.0 <3.0.0
flutter 0.0.0
Transitive dependencies
collection 1.14.11 1.14.12
meta 1.1.7 1.1.8
sky_engine 0.0.99
typed_data 1.1.6
vector_math 2.0.8
Dev dependencies
flutter_test