Smoothly moving a jpeg

Tim Selander selander at tkf.att.ne.jp
Wed Dec 16 21:59:13 EST 2009


Scott,

Thanks - shortening the changes in distance helped a lot. So it 
appears Rev doesn't visibly move an image, it jumps it to the 
next location.

If I move the image a pixel at a time, but tighten the loop to 2 
or 3 milliseconds, things get pretty smooth. Now to test the 
reading speed with the on camera talent!

Tim Selander
Tokyo, Japan


Scott Rossi wrote:
snip

> well moving large images.  That said, I would try to repeatedly set the
> position of the image with short changes in distance in a tight "send..."
> loop.  Here's a simple example:
> 
> on mouseUp
>    moveImage
> end mouseUp
> 
> on moveImage
>    if right of img 1 < 10 then exit moveImage
>    set left of img 1 to (left of img 1 - 2)
>    send "moveImage" to me in 5 millisecs
> end moveImage
> 
> This makes for substantial processor use, but also makes for smoother move
> effects.
> 
> Another option I would try is to move the physical position of the stack in
> which the image appears across the desktop, instead of moving the image
snip



More information about the Use-livecode mailing list