我正在做一些相对于缩放图像的绘图,所以我最终得到了分数 CGPoints。我正在缩放 CoreImage 人脸检测例程的结果。
CGPathAddLineToPoint
当我在通话中使用这些点时,我是想自己四舍五入还是留给 iOS 来做?如果舍入更好,我应该向上舍入还是向下舍入?
我已经阅读了有关像素边界等的信息,但我不确定如何在这里应用它。我正在画一个CALayer
CGPoint leftEye = CGPointMake((leftEyePosition.x * xScale),
(leftEyePosition.y * yScale));
// 结果
features {
faceRect = "{{92, 144.469}, {166.667, 179.688}}";
hasLeftEyePosition = 1;
hasMouthPosition = 1;
hasRightEyePosition = 1;
leftEyePosition = "{142.667, 268.812}";
mouthPosition = "{176, 189.75}";
rightEyePosition = "{207.333, 269.531}";
}