-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from Ezviz-OpenBiz/develop
version: 0.1.0
- Loading branch information
Showing
35 changed files
with
1,380 additions
and
269 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
--- | ||
name: Bug report | ||
about: 创建报告以帮助我们改进( Create a report to help us improve) | ||
title: '' | ||
labels: '' | ||
assignees: '' | ||
--- | ||
|
||
**bug 描述(Describe the bug)** | ||
|
||
对bug是什么的清晰简洁的描述。 (A clear and concise description of what the bug is.) | ||
|
||
**复现(To Reproduce)** | ||
|
||
再现步骤(Steps to reproduce the behavior): | ||
|
||
1. Go to '...' | ||
2. Click on '....' | ||
3. Scroll down to '....' | ||
4. See error | ||
|
||
**预期行为(Expected behavior)** | ||
|
||
对你期望发生的事情的清晰简洁的描述。 (A clear and concise description of what you expected to happen.) | ||
|
||
**截图(Screenshots)** | ||
|
||
如果适用,请添加屏幕截图以帮助解释您的问题。 (If applicable, add screenshots to help explain your problem.) | ||
|
||
**PC 请填写以下信息 (please complete the following information):** | ||
|
||
- OS: [e.g. iOS] | ||
- Browser [e.g. chrome, safari] | ||
- Version [e.g. 22] | ||
|
||
**mobile 请填写以下信息 (please complete the following information):** | ||
|
||
- Device: [e.g. iPhone6] | ||
- OS: [e.g. iOS8.1] | ||
- Browser [e.g. stock browser, safari] | ||
- Version [e.g. 22] | ||
|
||
**附加上下文(Additional context)** | ||
|
||
在此处添加有关该问题的任何其他上下文。 (Add any other context about the problem here.) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
name: build-demos | ||
|
||
on: | ||
push: | ||
branches: ["main", "develop"] | ||
pull_request: | ||
branches: ["main"] | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
matrix: | ||
node-version: [16.x, 18.x, 20.x, 21.x, 22.x] | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
- uses: pnpm/action-setup@v3 | ||
with: | ||
version: 8 | ||
|
||
- name: Build react-demo | ||
working-directory: ./examples/react-app | ||
run: | | ||
pnpm install | ||
pnpm run build | ||
- name: Build vue-demo | ||
working-directory: ./examples/vue-app | ||
run: | | ||
pnpm install | ||
pnpm run build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# 整个流程的名字 | ||
name: install dependencies | ||
# 触发时机,在 tag 被 push 操作触发 | ||
on: | ||
push: | ||
branches: ["main", "develop"] | ||
pull_request: | ||
branches: ["main"] | ||
|
||
# 任务,定义个changelog 的任务 | ||
jobs: | ||
changelog: | ||
name: install dependencies | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
# 设置 Node | ||
- name: Setup Node | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: 18 | ||
cache: npm | ||
registry-url: https://registry.npmjs.org | ||
# 安装依赖 | ||
- uses: pnpm/action-setup@v3 | ||
with: | ||
version: 8 | ||
|
||
- name: Install dependencies | ||
run: pnpm install | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# 整个流程的名字 | ||
name: Release | ||
# 触发时机,在 tag 被 push 操作触发 | ||
on: | ||
push: | ||
tags: | ||
- "v*" | ||
# 任务,定义个changelog 的任务 | ||
jobs: | ||
changelog: | ||
name: Release | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
# # 设置 pnpm | ||
# - name: Setup PNPM | ||
# uses: pnpm/action-setup@v2 | ||
# with: | ||
# version: 8 | ||
# 设置 Node | ||
- name: Setup Node | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: 18 | ||
cache: npm | ||
registry-url: https://registry.npmjs.org | ||
# 安装依赖 | ||
- uses: pnpm/action-setup@v3 | ||
with: | ||
version: 8 | ||
|
||
- name: Install dependencies | ||
run: pnpm install | ||
# # 打包 | ||
# - name: Build Packages | ||
# run: pnpm run build | ||
# 发布npm 发布前执行了prepublishOnly | ||
- name: Publish npm | ||
run: npm publish | ||
env: | ||
# 这里需要几个 Token 变量 | ||
# NPM_TOKEN 需要在 npm 网站生成 | ||
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
node_modules/ | ||
dist/ | ||
examples/**/dist/ | ||
build/ | ||
.cache | ||
# misc | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
## v0.1.0 | ||
|
||
- 支持hls h264/h265直播播放 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
|
||
|
||
https://github.com/numberwolf/h265web.js/blob/master/LICENSE-Free_CN.MD | ||
|
||
|
||
Copyright (c) 2017 Dailymotion (http://www.dailymotion.com) | ||
|
||
Licensed under the Apache License, Version 2.0 (the "License"); | ||
you may not use this file except in compliance with the License. | ||
You may obtain a copy of the License at | ||
|
||
http://www.apache.org/licenses/LICENSE-2.0 | ||
|
||
Unless required by applicable law or agreed to in writing, software | ||
distributed under the License is distributed on an "AS IS" BASIS, | ||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
See the License for the specific language governing permissions and | ||
limitations under the License. | ||
|
||
src/remux/mp4-generator.js and src/demux/exp-golomb.ts implementation in this project | ||
are derived from the HLS library for video.js (https://github.com/videojs/videojs-contrib-hls) | ||
|
||
That work is also covered by the Apache 2 License, following copyright: | ||
Copyright (c) 2013-2015 Brightcove | ||
|
||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | ||
THE SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,52 @@ | ||
# EZUIKit-hls | ||
## @ezuikit/player-hls | ||
|
||
hls 直播播放器, 支持视频H264, H265, 音频 AAC 播放。 | ||
|
||
## 安装 | ||
|
||
```bash | ||
# npm | ||
npm install @ezuikit/player-hls | ||
|
||
# yarn | ||
npm add @ezuikit/player-hls | ||
|
||
# pnpm | ||
pnpm add @ezuikit/player-hls | ||
``` | ||
|
||
### 支持 script 引入 | ||
|
||
```html | ||
<!-- 文件来源 node_modules/@ezuikit/player-hls/dist --> | ||
<script src='./index.umd.js'></script> | ||
``` | ||
|
||
## 使用 | ||
|
||
```ts | ||
// 推荐 | ||
import HlsPlayer from '@ezuikit/player-hls'; | ||
|
||
// 默认自动播放 | ||
const player = new HlsPlayer({ | ||
id: 'app', | ||
url: 'https://open.ys7.com/v3/openlive/E71992743_1_1.m3u8', | ||
staticPath: "/" // decoder静态资源文件夹 默认根目录 | ||
}); | ||
|
||
// 不会立即生效 | ||
// 1. 需要等待静态资源加载完成(js, wasm) | ||
// 2. 需要视频返回并且有视频帧 | ||
player.play(); // | ||
|
||
// 暂停 | ||
player.pause(); | ||
``` | ||
|
||
|
||
注意: 暂不提供CDN地址,decoder静态资源需要放置在自己的服务器下(node_modules/@ezuikit/player-hls/dist 下 decoder.wasm 和 decoder.worker.js 文件, 这两个文件需要在同一个文件夹下) | ||
|
||
注意: 暂不提供CDN地址,decoder静态资源需要放置在自己的服务器下(node_modules/@ezuikit/player-hls/dist 下 decoder.wasm 和 decoder.worker.js 文件, 这两个文件需要在同一个文件夹下) | ||
|
||
注意: 暂不提供CDN地址,decoder静态资源需要放置在自己的服务器下(node_modules/@ezuikit/player-hls/dist 下 decoder.wasm 和 decoder.worker.js 文件, 这两个文件需要在同一个文件夹下) |
Binary file not shown.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Oops, something went wrong.