【发布时间】:2014-12-24 13:56:12
【问题描述】:
我有一个UIView,其中view.layer.mask 设置为CAShapeLayer 的一个实例。形状层包含一个路径,现在我想通过添加第二个具有奇偶规则的形状来为这个形状添加一个洞,并淡入这个洞的外观。
问题是添加到路径似乎不是可动画的:
[UIView animateWithDuration:2 animations:^() {
CGPathAddPath(parentPath, nil, holePath);
[v.layer.mask didChangeValueForKey:@"path"];
}];
我将如何制作动画?
【问题讨论】:
标签: ios objective-c core-animation calayer