相机面部检测坐标到屏幕坐标 [英] Camera face detection coords to screen coords
本文介绍了相机面部检测坐标到屏幕坐标的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我最近开始使用Android的相机API.我正在使用人脸检测,它是回调setFaceDetectionListener
.我在尝试理解如何将faces[0].rect.centerX();
和faces[0].rect.centerY()
转换为我可以在屏幕上使用的东西方面遇到麻烦,例如围绕着以该点为中心的脸部移动图像.
i've recently started playing with Android's camera api. And i'm using face detection and it's callback setFaceDetectionListener
. I'm having trouble trying to understand how to convert the faces[0].rect.centerX();
and faces[0].rect.centerY()
to something i can use on screen like move a image around the face centered on that point.
任何人都可以帮助我了解如何从相机给出的坐标系转换为我可以用来在活动中设置元素的东西.
can anyone help me understand how to convert from the coord system given by the camera to something i can use to set elements on my activity.
推荐答案
查看全文