1.Cgtransform main three functions, pan (translation), zoom (scale), rotation (Rotate).
panning :
Self.imageView.transform = cgaffinetransformmaketranslation (;() not cumulative, one end)
Self.imageView.transform = Cgaffinetransformtranslate (Self.imageView.transform,,);(accumulated on the basis of the original)
Zoom :
Self.imageview.transform=cgaffinetransformmakescale (1.2);(not cumulative, one end)
Self.imageview.transform=cgaffinetransformscale (Self.imageView.transform, 1.5, 1.6);(accumulated on the basis of the original)
Rotation :
rotating on the basis of the original
// rotation angle is 1/pi, counterclockwise
self. ImageView. Transform = cgaffinetransformrotate(selfimageView. Transform,-m_1_pi);
// rotation angle is pi/2, clockwise
self. ImageView. Transform = cgaffinetransformrotate(selfimageView. Transform, m_2_pi);
PS: The reader can put several functions together to use, can build some basic animation effect Oh .
"IOS" several animations about Cgtransform