sobota, 26 lutego 2011

memory

Our first problem was memory. My friend, who is a great graphic designer and team member responsible for visual aspects of our game, created a set of images (frames) representing our main game character. We wanted to use spritesheets to animate character. There were about 160 frames for almost every character's move. Each frame was about 80x60 pixels. We prepared sprites in Texturepacker.


When we loaded files into program it turned out that it doesn't work on 3G device. We could see only black screen. 3GS device had no problem with launching.


We added a piece of code showing texture memory. 12MB. With a little help of Google we found blog post describing memory difference between 3G and 3GS. The guy wrote that after launching basic apps on 3G developer has no more than 13MB of free memory. Our 3G was stopping at 8MB.


At the first moment we decided that we'll focus on 3GS and 4 devices. The second thought was that we have no idea about minimal memory in Android devices. We can't loose few millions of potential customers.


The solution of problem was optimization of graphics: reduction of size and number of frames. Now animation works also on 3G device.

Brak komentarzy:

Prześlij komentarz