@kaelthas/react-native-ksface

0.0.1 • Public • Published

#

旷视人脸识别

程序配置

  1. 325、804等硬件激活设备
   
      //旷视人脸-正元定制
    implementation files("./libs/FacePassAndroidSDK-month-release.aar")

    //旷视人脸-软件激活
    //implementation files("./libs/FacePassAndroidSDK-McvSafe-release.aar")

    //旷视人脸-公共部分
    implementation files("./libs/mcvSafe.v1.2.2.aar")

  1. 其他设备

    //旷视人脸-正元定制
    //implementation files("./libs/FacePassAndroidSDK-month-release.aar")

    //旷视人脸-软件激活
    implementation files("./libs/FacePassAndroidSDK-McvSafe-release.aar")

    //旷视人脸-公共部分
    implementation files("./libs/mcvSafe.v1.2.2.aar")

使用

  1. 设置参数
import KSFaceView, {KSFace} from 'react-native-ksface'
KSFace.setConfig({
  isCross: false,
  cameraFacingFront: false,
  livenessEnabled: false,
  cameraPreviewRotation: 90,
  faceRotation: 90,
  faceMinThreshold: 40,
  searchThreshold: 0.7,
})
参数 说明 默认值
isCross 镜像展示 false
cameraFacingFront 是否使用前置摄像头 false
livenessEnabled 是否开启活体检测 false
cameraPreviewRotation 画面预览角度 90
faceRotation 算法角度 90
faceMinThreshold 人脸识别距离,数值越小识别距离越远 40
maxFailCount 人脸检测失败次数,到达次数后返回识别失败 8
searchThreshold 算法最小相似度 0.7
  1. 激活程序
    1. 325、804、327
    KSFace.checkAuthStatusByHardware(result=>{
    
    })
    1. 其他设备
    KSFace.checkAuthStatus("cert", "activateCode",result=>{
    
    })
  2. 初始化
    KSFace.init()

Readme

Keywords

none

Package Sidebar

Install

npm i @kaelthas/react-native-ksface

Weekly Downloads

0

Version

0.0.1

License

none

Unpacked Size

46.3 MB

Total Files

23

Last publish

Collaborators

  • kaelthaswang