CopyPixel large image killing FPS on iOS
So, problem is pretty simple (and limited to the iPhone 3GS, the 4+ seems to handle it ok). I've got a game that uses sprite blitting. So the rendering methods looks something like this:
background.copyPixels(background,rect,point);
then for each sprite :
sprite.copyPixels(spriteSheet,rect,point);
Pretty standard blitting stuff. The problem is when I blit the background image (which is one large 960x640 image) the iPhone justs chokes. Cuts my FPS in half.
For an experiment I tried using fillRect to just clear the bitmap between each frame instead of recopying the BG image, and fillRect took just as long (13FPS!).
Obviously the iPhone 3GS is choking on blitting such a large image. Anyone got anythoughts on how to optimize this? I'd much rather fix it then have to drop all those devices.
thanks guys ![]()
