Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.
what my program tries to do is scale it up when the user touch the object and scale it down when the user lift up the finger. and i tried to use CGAffineTransformScale(transform, 1, 1); however the image kept on shrinking and not coming back to its original size when i kept on touching it...i think the problem is that it is shrinking during the process of growing.

and i think the way to resolve this is to check if the current object is animating or not. i tried to use setAnimationDidStopSelector but i run into a whole new problem with accessing a singleton value...

i also tried to use isAnimating BOOL but that didnt work either...

i am running out of options.
 
yeh sorry i actually have it transform to 0.8 and increase at 1.25...however i dont have the problem makin it shrink its jsut that it shrinks to much...is there anyway i can check if the view is animating?
 
I wonder if you can detect the current scale when the shrinking is supposed to start and then just scale by 1 / current.

yeh i think the 'a' and 'd' values in CGAffineTransform struct (which has a, b, c, d, tx, ty) are the scale values. but when i tried to modify those values the image freak out when i touch on it again...i have no idea what or how to get scale values...
 
This discussion has been very helpful -- thank you all.

The thing to remember is that, using this technique, you are setting a start rotation (which is kinda defaulted) and an end rotation and leaving it to Core Animation to determine how to handle the animation between those. So, if you start at 0º and end at, say, 270º, the animation is going to go counter-clockwise from 360º (the same as 0º) down to 270º. The signedness of the rotation does not affect the direction of rotation. Just the end angle.
Excellent point.

However, I have a situation where I need to be able to control whether the animated rotation is done Clockwise or Counter-clockwise. For my purposes, this could be to a specified (Absolute) angle, or by a +/- Relative angle.

Any ideas how to exercise this kind of control?

Many thanks!
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.