idmission-web-sdk 0.0.14 → 0.0.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2788,8 +2788,14 @@ var reducer$3 = function reducer(state, action) {
2788
2788
  faceNotCentered = Math.abs(vCX - fCX) > vTX || Math.abs(vCY + 50 - fCY) > vTY;
2789
2789
  faceLookingAway = Math.abs(fCX - nose.x) > fTW || Math.abs(fCY - nose.y) > fTH;
2790
2790
  }
2791
- var tooCloseMultiple = isMobile() ? 2 : 4.5;
2792
- var tooFarMultiple = isMobile() ? 6 : 7;
2791
+ var isMobile = state.videoWidth < state.videoHeight;
2792
+ var tooCloseMultiple = isMobile ? 2 : 4.5;
2793
+ var tooFarMultiple = isMobile ? 6 : 7;
2794
+ console.log({
2795
+ faceBoxWidth: face.box.width,
2796
+ videoWidth: state.videoWidth,
2797
+ tooCloseMultiple: tooCloseMultiple
2798
+ });
2793
2799
  faceTooClose = face.box.width > state.videoWidth / tooCloseMultiple;
2794
2800
  faceTooFar = face.box.width < state.videoWidth / tooFarMultiple;
2795
2801
  }