0
的周長我有一個UIBezierPath:獲取區和UIBezierPath IOS
CGPathRef tapTargetPath = CGPathCreateCopyByStrokingPath(tracePath.CGPath, NULL, marginError, tracePath.lineCapStyle, tracePath.lineJoinStyle, tracePath.miterLimit);
UIBezierPath *tracePath = [UIBezierPath bezierPathWithCGPath:tapTargetPath];
,當它在該方法中感動:
- (void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event
我得到一分。當我檢索2分我想要得到我感動的UIBezierPath的片段(區域或周長)時,我該如何實現這一點?
您應該使用'CGRectInset'放大您的初始矩形。 – Martin