docs: update
This commit is contained in:
parent
de9b88609a
commit
4adab30fcb
|
|
@ -96,6 +96,7 @@ Feel free to submit yours in [`Let me know!`](https://github.com/MoePlayer/DPlay
|
|||
- [DPlayer for Discuz!](https://coding.net/u/Click_04/p/video/git): Discuz!
|
||||
- [DPlayer for WordPress](https://github.com/BlueCocoa/DPlayer-WordPress): WordPress
|
||||
- [DPlayerHandle](https://github.com/kn007/DPlayerHandle): WordPress
|
||||
- [Selection](https://github.com/GreatSatan79/Selection): WordPress
|
||||
- [Vue-DPlayer](https://github.com/sinchang/vue-dplayer): Vue
|
||||
- [react-dplayer](https://github.com/hnsylitao/react-dplayer): React
|
||||
|
||||
|
|
|
|||
|
|
@ -506,6 +506,35 @@ const dp = new DPlayer({
|
|||
});
|
||||
```
|
||||
|
||||
### MPEG DASH (Shaka)
|
||||
|
||||
It requires the library [shaka-player](https://github.com/google/shaka-player) and it should be loaded before `DPlayer.min.js`.
|
||||
|
||||
```html
|
||||
<link rel="stylesheet" href="DPlayer.min.css">
|
||||
<div id="dplayer"></div>
|
||||
<script src="shaka-player.compiled.js"></script>
|
||||
<script src="DPlayer.min.js"></script>
|
||||
```
|
||||
|
||||
```js
|
||||
const dp = new DPlayer({
|
||||
container: document.getElementById('dplayer'),
|
||||
screenshot: true,
|
||||
video: {
|
||||
url: 'demo.mpd',
|
||||
type: 'shakaDash',
|
||||
customType: {
|
||||
'shakaDash': function (video, player) {
|
||||
var src = video.src;
|
||||
var playerShaka = new shaka.Player(video); // 将会修改 video.src
|
||||
playerShaka.load(src);
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
```
|
||||
|
||||
### FLV
|
||||
|
||||
It requires the library [flv.js](https://github.com/Bilibili/flv.js) and it should be loaded before `DPlayer.min.js`.
|
||||
|
|
|
|||
|
|
@ -37,6 +37,7 @@ Let's make DPlayer better, feel free to submit yours in [`Let me know!`](https:/
|
|||
- [DPlayer for Discuz!](https://coding.net/u/Click_04/p/video/git): Discuz!
|
||||
- [DPlayer for WordPress](https://github.com/BlueCocoa/DPlayer-WordPress): WordPress
|
||||
- [DPlayerHandle](https://github.com/kn007/DPlayerHandle): WordPress
|
||||
- [Selection](https://github.com/GreatSatan79/Selection): WordPress
|
||||
- [Vue-DPlayer](https://github.com/sinchang/vue-dplayer): Vue
|
||||
- [react-dplayer](https://github.com/hnsylitao/react-dplayer): React
|
||||
|
||||
|
|
|
|||
|
|
@ -38,6 +38,7 @@ search: zh-Hans
|
|||
- [DPlayer for Discuz!](https://coding.net/u/Click_04/p/video/git): Discuz!
|
||||
- [DPlayer for WordPress](https://github.com/BlueCocoa/DPlayer-WordPress): WordPress
|
||||
- [DPlayerHandle](https://github.com/kn007/DPlayerHandle): WordPress
|
||||
- [Selection](https://github.com/GreatSatan79/Selection): WordPress
|
||||
- [Vue-DPlayer](https://github.com/sinchang/vue-dplayer): Vue
|
||||
- [react-dplayer](https://github.com/hnsylitao/react-dplayer): React
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue