Alternative to copyArea?
Posted on 1999-07-13
I'm doing an animation which involves moving an image across the screen. I use an offscreen buffer & double-buffering, there's a background image and a 'sprite' image. For a start I was copying the entire background image to the buffer, then the sprite, updating, redrawing the bg image to 'clear' then screen and redrawing the sprite at the new position.
I then used copyArea to copy part of a background to an offscreen area so that I can then draw an image over that part of the background, update the screen, copy the background section back, move the image and repeat.
This works fine but I'd rather create a small graphics buffer to hold the image. So is there an alternative function that will copy an area of one buffer into another?