| | |
| | | item: { |
| | | type: Object, |
| | | default: {} |
| | | }, |
| | | autoPlay: { |
| | | type: Boolean, |
| | | default: false |
| | | } |
| | | }); |
| | | |
| | |
| | | showPause.value = false; |
| | | } |
| | | |
| | | const init = () => { |
| | | videojsb.value = new window.Jessibuca( |
| | | Object.assign({ |
| | | container: videoRef.value, |
| | | isResize: true, |
| | | // 实例化dom节点 |
| | | const initDom = async () => { |
| | | videojsb.value = new window.Jessibuca( |
| | | Object.assign({ |
| | | container: videoRef.value, |
| | | isResize: true, |
| | | isFullResize: true, |
| | | text: '', |
| | | text: '', |
| | | videoBuffer: 2, |
| | | loadingText: '加载中...', |
| | | useMSE: true, |
| | | loadingText: '加载中...', |
| | | useMSE: true, |
| | | useWCS: true, |
| | | autoWasm: true, |
| | | // debug: true, |
| | | // debug: true, |
| | | supportDblclickFullscreen: false, |
| | | operateBtns: { |
| | | fullscreen: true, |
| | | play: false, |
| | | audio: true, |
| | | recorder: false, |
| | | }, |
| | | operateBtns: { |
| | | fullscreen: true, |
| | | play: false, |
| | | audio: true, |
| | | recorder: false, |
| | | }, |
| | | controlAutoHide: true, |
| | | forceNoOffscreen: true, |
| | | isNotMute: false, |
| | | forceNoOffscreen: true, |
| | | isNotMute: false, |
| | | heartTimeoutReplay:false, |
| | | }) |
| | | ); |
| | | }) |
| | | ); |
| | | } |
| | | |
| | | // 初始化 |
| | | const init = async () => { |
| | | await initDom() |
| | | // 自动播放 |
| | | if(props.autoPlay && props.item.deviceId && props.item.channelId) { |
| | | handlePlayer() |
| | | } |
| | | }; |
| | | |
| | | onMounted(() => { |