flx:修改海康默认码流
This commit is contained in:
parent
03e1dd6383
commit
0b9638814b
@ -163,6 +163,7 @@ export const getAreaDamgerList = data => post('/xmgl/panoramaPlanStatistics/sele
|
|||||||
|
|
||||||
// 查询项目信息
|
// 查询项目信息
|
||||||
export const getCompanyInfo = data => post('/xmgl/company/queryById', data)
|
export const getCompanyInfo = data => post('/xmgl/company/queryById', data)
|
||||||
|
export const getQueryBySnCompanyInfo = data => post('/xmgl/company/queryBySn', data)
|
||||||
|
|
||||||
// 查询项目列表
|
// 查询项目列表
|
||||||
export const getProjectList = data => post('/xmgl/project/selectProjectListByCompany', data)
|
export const getProjectList = data => post('/xmgl/project/selectProjectListByCompany', data)
|
||||||
|
|||||||
@ -79,15 +79,15 @@ export function unInitObjPlugin() {
|
|||||||
export function OpenVideo(cameraIndexCode, streamMode, winIndex) {
|
export function OpenVideo(cameraIndexCode, streamMode, winIndex) {
|
||||||
var transMode = +'1'; //传输协议:1、TCP 0、UDP
|
var transMode = +'1'; //传输协议:1、TCP 0、UDP
|
||||||
var gpuMode = +'0'; //是否启用GPU硬解:1、启用 0、不启用
|
var gpuMode = +'0'; //是否启用GPU硬解:1、启用 0、不启用
|
||||||
|
console.log(8855544, streamMode)
|
||||||
oWebControl.JS_RequestInterface({
|
oWebControl.JS_RequestInterface({
|
||||||
funcName: "startPreview",
|
funcName: "startPreview",
|
||||||
argument: JSON.stringify({
|
argument: JSON.stringify({
|
||||||
cameraIndexCode: cameraIndexCode,
|
cameraIndexCode: cameraIndexCode,
|
||||||
streamMode: streamMode,
|
streamMode: streamMode == 2 ? 0 : streamMode, // 码流类型 0 主码流 1 子码流 (2 主码流 1 子码流)
|
||||||
transMode: transMode,
|
transMode: transMode,
|
||||||
gpuMode: gpuMode,
|
gpuMode: gpuMode,
|
||||||
wndId: -1
|
wndId: -1,
|
||||||
})
|
})
|
||||||
}).then(function (oData) {
|
}).then(function (oData) {
|
||||||
console.log(oData.responseMsg.code === 336)
|
console.log(oData.responseMsg.code === 336)
|
||||||
@ -266,7 +266,7 @@ export function InitObjPlugin(appkey, secret, ip, port, type, videoData, layout)
|
|||||||
}
|
}
|
||||||
//初始化
|
//初始化
|
||||||
function init(videoData) {
|
function init(videoData) {
|
||||||
console.log(videoData)
|
console.log(222222222222, videoData)
|
||||||
getPubKey(function () {
|
getPubKey(function () {
|
||||||
////////////////////////////////// 请自行修改以下变量值 ////////////////////////////////////
|
////////////////////////////////// 请自行修改以下变量值 ////////////////////////////////////
|
||||||
// var appkey = "20880397"; //综合安防管理平台提供的appkey,必填
|
// var appkey = "20880397"; //综合安防管理平台提供的appkey,必填
|
||||||
@ -320,7 +320,7 @@ function init(videoData) {
|
|||||||
for (let i = 0; i < videoData.length; i++) {
|
for (let i = 0; i < videoData.length; i++) {
|
||||||
if (i < 24 && videoData.length >= i) {
|
if (i < 24 && videoData.length >= i) {
|
||||||
// setTimeout(()=>{
|
// setTimeout(()=>{
|
||||||
OpenVideo(videoData[i].serialNumber, 0, i + 1)
|
OpenVideo(videoData[i].serialNumber, videoData[i].defaultStreamType, i + 1)
|
||||||
// },1000)
|
// },1000)
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -335,7 +335,7 @@ export function isLoadPlugin(devList, layout) {
|
|||||||
if (oWebControl) {
|
if (oWebControl) {
|
||||||
devList.forEach(element => {
|
devList.forEach(element => {
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
OpenVideo(element.serialNumber, 1)
|
OpenVideo(element.serialNumber,element.defaultStreamType)
|
||||||
}, 500)
|
}, 500)
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|||||||
@ -28,7 +28,7 @@
|
|||||||
import CompanyInfoDialog from './companyInfoDialog.vue'
|
import CompanyInfoDialog from './companyInfoDialog.vue'
|
||||||
import Card from './card.vue'
|
import Card from './card.vue'
|
||||||
import { ref, onMounted } from 'vue'
|
import { ref, onMounted } from 'vue'
|
||||||
import { getCompanyInfo } from '@/assets/js/api/companyBigScreen'
|
import { getQueryBySnCompanyInfo } from '@/assets/js/api/companyBigScreen'
|
||||||
import { queryCustomConfig } from '@/assets/js/api/common'
|
import { queryCustomConfig } from '@/assets/js/api/common'
|
||||||
import store from '@/store'
|
import store from '@/store'
|
||||||
const infoData = ref({})
|
const infoData = ref({})
|
||||||
@ -55,7 +55,9 @@ const getCustomConfig = async () => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
const getCompanyInfoData = async () => {
|
const getCompanyInfoData = async () => {
|
||||||
const res = await getCompanyInfo({ sn: store.state.userInfo.sn })
|
const res = await getQueryBySnCompanyInfo({
|
||||||
|
sn: store.state.userInfo.sn,
|
||||||
|
})
|
||||||
console.log(res)
|
console.log(res)
|
||||||
infoData.value = {
|
infoData.value = {
|
||||||
imageUrl: res.result.coverImage,
|
imageUrl: res.result.coverImage,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user