xcode iOS中的人脸检测

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/16140378/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-15 03:15:37  来源:igfitidea点击:

Facedetection in iOS

iosobjective-cxcodephotoface-detection

提问by Lukas

I'm currently working on a project, where I need to detect a face and then take a photo with the camera. (after the camera focused everything correctly).

我目前正在做一个项目,我需要检测人脸,然后用相机拍照。(在相机正确聚焦一切之后)。

Is something like this possbile in iOS?
Are there any good tutorials on this?

在 iOS 中有这样的事情吗?
有没有这方面的好教程?

回答by Jigar Parekh

i would suggest to use opencv for this as it has proven algorithm and fast enough to work on image as well as video

我建议为此使用 opencv,因为它已经证明了算法并且足够快,可以处理图像和视频

https://github.com/aptogo/FaceTracker

https://github.com/aptogo/FaceTracker

https://github.com/mjp/FaceRecognition

https://github.com/mjp/FaceRecognition

This solution will work for android too using opencv port to android.

此解决方案也适用于 android,使用 opencv 端口到 android。

回答by DharaParekh

Use GPUImagefor face detection. Face detection example is also available in GPUImage. see last point in FilterShowCase example project of GPUImagefor face detection.

使用GPUImage进行人脸检测。GPUImage 中也提供了人脸检测示例。参见用于人脸检测的GPUImage 的FilterShowCase 示例项目中的最后一点。

回答by dimo hamdy

iOS 10 and Swift 3

iOS 10 和 Swift 3

You can check apple example you can detect face

你可以检查苹果的例子,你可以检测人脸

https://developer.apple.com/library/content/samplecode/AVCamBarcode/Introduction/Intro.html

https://developer.apple.com/library/content/samplecode/AVCamBarcode/Introduction/Intro.html

you can select the face metedata to make camera track the face and show yellow box on the face its have good performace than this example

您可以选择人脸元数据使相机跟踪人脸并在人脸上显示黄色框它比这个例子有更好的表现

https://github.com/wayn/SquareCam-Swift

https://github.com/wayn/SquareCam-Swift