Compare commits

..

2 Commits

View File

@ -139,6 +139,7 @@ export default struct FaceCompare {
.backgroundImageSize({ width: '100%', height: '100%' }) .backgroundImageSize({ width: '100%', height: '100%' })
.onClick(() => { .onClick(() => {
this.controller.stop() this.controller.stop()
clearInterval(this.interval)
this.vocObj && this.vocObj.releasePlayer() this.vocObj && this.vocObj.releasePlayer()
this.showFaceCompare = !this.showFaceCompare this.showFaceCompare = !this.showFaceCompare
this.showFaceCompareFlag = !this.showFaceCompareFlag this.showFaceCompareFlag = !this.showFaceCompareFlag
@ -250,6 +251,9 @@ export default struct FaceCompare {
} }
}, 1000) }, 1000)
globalThis.udpClient2.setMsgCallBack((val) => { globalThis.udpClient2.setMsgCallBack((val) => {
if(globalThis.statue!=3){
return
}
if (val.id == '48') { if (val.id == '48') {
if (val.body[13] == '1') { if (val.body[13] == '1') {
this.showFaceCompareFlag = !this.showFaceCompareFlag this.showFaceCompareFlag = !this.showFaceCompareFlag
@ -322,7 +326,7 @@ export default struct FaceCompare {
} }
async aboutToDisappear() { async aboutToDisappear() {
clearInterval(this.interval)
} }
} }