重新设置获取逻辑
This commit is contained in:
parent
fa4e4fa3b1
commit
9d48046ca5
|
|
@ -129,6 +129,12 @@ func GetVideoStream(id int) {
|
||||||
log.Println("device:", id, " not found")
|
log.Println("device:", id, " not found")
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if DeviceIsGettingFrame[id] == true {
|
||||||
|
log.Println("for device:", id, " is running!")
|
||||||
|
break
|
||||||
|
}
|
||||||
|
|
||||||
if device.NextStop {
|
if device.NextStop {
|
||||||
DeviceIsGettingFrame[id] = false
|
DeviceIsGettingFrame[id] = false
|
||||||
break
|
break
|
||||||
|
|
@ -139,6 +145,8 @@ func GetVideoStream(id int) {
|
||||||
log.Println("device:", device.ID, " set control info status:", status)
|
log.Println("device:", device.ID, " set control info status:", status)
|
||||||
getVideoFrame(device)
|
getVideoFrame(device)
|
||||||
DeviceIsGettingFrame[id] = false //停止之后,设置已停止信息
|
DeviceIsGettingFrame[id] = false //停止之后,设置已停止信息
|
||||||
|
//等待1s
|
||||||
|
time.Sleep(1 * time.Second)
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue