iphone - UIView Animation, Transforming layer.shadowPath -
i created uiimageview has custom shadowpath. view moved left , right across screen, need shadowpath have different transformation image layer itself. possible? moving image works, , shadow moves when following:
[uiview beginanimations:nil context:null]; [uiview setanimationduration:0.3]; [uiview setanimationcurve:uiviewanimationcurveeaseout]; im.center = location; [uiview commitanimations];
but if try add layer transformation before "commitanimations", shadow take on property right away, example:
[uiview beginanimations:nil context:null]; [uiview setanimationduration:5]; [uiview setanimationcurve:uiviewanimationcurveeaseout]; im.center = location; im.layer.shadowpath = [self createperspectiveshadow:im]; //this not animate [uiview commitanimations];
so, question is, there way recalculate shadow during animation?
thanks
the uiview
animations don’t allow animate calayer
attributes; try using cabasicanimation
instead.
Comments
Post a Comment