Files
rrweb/packages/rrvideo/README.zh_CN.md
Yun Feng 23d01387f4 rrvideo: improve the video quality and add a progress bar for the CLI tool (#1197)
* refactor rrvideo: use playwright rather than puppeteer

* add a progress bar for the tool

* add tests for cli.ts

* fix build error

* add change log

* update readme file

* Apply a scaling method to improve the resolution of the output video
2023-05-01 14:04:38 +02:00

37 lines
948 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# rrvideo
rrvideo 是用于将 [rrweb](https://github.com/rrweb-io/rrweb) 录制的数据转为视频格式的工具。
![Demo Video](./demo/demo.gif)
## 安装 rrvideo
1. 安装 [Node.JS](https://nodejs.org/en/download/)。
2. 执行 `npm i -g rrvideo` 以安装 rrvideo CLI。
## 使用 rrvideo
### 将一份 rrweb 录制的数据JSON 格式)转换为视频。
```shell
rrvideo --input PATH_TO_YOUR_RRWEB_EVENTS_FILE
```
运行以上命令会在执行文件夹中生成一个 `rrvideo-output.webm` 文件。
### 指定输出路径
```shell
rrvideo --input PATH_TO_YOUR_RRWEB_EVENTS_FILE --output OUTPUT_PATH
```
### 对回放进行配置
通过编写一个 rrvideo 配置文件再传入 rrvideo CLI 的方式可以对回放进行一定的配置。
```shell
rrvideo --input PATH_TO_YOUR_RRWEB_EVENTS_JSON_FILE --config PATH_TO_YOUR_RRVIDEO_CONFIG_FILE
```
rrvideo 配置文件可参考[示例](./rrvideo.config.example.json)。