A Flash Developer Resource Site

Results 1 to 2 of 2

Thread: Jittery Tween on Jpegs - Tried Everything :(

  1. #1
    Member
    Join Date
    May 2004
    Posts
    57

    Jittery Tween on Jpegs - Tried Everything :(

    Hi there

    I am using TweenMax to tween 3 images across a screen at a time (there is a next button that tweens the first image offstage, and moves the next image in its place and moves another onscreen and so on in a loop).

    The images are loaded dynamically. In the class that handles each image I use this code:

    ('Project' Class extends MovieClip)
    Actionscript Code:
    private function imageLoaded(_e:Event):void{
        var bitmap:Bitmap=Bitmap(image.content);
        bitmap.smoothing=true;
        bitmap.pixelSnapping=PixelSnapping.NEVER;
        bitmap.scaleX=.9;
            bitmap.scaleY=.9;
    }

    These objects are stored in the projects array and tweened from the Document class:
    Actionscript Code:
    TweenMax.to(projects[curImage],1,{x:imagePadding});
    TweenMax.to(projects[curImage+1],1,{x:(imagePadding*2)+projects[curImage].width});
    TweenMax.to(projects[curImage+2],1,{x:stage.stageWidth-projects[curImage+2].width-imagePadding});

    No matter what I do, the tween always seems to jump/jitter. I've tried turning the pixel snapping on, turning cache as bitmap on, upping the framerate, setting the .x destination to a float etc. Apparently setting the x/y scale to .9 is supposed to fix jittery tweening, but I've had no luck with it.

    Is there a definitive Adobe guide to tweening images in Flash? Clarifying the whole pixel versus subpixel stuff?

    I'm confused and stumped!
    He took daddy's umbrella!

  2. #2
    Junior Member
    Join Date
    Jun 2008
    Posts
    3
    I have same problem in my Flex project.
    Did everything like you and still have "jumping" images

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center