开源版本,视频直播功能,删除录像相关代码

This commit is contained in:
gx_ma
2024-07-12 14:45:34 +08:00
parent 67534a1f16
commit d6cda401fd
7 changed files with 4 additions and 684 deletions

View File

@@ -104,6 +104,7 @@ export default {
}, 1000);
},
startPushStream() {
console.log('开始通道: [' + this.channelId + ']');
if (!this.channelId) {
console.log('开始通道: [' + this.channelId + ']');
return;
@@ -135,17 +136,17 @@ export default {
if (!this.$refs.player.isInit) {
this.$refs.player.init();
}
this.$refs.player.registercallback('loadingTimeout', this.TimeoutCallback);
this.$refs.player.registercallback('delayTimeout', this.TimeoutCallback);
// this.$refs.player.registercallback('loadingTimeout', this.TimeoutCallback);
// this.$refs.player.registercallback('delayTimeout', this.TimeoutCallback);
// this.$refs.player.play("https://sample-videos.com/video321/flv/480/big_buck_bunny_480p_1mb.flv");
if (this.playrecord) {
} else {
startPlay(this.deviceId, this.channelId).then((response) => {
console.log('开始推流: [' + this.streamId + ']');
const res = response.data;
this.streamId = res.streamId;
this.playurl = res.playurl;
console.log('开始推流: [' + this.streamId + ']');
this.$refs.player.play(res.playurl);
this.playing = true;
this.playrecording = false;