草庐IT

rotationWithPerspective

全部标签

ios - 了解 CATransform3DRotate/CATransform3DMakeRotation

我正在尝试了解如何像这样为我的UIView创建深度感知:我试过这段代码:varrotationWithPerspective=CATransform3DIdentity;rotationWithPerspective.m34=-1.0/500.0/2/2rotationWithPerspective=CATransform3DRotate(rotationWithPerspective,22.5,0,1,0);preview.layer.transform=rotationWithPerspective生成透视图。然而,它出于某种原因翻转View。1)如何避免转换后的“翻转”?2)转换