| | |
| | | v-loading="videoLoading" |
| | | element-loading-background="rgba(0, 0, 0, 0.8)" |
| | | style="position: unset !important" |
| | | ></div> |
| | | <canvas |
| | | ></div> |
| | | <canvas |
| | | ref="playCanvas" |
| | | id="paly-canvas" |
| | | width="960" |
| | |
| | | isEmptyUrl: false, |
| | | videoLoading: false, |
| | | loadUrl:'', |
| | | isFullScreen:false |
| | | } |
| | | }, |
| | | watch: { |
| | |
| | | }, |
| | | |
| | | fullScreen() { |
| | | this.player.fullscreen() |
| | | if(!this.isFullScreen){ |
| | | this.player.fullscreen() |
| | | } |
| | | else{ |
| | | this.player.exitfullscreen() |
| | | } |
| | | this.isFullScreen = !this.isFullScreen |
| | | }, |
| | | |
| | | async downLoad() { |
| | |
| | | title: '消息', |
| | | message: '资源下载中,请稍后...' |
| | | }); |
| | | let url = 'http:/'+this.loadUrl.substring(10) |
| | | let url = 'http://'+window.location.host+this.loadUrl |
| | | |
| | | // let url = "http://localhost:8080/httpImage/192.168.20.189:6700/283,2f49bf283ad7?collection=2021-09-28-DSVAD010120190703-video" |
| | | console.log(url); |
| | | let name = url.substring(url.lastIndexOf("/") + 1) |
| | | let responsePromise = await fetch(url) |
| | | let blob = await responsePromise.blob() |
| | |
| | | if (this.webglPlayer) this.webglPlayer.fullscreen() |
| | | } |
| | | |
| | | Player.prototype.exitfullscreen = function() { |
| | | if (this.webglPlayer) this.webglPlayer.exitfullscreen() |
| | | } |
| | | |
| | | |
| | | Player.prototype.startTrackTimer = function() { |
| | | var This = this |
| | | this.trackTimer = setInterval(function() { |
| | |
| | | } |
| | | |
| | | WebGLPlayer.prototype.fullscreen = function() { |
| | | var canvas = this.canvas |
| | | let canvas = this.canvas.parentNode.parentNode.parentNode |
| | | if (canvas.RequestFullScreen) { |
| | | canvas.RequestFullScreen() |
| | | } else if (canvas.webkitRequestFullScreen) { |