An open API service indexing awesome lists of open source software.

https://github.com/z41z/hikvision-plugin-player

Hikvision Player By WebControl Plugin
https://github.com/z41z/hikvision-plugin-player

hikvision javascript player webcontrol

Last synced: 4 months ago
JSON representation

Hikvision Player By WebControl Plugin

Awesome Lists containing this project

README

          

# hikvision-plugin-player
Hikvision Player By WebControl Plugin

## Install

``` node
npm i hikvision-plugin-player -S
```

## CDN

``` js



```

### Usage
``` html
// 必须引用基础库
//
//




import HikvisionPlugin from 'hikvision-plugin-player'
export default {
data() {
return {
}
},
mounted() {
},
methods: {
async init() {
let player = await new HikvisionPlugin.Player({
el: 'player',
width: 800,
height: 600,
layout: '1x1',
host: 'ISC Host',
port: 443,
secret: 'ISC Secret',
appkey: 'ISC Appkey',
isShowToolbar: false
}).init()
// player = {
// isSuccess: Boolean,
// instance: {
// config: Object,
// webControl: WebControl
// },
// msg: String
// }
this.player = player.instance
}
},
components: {
},
}


#player {
width: 800px;
height: 600px;
}


```
### Function
- #### 初始化
``` js
this.player.init()
```
- #### 根据sn播放
``` js
this.player.play(sn, winId = -1)
```
- #### 调整窗口大小
``` js
this.player.resize()
```
- #### 销毁
``` js
this.player.destroy()
```

### 海康Web插件开发指南
- [海康Web插件开发指南](https://unpkg.com/hikvision-plugin-player/dist/视频WEB插件V1.5.2开发指南.pdf)