我正在尝试在从捏合手势识别器缩放图像后应用3D变换。当应用3d变换时图像重新调整为默认大小(即在缩放之前的大小)。如何让imageView停止回到Previous状态(即在Pinch之前)
self.transform = CATransform3DIdentity
self.transform.m34 = 1.0 / 500.0;
self.transform = CATransform3DRotate(self.transform, CGFloat(145 * M_PI / 180), 0, 1, 0)
viewToDelete.layer.transform = self.transform
func handlePinch(_ nizer:UIPinchGestureRecognizer) {
nizer.view!.transform = nizer.view!.transform.scaledBy(x: nizer.scale, y: nizer.scale)
nizer.scale = 1
}