mirror of
https://github.com/openharmony/useriam_faceauth.git
synced 2026-07-18 16:24:42 -04:00
fix: use the buildin camera to auth
Signed-off-by: Zen知仁 <xuzhiren@huawei.com> Change-Id: Ieb978391d43b30cd7b54c1a1a67bdb9f6c2ebba2
This commit is contained in:
@@ -82,7 +82,8 @@ int32_t FaceAuthCamera::CreateCamera(sptr<IBufferProducer> producer)
|
||||
sptr<CameraStandard::CameraInfo> camera = nullptr;
|
||||
if (cameraObjList.size() > 0) {
|
||||
for (unsigned int i = 0; i < cameraObjList.size(); i++) {
|
||||
if (cameraObjList[i]->GetPosition() == OHOS_CAMERA_POSITION_FRONT) {
|
||||
if (cameraObjList[i]->GetPosition() == OHOS_CAMERA_POSITION_FRONT &&
|
||||
cameraObjList[i]->GetConnectionType() == OHOS_CAMERA_CONNECTION_TYPE_BUILTIN) {
|
||||
camera = cameraObjList[i];
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user