Created
January 3, 2019 21:48
-
-
Save yarneo/f2f7ffb97da2987dae095802e9ae54f5 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (MDCPathGenerator *)pathGeneratorForCornerWithAngle:(CGFloat)angle | |
andRadius:(CGFloat)radius { | |
MDCPathGenerator *path = | |
[MDCPathGenerator pathGeneratorWithStartPoint:CGPointMake(0, radius)]; | |
[path addArcWithTangentPoint:CGPointZero | |
toPoint:CGPointMake(MDCSin(angle) * radius, MDCCos(angle) * radius) | |
radius:radius]; | |
return path; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment