I want to know the final coordinate of predefined 2 points in TouchImageView. 1. If I just move the touchimageview, these codes are okay. 2. But if I scale or rotate touchimageview, the ptLeft and ptRight are not correct.
CGPoint ptLeft = CGPointMake (100, 100);
CGPoint ptRight = CGPointMake (200, 200);
TouchImageView *touchView = [[TouchImageView alloc] initWithFrame:rect];
....
....
/***** get the coordinate after TouchImageView has been scaled or rotated *****/
ptLeft = CGPointApplyAffineTransform(ptLeft, touchView.transform);
ptRight = CGPointApplyAffineTransform(ptRight, touchView.transform);
Here is the touchimageview source code - TouchImageView source code