Hey,
 
There is a big difference in animation/effect performance across computers in 
Flex.  On our macs (Mac Pro desktop, Macbook Pro, MacBook), everything is 
fairly smooth (Firefox and Safari).  On any Windows XP (Firefox or IE), alpha 
and translation animations/effects are very choppy, not to mention rotation or 
anything more complex: a TweenMax alpha tween from 1 to 0 in 1 second only uses 
3-4 frames, instead of 24-60.  On Windows Vista, it's like 2 frames (this is on 
a Panel 500 x 500).  Same with tweening x and y.  Same with running Andrew 
Trice's KeyFrame and MotionPath example, very choppy on anything but a mac, 
especially if you have a full blown application with 50+ components on the 
stage at once.
 
I think this might have something to do with the event dispatching going on 
with animating properties.  When you tween the "alpha" on a UIComponent for 1 
second, it can dispatch more than 20 "alphaChanged" events, even when there are 
no listeners for it.  Add in a position animation, and you easily have 50+ 
events being dispatched for every item animating on the screen, plus calls to 
invalidateProperties(), invalidateDisplayList(), etc. (setting 
UIComponent.suspendBackgroundProcessing to 'true' doesn't help), plus all the 
background binding execution flex generates in the background.  Tons of things 
pure Actionscript doesn't use when animating.
 
In pure Flash/Actionscript, when you do animations (like those found on 
Template Monster website templates), they are VERY smooth, even on Windows 
Vista.  The only difference between these animations and those in Flex is:
 
1) Flash is not dispatching any events when properties change.
2) Flash is not calling any invalidation methods when properties change.
 
Granted, invalidation and binding is core to Flex and I love it dearly.  But if 
there was/is a way to prevent any binding updates (event dispatching), and 
calls to even any invalidation methods WHILE ANIMATIONS ARE RUNNING, I think 
animations in Flex would be just as smooth as those in Flash and pure 
Actionscript, on all computers.
 
Question is, is this possible?  Is it possible to say "don't update any 
bindings on these objects until this animation is complete"?  If not, is Ely or 
others involved in the new Spark architecture willing to take on such a task?  
Otherwise it's pointless to use anything but the simplest animations (changing 
alpha or color on a 20x20 ButtonSkin) because its choppiness will just detract 
from the User Experience.
 
Thanks for your help.
 
Lance

Reply via email to