Explorar o código

新活检:人脸晃出摄像头放松

Michael Wang %!s(int64=5) %!d(string=hai) anos
pai
achega
7f0292f206
Modificáronse 1 ficheiros con 3 adicións e 1 borrados
  1. 3 1
      src/features/OnlineExam/Examing/FaceMotion/FaceMotion.vue

+ 3 - 1
src/features/OnlineExam/Examing/FaceMotion/FaceMotion.vue

@@ -590,7 +590,7 @@ export default {
         }
         if (
           this.singleFaceFailedTimes >= 3 &&
-          this.singleFaceFailedTimes / this.totalDetectTimes >= 0.2
+          this.singleFaceFailedTimes / this.totalDetectTimes >= 0.4
         ) {
           this.corFinalResult.result = false;
           this.corFinalResult.waggleOutCamera = true;
@@ -703,6 +703,8 @@ export default {
               this.doneCompare = true;
               if (this.compareResult.isPass && !this.compareResult.isStranger) {
                 console.log("人脸同步比对成功");
+                // 初始化晃出摄像头次数
+                this.singleFaceFailedTimes = 0;
                 if (!this.instructionsFinished && this.currentStep)
                   this.currentStep.finished = true;
               } else {