Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jaxwilko/wn-mediastream-plugin
WinterCMS plugin adding support for streaming html5 videos
https://github.com/jaxwilko/wn-mediastream-plugin
Last synced: 3 months ago
JSON representation
WinterCMS plugin adding support for streaming html5 videos
- Host: GitHub
- URL: https://github.com/jaxwilko/wn-mediastream-plugin
- Owner: jaxwilko
- Created: 2021-10-11T13:18:24.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2022-04-10T16:06:10.000Z (almost 3 years ago)
- Last Synced: 2024-09-21T10:17:00.378Z (4 months ago)
- Language: PHP
- Size: 15.6 KB
- Stars: 5
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# Winter MediaStream
### Intro
This plugin adds streaming support for html5 videos.
### Installation
```shell
composer install jaxwilko/wn-mediastream-plugin
```### Usage
Once installed, you can use the `video` component to add a video to your page:
```html
title = "Example"
url = "/example"
is_hidden = 0[video]
==
{% styles %}
{% component 'video' file='media/videos/example.mp4' %}
```> If you're not using the `{% styles %}` tag, you'll need to include
> `/plugins/jaxwilko/mediastream/assets/css/video.css` yourself.The video component supports the following properties:
| Name | Type | Description |
|----------------|----------|--------------------------|
| `file` | `string` | the file to display |
| `disable_meta` | `bool` | disable schema data |
| `lazy` | `bool` | enable lazy load support |> Lazy loading support is compatible with [verlok/vanilla-lazyload](https://github.com/verlok/vanilla-lazyload).
The `file` property is the path to your video within the media storage.
E.g. `file='videos/example.mp4'` will load `storage/app/media/videos/example.mp4` when using local storage.
#### Metadata
Video metadata can be added via the backend, this is used to support the `VideoObject` schema.
#### Thumbnails
By default, if the file is in local storage a thumbnail will be generated using ffmpeg. If the file is remote, then
ffmpeg will not be able to generate the thumbnail and you will have to supply your own. This can also be done via
the MediaStream Meta tab in the backend.The meta thumbnail will also be used instead of the generated one if present.