| | |
| | | * @Author: shuishen 1109946754@qq.com |
| | | * @Date: 2024-11-09 15:41:35 |
| | | * @LastEditors: shuishen 1109946754@qq.com |
| | | * @LastEditTime: 2024-12-02 18:36:34 |
| | | * @LastEditTime: 2024-12-06 16:50:50 |
| | | * @FilePath: \bigScreen\src\views\pd\components\dynamicPanel.vue |
| | | * @Description: |
| | | * |
| | |
| | | lng: 115.10343807, |
| | | lat: 27.27256126 |
| | | }, |
| | | linePosition: '115.10341051,27.27251643,80;115.10357817,27.27278003,80', |
| | | linePosition: '115.10341051,27.27251643,64;115.10357817,27.27278003,64', |
| | | lineTime: 5000, |
| | | |
| | | threeContent: '关闭绿源污水处理厂旁雨水排口,拦截污染水体。', |
| | |
| | | lng: 115.10627858, |
| | | lat: 27.29434439 |
| | | }, |
| | | linePosition: '115.10627726,27.29408853,80;115.10627703,27.29456132,80', |
| | | linePosition: '115.10627726,27.29408853,64;115.10627703,27.29456132,64', |
| | | lineTime: 5000, |
| | | |
| | | twoContent: '园区关闭北区雨水排口,拦截污染水体。', |
| | | twoPointPosition: { |
| | | lng: 115.10542509, |
| | | lat: 27.29924475 |
| | | lng: 115.10629605, |
| | | lat: 27.29785816 |
| | | }, |
| | | twotime: 10000, |
| | | |
| | |
| | | |
| | | fiveContent: '排口下游展开应急监测,确保废水没有进入周边水系。', |
| | | fivePointPosition: { |
| | | lng: 115.10921467, |
| | | lat: 27.27166382 |
| | | lng: 115.10542509, |
| | | lat: 27.29924475 |
| | | }, |
| | | fivetime: 25000 |
| | | }, |
| | |
| | | |
| | | oneCentent: '2024年09月16日14时,北片区某公司的危化品运输车辆发生侧翻,大量盐酸流至路面。', |
| | | onePointPosition: { |
| | | lng: 115.10639786, |
| | | lat: 27.28116943 |
| | | lng: 115.10639803, |
| | | lat: 27.27848014 |
| | | }, |
| | | onetime: 8000, |
| | | onetime: 10000, |
| | | |
| | | twoContent: '调度金龙水库清水,稀释污染团。', |
| | | twoPointPosition: { |
| | |
| | | |
| | | let modelPosition = [ |
| | | { |
| | | lng: 115.10601196, |
| | | lat: 27.28378838 |
| | | }, |
| | | { |
| | | lng: 115.10602432, |
| | | lat: 27.28339800 |
| | | }, |
| | | { |
| | | lng: 115.10600450, |
| | | lat: 27.28319338, |
| | | }, |
| | | { |
| | | lng: 115.10605031, |
| | | lat: 27.28294272, |
| | | }, |
| | | { |
| | | lng: 115.10610404, |
| | | lat: 27.28267996 |
| | | }, |
| | | { |
| | | lng: 115.10614202, |
| | | lat: 27.28248175 |
| | | }, |
| | | { |
| | | lng: 115.10620011, |
| | | lat: 27.28221311 |
| | | }, |
| | | { |
| | | lng: 115.10640155, |
| | | lat: 27.28121605 |
| | | }, |
| | | |
| | | { |
| | | lng: 115.10641953, |
| | | lat: 27.28084006 |
| | | }, |
| | | { |
| | | lng: 115.10641886, |
| | | lat: 27.28026147 |
| | | }, |
| | | { |
| | | lng: 115.10642486, |
| | | lat: 27.27994712, |
| | | }, |
| | | { |
| | | lng: 115.10640964, |
| | | lat: 27.27928393, |
| | | }, |
| | | { |
| | | lng: 115.10639803, |
| | | lat: 27.27848014 |
| | | } |
| | | ] |
| | | |
| | | let positions = modelPosition.map(i => [i.lng, i.lat, i.ele || 64].join(',')).join(';') |
| | |
| | | |
| | | const synth = window.speechSynthesis |
| | | |
| | | |
| | | const speak = (msg, continueFun = () => { }) => { |
| | | let u = new SpeechSynthesisUtterance() |
| | | u.lang = 'zh-TW' |
| | | let voices = synth.getVoices() |
| | | u.text = msg |
| | | u.rate = 2 |
| | | let findObj = voices.some(voice => voice.lang == 'zh-CN') |
| | | |
| | | if (!findObj) { |
| | | u.lang = 'zh-TW' |
| | | } |
| | | |
| | | u.onend = () => { |
| | | continueFun() |
| | | } |
| | |
| | | } |
| | | |
| | | const createLinePath = (item, cb = () => { }) => { |
| | | lineTime = setTimeout(() => { |
| | | let polyline = new DC.Polyline(item.linePosition) |
| | | polyline.setStyle({ |
| | | width: 20, |
| | | material: new DC.PolylineImageTrailMaterialProperty({ |
| | | color: DC.Color.RED, |
| | | speed: 20, |
| | | image: VITE_APP_BASE + 'img/mapicon/right.png', |
| | | repeat: { x: 5, y: 1 } |
| | | }), |
| | | clampToGround: false |
| | | }) |
| | | let polyline = new DC.Polyline(item.linePosition) |
| | | polyline.setStyle({ |
| | | width: 20, |
| | | material: new DC.PolylineImageTrailMaterialProperty({ |
| | | color: DC.Color.RED, |
| | | speed: 20, |
| | | image: VITE_APP_BASE + 'img/mapicon/right.png', |
| | | repeat: { x: 5, y: 1 } |
| | | }), |
| | | clampToGround: false |
| | | }) |
| | | |
| | | dynamicLineVectorLayer.addOverlay(polyline) |
| | | dynamicLineVectorLayer.addOverlay(polyline) |
| | | |
| | | window.$viewer.flyToPosition(new DC.Position(item.lineCenter.lng, item.lineCenter.lat, 400, 0, -90, 0), () => { |
| | | window.$viewer.flyToPosition(new DC.Position(item.lineCenter.lng, item.lineCenter.lat, 400, 0, -90, 0), () => { |
| | | lineTime = setTimeout(() => { |
| | | cb() |
| | | }, 3) |
| | | }, item.lineTime) |
| | | }, item.lineTime) |
| | | }, 3) |
| | | } |
| | | |
| | | const schemeStart = (item) => { |