Appearance
录像
方法名
startRecording
用法
示例
js
if (this.$refs.refLevenUvcMultiCamera) {
this.$refs.refLevenUvcMultiCamera.startRecording({
type: type
}, res => {
if (res.code == 0 && res.data && res.data.path) {
if (res.data.index == 1) {
this.videopath.leftPath = res.data.path;
} else if (res.data.index == 2) {
this.videopath.rightPath = res.data.path;
}
}
this.writeLog(JSON.stringify(res))
})
}参数说明
| 参数名 | 参数类型 | 是否必填 | 默认值 | 参数描述 |
|---|---|---|---|---|
| type | Integer | 是 | 无 | 摄像头位置,1.左侧,2.右侧,0.所有 |
回调
示例
json
{
"message": "",
"code": 0,
"data": {
"index":1,
"status":"finish",
"path":""
}
}回调说明
| 参数名 | 参数类型 | 参数描述 |
|---|---|---|
| message | String | 消息提示 |
| data | Object | 数据对象 |
| data.index | Integer | 当前摄像头索引,1.左侧,2.右侧 |
| data.status | String | 当前录制状态,start:开始录制,finish:录制完成 |
| data.path | String | 录制视频的文件路径 |
| code | Integer | 返回类型,0.成功,其他:失败 |
