This commit is contained in:
chengdandan 2023-01-04 16:39:04 +08:00
parent a9fd6f0f6d
commit de50ca3d66
16 changed files with 64 additions and 79 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1 +1 @@
{"remainingRequest":"D:\\视频边缘1215\\TransFlow\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\视频边缘1215\\TransFlow\\src\\views\\index.vue","dependencies":[{"path":"D:\\视频边缘1215\\TransFlow\\src\\views\\index.vue","mtime":1672741609576},{"path":"D:\\视频边缘1215\\TransFlow\\node_modules\\cache-loader\\dist\\cjs.js","mtime":1671074740928},{"path":"D:\\视频边缘1215\\TransFlow\\node_modules\\vue-loader\\lib\\index.js","mtime":1671074747916}],"contextDependencies":[],"result":["import { render, staticRenderFns } from \"./index.vue?vue&type=template&id=a83bd3b0&scoped=true&\"\nimport script from \"./index.vue?vue&type=script&lang=js&\"\nexport * from \"./index.vue?vue&type=script&lang=js&\"\nimport style0 from \"./index.vue?vue&type=style&index=0&id=a83bd3b0&scoped=true&lang=css&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"a83bd3b0\",\n null\n \n)\n\n/* hot reload */\nif (module.hot) {\n var api = require(\"D:\\\\视频边缘1215\\\\TransFlow\\\\node_modules\\\\vue-hot-reload-api\\\\dist\\\\index.js\")\n api.install(require('vue'))\n if (api.compatible) {\n module.hot.accept()\n if (!api.isRecorded('a83bd3b0')) {\n api.createRecord('a83bd3b0', component.options)\n } else {\n api.reload('a83bd3b0', component.options)\n }\n module.hot.accept(\"./index.vue?vue&type=template&id=a83bd3b0&scoped=true&\", function () {\n api.rerender('a83bd3b0', {\n render: render,\n staticRenderFns: staticRenderFns\n })\n })\n }\n}\ncomponent.options.__file = \"src/views/index.vue\"\nexport default component.exports"]}
{"remainingRequest":"D:\\视频边缘1215\\TransFlow\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\视频边缘1215\\TransFlow\\src\\views\\index.vue","dependencies":[{"path":"D:\\视频边缘1215\\TransFlow\\src\\views\\index.vue","mtime":1672799272806},{"path":"D:\\视频边缘1215\\TransFlow\\node_modules\\cache-loader\\dist\\cjs.js","mtime":1671074740928},{"path":"D:\\视频边缘1215\\TransFlow\\node_modules\\vue-loader\\lib\\index.js","mtime":1671074747916}],"contextDependencies":[],"result":["import { render, staticRenderFns } from \"./index.vue?vue&type=template&id=a83bd3b0&scoped=true&\"\nimport script from \"./index.vue?vue&type=script&lang=js&\"\nexport * from \"./index.vue?vue&type=script&lang=js&\"\nimport style0 from \"./index.vue?vue&type=style&index=0&id=a83bd3b0&scoped=true&lang=css&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"a83bd3b0\",\n null\n \n)\n\n/* hot reload */\nif (module.hot) {\n var api = require(\"D:\\\\视频边缘1215\\\\TransFlow\\\\node_modules\\\\vue-hot-reload-api\\\\dist\\\\index.js\")\n api.install(require('vue'))\n if (api.compatible) {\n module.hot.accept()\n if (!api.isRecorded('a83bd3b0')) {\n api.createRecord('a83bd3b0', component.options)\n } else {\n api.reload('a83bd3b0', component.options)\n }\n module.hot.accept(\"./index.vue?vue&type=template&id=a83bd3b0&scoped=true&\", function () {\n api.rerender('a83bd3b0', {\n render: render,\n staticRenderFns: staticRenderFns\n })\n })\n }\n}\ncomponent.options.__file = \"src/views/index.vue\"\nexport default component.exports"]}

View File

@ -1 +1 @@
{"remainingRequest":"D:\\视频边缘1215\\TransFlow\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\视频边缘1215\\TransFlow\\src\\views\\bounced\\analysisConfiguration.vue","dependencies":[{"path":"D:\\视频边缘1215\\TransFlow\\src\\views\\bounced\\analysisConfiguration.vue","mtime":1672741926736},{"path":"D:\\视频边缘1215\\TransFlow\\node_modules\\cache-loader\\dist\\cjs.js","mtime":1671074740928},{"path":"D:\\视频边缘1215\\TransFlow\\node_modules\\vue-loader\\lib\\index.js","mtime":1671074747916}],"contextDependencies":[],"result":["import { render, staticRenderFns } from \"./analysisConfiguration.vue?vue&type=template&id=fd3d0d46&scoped=true&\"\nimport script from \"./analysisConfiguration.vue?vue&type=script&lang=js&\"\nexport * from \"./analysisConfiguration.vue?vue&type=script&lang=js&\"\nimport style0 from \"./analysisConfiguration.vue?vue&type=style&index=0&id=fd3d0d46&lang=scss&scoped=true&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"fd3d0d46\",\n null\n \n)\n\n/* hot reload */\nif (module.hot) {\n var api = require(\"D:\\\\视频边缘1215\\\\TransFlow\\\\node_modules\\\\vue-hot-reload-api\\\\dist\\\\index.js\")\n api.install(require('vue'))\n if (api.compatible) {\n module.hot.accept()\n if (!api.isRecorded('fd3d0d46')) {\n api.createRecord('fd3d0d46', component.options)\n } else {\n api.reload('fd3d0d46', component.options)\n }\n module.hot.accept(\"./analysisConfiguration.vue?vue&type=template&id=fd3d0d46&scoped=true&\", function () {\n api.rerender('fd3d0d46', {\n render: render,\n staticRenderFns: staticRenderFns\n })\n })\n }\n}\ncomponent.options.__file = \"src/views/bounced/analysisConfiguration.vue\"\nexport default component.exports"]}
{"remainingRequest":"D:\\视频边缘1215\\TransFlow\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\视频边缘1215\\TransFlow\\src\\views\\bounced\\analysisConfiguration.vue","dependencies":[{"path":"D:\\视频边缘1215\\TransFlow\\src\\views\\bounced\\analysisConfiguration.vue","mtime":1672809677780},{"path":"D:\\视频边缘1215\\TransFlow\\node_modules\\cache-loader\\dist\\cjs.js","mtime":1671074740928},{"path":"D:\\视频边缘1215\\TransFlow\\node_modules\\vue-loader\\lib\\index.js","mtime":1671074747916}],"contextDependencies":[],"result":["import { render, staticRenderFns } from \"./analysisConfiguration.vue?vue&type=template&id=fd3d0d46&scoped=true&\"\nimport script from \"./analysisConfiguration.vue?vue&type=script&lang=js&\"\nexport * from \"./analysisConfiguration.vue?vue&type=script&lang=js&\"\nimport style0 from \"./analysisConfiguration.vue?vue&type=style&index=0&id=fd3d0d46&lang=scss&scoped=true&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"fd3d0d46\",\n null\n \n)\n\n/* hot reload */\nif (module.hot) {\n var api = require(\"D:\\\\视频边缘1215\\\\TransFlow\\\\node_modules\\\\vue-hot-reload-api\\\\dist\\\\index.js\")\n api.install(require('vue'))\n if (api.compatible) {\n module.hot.accept()\n if (!api.isRecorded('fd3d0d46')) {\n api.createRecord('fd3d0d46', component.options)\n } else {\n api.reload('fd3d0d46', component.options)\n }\n module.hot.accept(\"./analysisConfiguration.vue?vue&type=template&id=fd3d0d46&scoped=true&\", function () {\n api.rerender('fd3d0d46', {\n render: render,\n staticRenderFns: staticRenderFns\n })\n })\n }\n}\ncomponent.options.__file = \"src/views/bounced/analysisConfiguration.vue\"\nexport default component.exports"]}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -118,37 +118,19 @@
};
//获取图像
function getDestination(string){
// console.log("string",string)
// debugger
if(unity!=null){
unity.SendMessage('AAA', 'SendImage', string);
}
}
//获取数据
function getData(string){
// console.log("string",string)
// debugger
if(unity!=null){
unity.SendMessage('AAA', 'SendStream', string);
}
// if(message.destinationName=='img0')
// {
// if(aaaaa!=null)
// {
// aaaaa.SendMessage('AAA', 'SendImage', message.payloadString);
// }
// }
// else if(message.destinationName=='stream0')
// {
// //原始数据
// if(aaaaa!=null)
// {
// aaaaa.SendMessage('AAA', 'SendStream', message.payloadString);
// }
// }
}
//获取图形数据
function getfigureData(string){
console.log("图形数据",string)
}
document.body.appendChild(script);

View File

@ -34,5 +34,6 @@ export const getDeleteShipjk = (params) => {
params
})
};
//视频分析预览

View File

