Share Posted June 12, 2012 My animation (a rotating loading indicator) occasionally stalls as my app is processing some code. Is there a way to avoid this? Is there a way to make the animation run on the GPU rather than the CPU? Any ideas are welcomed! thanks, Jack Below is the code that I run. The displayObject "_spCenter" is a circular loading indicator: private function rotate():void { if(_tween == null || !_tween.active){ _tween = new TweenLite(_spCenter, .6, {rotation: 355, ease: Linear.easeInOut, onComplete:rotate}); } } Link to comment Share on other sites More sharing options...
Share Posted June 12, 2012 nope. if flash is processing an intensive amount of code the next frame will not render until that code is processed. I am not aware of any work-arounds for this. Link to comment Share on other sites More sharing options...
Author Share Posted June 13, 2012 What about Stage3D? Is that something to look into? Link to comment Share on other sites More sharing options...
Share Posted June 13, 2012 I doubt Stage3D will solve your problem or that the rotation is really the source anyway, but I will point out that using TransformMatrixPlugin to do the rotation may be a bit smoother - see the interactive example at http://www.greensock.com/tweening-tips/ (first tip) Link to comment Share on other sites More sharing options...
Share Posted June 14, 2012 try to divide calculations over multiple frames: http://www.senocular.com/flash/tutorials/asyncoperations/ Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now