Файл libVSS.wasm используется для декодирования h265 и загрузки снимков.
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<title>vue-map-skeye-player</title>
<script src="static/SkeyeWebPlayer/SkeyeWebPlayer.js"></script>
</head>
<body>
<div id="app"></div>
<!-- built files will be auto injected -->
</body>
</html>
npm install vue-baidu-map --save
import {BaiduMap, BmView, BmLocalSearch, BmMarker, BmInfoWindow} from "vue-baidu-map";
components: {
BaiduMap, BmView, BmLocalSearch, BmMarker, BmInfoWindow
},
<template>
<div class="bmap">
<baidu-map
class="map"
ak="ydtz9Gf75Pt9swZvc0bWa8t0UWUSxW5I"
:mapStyle="mapStyle"
:center="mapcenter"
:zoom="mapZoom"
:scroll-wheel-zoom="true"
:double-click-zoom="false"
@ready="mapReady">
<template v-for="(item, index) in markerPointData">
<bm-marker
:key="index"
:position="item.markerPoint"
:icon="{url: item.markerIcon, size: {width: 30, height: 30}}"
@click="lookInfo(item, false)">
</bm-marker>
</template>
<!-- информационная форма -->
<InfoWindow ref="InfoWindow" @preview="preview"></InfoWindow>
<!-- Форма монитора -->
<VideoWindow ref="videoWindow"></VideoWindow>
</baidu-map>
</div>
</template>
markerPointData: [
{
cameraId: 1,
url: 'rtsp://39.101.128.80:5540/34020000001310000071/0',
name: «Первая точка мониторинга»,
indexCode: '000001',
ipaddr: '192.168.0.111',
markerPoint: { lng: 103.99104, lat: 30.627748 },
markerIcon: require(`@/assets/camera/camera_0.png`)
}
]
this.map.centerAndZoom(new this.BMap.Point(lng, lat), this.map.getZoom());
plugins: [
new CopyWebpackPlugin([
{
from: path.resolve(__dirname, '../static/SkeyeWebPlayer/libVSS.wasm'),
to: './'
}
])
],