LeoMaskAnimationKit 通过 CocoaPods 提供。要安装它,只需将以下行添加到您的 Podfile 中
pod "LeoMaskAnimationKit"
使用掩码时应在相同坐标系下
圆形视图掩码
-(void)leo_animateCircleMaskWithduration:(NSTimeInterval)duration
delay:(NSTimeInterval)delay
clockwise:(BOOL)clockwise
options:(LeoMaskAnimationOptions)options
compeletion:(void(^)(void))completion;
从任何方向对视图进行掩码处理
-(void)leo_animateRectExpandDirection:(LeoMaskAnimationDirections)directions
duration:(NSTimeInterval)duration
delay:(NSTimeInterval)delay
options:(LeoMaskAnimationOptions)options
compeletion:(void(^)(void))completion;
矩形间掩码
-(void)leo_animateMaskFromRect:(CGRect)fromRect
toRect:(CGRect)toRect
duration:(NSTimeInterval)duration
delay:(NSTimeInterval)delay
options:(LeoMaskAnimationOptions)options
compeletion:(void(^)(void))completion;
路径间掩码
-(void)leo_animateMaskFromPath:(UIBezierPath *)fromPath
toPath:(UIBezierPath *)toPath
duration:(NSTimeInterval)duration
delay:(NSTimeInterval)delay
options:(LeoMaskAnimationOptions)options
compeletion:(void(^)(void))completion;
leoMobileDeveloper, [email protected]
LeoMaskAnimationKit 可在 MIT 许可证下使用。获取更多信息,请参阅 LICENSE 文件。