added message pack dependency

This commit is contained in:
ori agranat
2019-10-10 22:40:51 +03:00
parent 8748dd2503
commit 5421bb09f7
7 changed files with 74 additions and 49 deletions

View File

@@ -89,6 +89,11 @@
<artifactId>gson</artifactId> <artifactId>gson</artifactId>
<version>2.8.5</version> <version>2.8.5</version>
</dependency> </dependency>
<dependency>
<groupId>org.msgpack</groupId>
<artifactId>msgpack</artifactId>
<version>0.6.12</version>
</dependency>
<dependency> <dependency>
<groupId>org.springframework</groupId> <groupId>org.springframework</groupId>
<artifactId>spring-beans</artifactId> <artifactId>spring-beans</artifactId>

View File

@@ -2160,6 +2160,15 @@
"integrity": "sha512-Un7MIEDdUC5gNpcGDV97op1Ywk748MpHcFTHoYs6qnj1Z3j7I53VG3nwZhKzoBZmbdRNnb6WRdFlwl7tSDuZGw==", "integrity": "sha512-Un7MIEDdUC5gNpcGDV97op1Ywk748MpHcFTHoYs6qnj1Z3j7I53VG3nwZhKzoBZmbdRNnb6WRdFlwl7tSDuZGw==",
"dev": true "dev": true
}, },
"bl": {
"version": "2.2.0",
"resolved": "https://registry.npmjs.org/bl/-/bl-2.2.0.tgz",
"integrity": "sha512-wbgvOpqopSr7uq6fJrLH8EsvYMJf9gzfo2jCsL2eTy75qXPukA4pCgHamOQkZtY5vmfVtjB+P3LNlMHW5CEZXA==",
"requires": {
"readable-stream": "^2.3.5",
"safe-buffer": "^5.1.1"
}
},
"bluebird": { "bluebird": {
"version": "3.5.5", "version": "3.5.5",
"resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.5.5.tgz", "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.5.5.tgz",
@@ -3156,8 +3165,7 @@
"core-util-is": { "core-util-is": {
"version": "1.0.2", "version": "1.0.2",
"resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz",
"integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=", "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac="
"dev": true
}, },
"cosmiconfig": { "cosmiconfig": {
"version": "5.2.1", "version": "5.2.1",
@@ -6292,8 +6300,7 @@
"inherits": { "inherits": {
"version": "2.0.4", "version": "2.0.4",
"resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz",
"integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ=="
"dev": true
}, },
"inquirer": { "inquirer": {
"version": "3.3.0", "version": "3.3.0",
@@ -6683,8 +6690,7 @@
"isarray": { "isarray": {
"version": "1.0.0", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
"integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE="
"dev": true
}, },
"isexe": { "isexe": {
"version": "2.0.0", "version": "2.0.0",
@@ -7375,6 +7381,17 @@
"integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==",
"dev": true "dev": true
}, },
"msgpack5": {
"version": "4.2.1",
"resolved": "https://registry.npmjs.org/msgpack5/-/msgpack5-4.2.1.tgz",
"integrity": "sha512-Xo7nE9ZfBVonQi1rSopNAqPdts/QHyuSEUwIEzAkB+V2FtmkkLUbP6MyVqVVQxsZYI65FpvW3Bb8Z9ZWEjbgHQ==",
"requires": {
"bl": "^2.0.1",
"inherits": "^2.0.3",
"readable-stream": "^2.3.6",
"safe-buffer": "^5.1.2"
}
},
"multicast-dns": { "multicast-dns": {
"version": "6.2.3", "version": "6.2.3",
"resolved": "https://registry.npmjs.org/multicast-dns/-/multicast-dns-6.2.3.tgz", "resolved": "https://registry.npmjs.org/multicast-dns/-/multicast-dns-6.2.3.tgz",
@@ -8738,8 +8755,7 @@
"process-nextick-args": { "process-nextick-args": {
"version": "2.0.1", "version": "2.0.1",
"resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz",
"integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag=="
"dev": true
}, },
"progress": { "progress": {
"version": "2.0.3", "version": "2.0.3",
@@ -8942,7 +8958,6 @@
"version": "2.3.6", "version": "2.3.6",
"resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz",
"integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==",
"dev": true,
"requires": { "requires": {
"core-util-is": "~1.0.0", "core-util-is": "~1.0.0",
"inherits": "~2.0.3", "inherits": "~2.0.3",
@@ -9360,8 +9375,7 @@
"safe-buffer": { "safe-buffer": {
"version": "5.1.2", "version": "5.1.2",
"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz",
"integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g=="
"dev": true
}, },
"safe-regex": { "safe-regex": {
"version": "1.1.0", "version": "1.1.0",
@@ -10192,7 +10206,6 @@
"version": "1.1.1", "version": "1.1.1",
"resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",
"integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
"dev": true,
"requires": { "requires": {
"safe-buffer": "~5.1.0" "safe-buffer": "~5.1.0"
} }
@@ -10870,8 +10883,7 @@
"util-deprecate": { "util-deprecate": {
"version": "1.0.2", "version": "1.0.2",
"resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz",
"integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8="
"dev": true
}, },
"util.promisify": { "util.promisify": {
"version": "1.0.0", "version": "1.0.0",
@@ -13481,8 +13493,7 @@
}, },
"code-point-at": { "code-point-at": {
"version": "1.1.0", "version": "1.1.0",
"bundled": true, "bundled": true
"optional": true
}, },
"concat-map": { "concat-map": {
"version": "0.0.1", "version": "0.0.1",
@@ -13491,8 +13502,7 @@
}, },
"console-control-strings": { "console-control-strings": {
"version": "1.1.0", "version": "1.1.0",
"bundled": true, "bundled": true
"optional": true
}, },
"core-util-is": { "core-util-is": {
"version": "1.0.2", "version": "1.0.2",
@@ -13595,8 +13605,7 @@
}, },
"inherits": { "inherits": {
"version": "2.0.3", "version": "2.0.3",
"bundled": true, "bundled": true
"optional": true
}, },
"ini": { "ini": {
"version": "1.3.5", "version": "1.3.5",
@@ -13606,7 +13615,6 @@
"is-fullwidth-code-point": { "is-fullwidth-code-point": {
"version": "1.0.0", "version": "1.0.0",
"bundled": true, "bundled": true,
"optional": true,
"requires": { "requires": {
"number-is-nan": "^1.0.0" "number-is-nan": "^1.0.0"
} }
@@ -13632,7 +13640,6 @@
"minipass": { "minipass": {
"version": "2.2.4", "version": "2.2.4",
"bundled": true, "bundled": true,
"optional": true,
"requires": { "requires": {
"safe-buffer": "^5.1.1", "safe-buffer": "^5.1.1",
"yallist": "^3.0.0" "yallist": "^3.0.0"
@@ -13649,7 +13656,6 @@
"mkdirp": { "mkdirp": {
"version": "0.5.1", "version": "0.5.1",
"bundled": true, "bundled": true,
"optional": true,
"requires": { "requires": {
"minimist": "0.0.8" "minimist": "0.0.8"
} }
@@ -13722,8 +13728,7 @@
}, },
"number-is-nan": { "number-is-nan": {
"version": "1.0.1", "version": "1.0.1",
"bundled": true, "bundled": true
"optional": true
}, },
"object-assign": { "object-assign": {
"version": "4.1.1", "version": "4.1.1",
@@ -13733,7 +13738,6 @@
"once": { "once": {
"version": "1.4.0", "version": "1.4.0",
"bundled": true, "bundled": true,
"optional": true,
"requires": { "requires": {
"wrappy": "1" "wrappy": "1"
} }
@@ -13839,7 +13843,6 @@
"string-width": { "string-width": {
"version": "1.0.2", "version": "1.0.2",
"bundled": true, "bundled": true,
"optional": true,
"requires": { "requires": {
"code-point-at": "^1.0.0", "code-point-at": "^1.0.0",
"is-fullwidth-code-point": "^1.0.0", "is-fullwidth-code-point": "^1.0.0",

View File

@@ -10,6 +10,7 @@
"dependencies": { "dependencies": {
"core-js": "^2.6.5", "core-js": "^2.6.5",
"material-design-icons-iconfont": "^5.0.1", "material-design-icons-iconfont": "^5.0.1",
"msgpack5": "^4.2.1",
"vue": "^2.6.10", "vue": "^2.6.10",
"vue-native-websocket": "^2.0.13", "vue-native-websocket": "^2.0.13",
"vue-router": "^3.0.3", "vue-router": "^3.0.3",

View File

@@ -2,7 +2,7 @@
<div> <div>
<v-tooltip :right="right" :bottom="!right" nudge-right="10"> <v-tooltip :right="right" :bottom="!right" nudge-right="10">
<template v-slot:activator="{ on }"> <template v-slot:activator="{ on }">
<v-icon @click="handleClick" v-on="on" :color="color">{{text}}</v-icon> <v-icon :class="hoverClass" @click="handleClick" v-on="on" :color="color">{{text}}</v-icon>
</template> </template>
<span>{{tooltip}}</span> <span>{{tooltip}}</span>
</v-tooltip> </v-tooltip>
@@ -12,7 +12,7 @@
<script> <script>
export default { export default {
name: 'Icon', name: 'Icon',
props:['color','tooltip','text','right'], props:['color','tooltip','text','right','hover'],
data() { data() {
return { return {
@@ -22,10 +22,20 @@
handleClick(){ handleClick(){
this.$emit('click'); this.$emit('click');
} }
} },
computed:{
hoverClass(){
if(this.hover !== undefined){
return "hover";
}
}
},
} }
</script> </script>
<style lang="" scoped> <style scoped>
.hover:hover{
color: white !important;
}
</style> </style>

View File

@@ -4,9 +4,12 @@ import router from './router'
import store from './store' import store from './store'
import vuetify from './plugins/vuetify'; import vuetify from './plugins/vuetify';
import VueNativeSock from 'vue-native-websocket'; import VueNativeSock from 'vue-native-websocket';
import msgPack from 'msgpack5';
Vue.config.productionTip = false; Vue.config.productionTip = false;
// Vue.use(VueNativeSock,'ws://' + location.host + '/websocket',{format: 'json'}); // Vue.use(VueNativeSock,'ws://' + location.host + '/websocket',{format: 'json'});
Vue.use(VueNativeSock,'ws://'+location.hostname+':8888/websocket',{format:'JSON'}); Vue.use(VueNativeSock,'ws://'+location.hostname+':8888/websocket',{format:'JSON'});
Vue.prototype.$msgPack = msgPack;
new Vue({ new Vue({
router, router,
store, store,

View File

@@ -8,7 +8,7 @@
</div> </div>
</v-col> </v-col>
<v-col :cols="1"> <v-col :cols="1">
<CVicon color="white" text="edit" tooltip="Edit camera name"></CVicon> <CVicon color="#c5c5c5" hover text="edit" @click="test" tooltip="Edit camera name"></CVicon>
</v-col> </v-col>
<v-col :cols="3" class="colsClass"> <v-col :cols="3" class="colsClass">
<CVselect name="Pipeline" :list="pipelineList" v-model="currentPipelineIndex"></CVselect> <CVselect name="Pipeline" :list="pipelineList" v-model="currentPipelineIndex"></CVselect>
@@ -21,12 +21,12 @@
<v-list dense> <v-list dense>
<v-list-item @click="test"> <v-list-item @click="test">
<v-list-item-title> <v-list-item-title>
<CVicon color="white" :right="true" text="edit" tooltip="Edit pipeline name"></CVicon> <CVicon color="#c5c5c5" :right="true" text="edit" tooltip="Edit pipeline name"></CVicon>
</v-list-item-title> </v-list-item-title>
</v-list-item> </v-list-item>
<v-list-item @click="test"> <v-list-item @click="test">
<v-list-item-title> <v-list-item-title>
<CVicon color="white" :right="true" text="add" tooltip="Add new pipeline"></CVicon> <CVicon color="#c5c5c5" :right="true" text="add" tooltip="Add new pipeline"></CVicon>
</v-list-item-title> </v-list-item-title>
</v-list-item> </v-list-item>
<v-list-item @click="test"> <v-list-item @click="test">
@@ -36,7 +36,7 @@
</v-list-item> </v-list-item>
<v-list-item @click="test"> <v-list-item @click="test">
<v-list-item-title> <v-list-item-title>
<CVicon color="white" :right="true" text="mdi-content-copy" tooltip="Duplicate pipeline"></CVicon> <CVicon color="#c5c5c5" :right="true" text="mdi-content-copy" tooltip="Duplicate pipeline"></CVicon>
</v-list-item-title> </v-list-item-title>
</v-list-item> </v-list-item>
</v-list> </v-list>
@@ -63,7 +63,8 @@
<v-tab>Threshold</v-tab> <v-tab>Threshold</v-tab>
</v-tabs> </v-tabs>
<div class="videoClass"> <div class="videoClass">
<img :src="steamAdress"> <img v-if="cameraList.length > 0" :src="steamAdress">
<span v-else>No Cameras Are connected</span>
</div> </div>
<h5 id="Point">{{point}}</h5> <h5 id="Point">{{point}}</h5>
</div> </div>
@@ -91,7 +92,8 @@ import CVicon from '../components/cv-icon'
}, },
methods:{ methods:{
test(){ test(){
let o = this.$msgPack().encode("dasd");
console.log(o);
} }
}, },
data() { data() {
@@ -100,16 +102,18 @@ import CVicon from '../components/cv-icon'
} }
}, },
computed:{ computed:{
selectedComponent(){ selectedComponent:{
switch(this.selectedTab){ get(){
case 0: switch(this.selectedTab){
return "InputTab"; case 0:
case 1: return "InputTab";
return "ThresholdTab"; case 1:
case 2: return "ThresholdTab";
return "ContoursTab"; case 2:
case 3: return "ContoursTab";
return "OutputTab"; case 3:
return "OutputTab";
}
} }
}, },
point:{ point:{

View File

@@ -16,7 +16,6 @@ import CVswitch from '../../components/cv-switch'
props:['value'], props:['value'],
components:{ components:{
CVslider, CVslider,
rangeSlider,
CVselect, CVselect,
CVswitch CVswitch
}, },