@ -54,7 +54,7 @@
</el-radio-group>
</el-form-item>
<div style="width:100%;height:300px" >
<iframe id="mapModule" src="./VideoWeb/index.html" frameborder="0" style="width: 100%; height:100%;" ></iframe>
<iframe id="mapModuleTop" @load="load" src="./VideoWeb/index.html" frameborder="0" style="width: 100%; height:100%;" ></iframe>
<!-- <iframe src="./VideoWeb/index.html" style="height: 100%; width: 100%;border: none"
ref="iframe"></iframe> -->
</div>
@ -478,9 +478,40 @@ export default {
created() {
// this.getDataByMqtt()
// this.testMqtt()
// var iframe = document.getElementById("mapModule");
// iframe.onload = function () {
// setTimeout(() => {
// this.testMqtt()
// }, 5000);
// };
// iframe.onload = () => {
// setTimeout(() => {
// this.load()
// }, 5000);//
// }
},
methods: {
load(){
console.log("1111")
var iframe = document.getElementById("mapModuleTop");
console.log("iframe",iframe)
// if (iframe.attachEvent) {
// setTimeout(() => {
// this.testMqtt()
// }, 5000);
// }else{
// console.log("3333")
// }
iframe.onload = () => {
// setTimeout(() => {
this.testMqtt()
// }, 5000);
}
},
testMqtt() {
console.log("222")
this.getDataByMqtt()
},

View File

@ -330,7 +330,7 @@ export default {
methods: {
// mqtt
testMqtt() {
// this.getDataByMqtt()
this.getDataByMqtt()
//
// for (let key in this.carId) {
// this.getDataByMqtt(
@ -437,6 +437,9 @@ export default {
// console.log("[MQTT-TEST] ID: ", connect);
//
this.mqttClient.subscribe('img0', { qos: 0 });
// this.client.connect('aaa', '111')
this.mqttClient.publish('aaa', '111');
// this.mqttClient.subscribe('msg_stream', { msg_flag: 0 });
this.mqttClient.subscribe('img1', { qos: 0 });
this.mqttClient.subscribe('img2', { qos: 0 });
this.mqttClient.subscribe('img3', { qos: 0 });
@ -450,34 +453,10 @@ export default {
this.mqttClient.subscribe('stream5', { qos: 0 });
});
//
this.mqttClient.on("message", (topic, message, packet) => {
// debugger
// return
// console.log("[MQTT-TEST] ID: ", message);
// console.log(
// `[MQTT-TEST] "${topic}" : ${message.toString()}`,
// new Date(),
// new Date().getMilliseconds()
// );
//
// let dataReceived = JSON.parse(message.toString());
// console.log("[MQTT-TEST] ID: ",dataReceived);
// try{
// const utf8decoder = new TextDecoder()
// const u8arr = new Uint8Array(message)
// const temp = utf8decoder.decode(u8arr) //
// const msg = JSON.parse(temp) //JSON
// console.log("msg",msg) //msgJSON
// this.imgUrl='data:image/png;base64,' + msg.pic;
// console.log("imageUrl",imageUrl)
// }catch{
// let imageType = 'arraybuffer';
// const blob = new Blob([message], { type: imageType })
// const imageUrl = (window.URL || window.webkitURL).createObjectURL(blob)
// console.log("imageUrl",imageUrl)
// }
if (topic.indexOf("img0") != -1) {
try {
const utf8decoder = new TextDecoder()
@ -486,9 +465,9 @@ export default {
const msg = JSON.parse(temp) //JSON
// debugger
// console.log("msg", msg) //msgJSON
console.log("1111",document.getElementById("mapModule"))
// console.log("1111",document.getElementById("mapModule"))
document.getElementById("mapModule").contentWindow.getDestination(JSON.stringify(msg))
this.imgUrl = 'data:image/png;base64,' + msg.pic;
// this.imgUrl = 'data:image/png;base64,' + msg.pic;
// console.log("imageUrl", imageUrl)
} catch {
@ -573,18 +552,10 @@ export default {
console.log("imageUrl", imageUrl)
}
} else if (topic.indexOf("stream0") != -1) {
// console.log(
// `[MQTT-TEST] "${topic}" : ${message.toString()}`,
// new Date(),
// new Date().getMilliseconds()
// );
const utf8decoder = new TextDecoder()
const u8arr = new Uint8Array(message)
const temp = utf8decoder.decode(u8arr) //
const msg = JSON.parse(temp)
// console.log("msg",msg)
// debugger
document.getElementById("mapModule").contentWindow.getData(JSON.stringify(msg))
} else if (topic.indexOf("stream1") != -1) {
console.log(