I'm an Android dev who's trying to get into game dev.
As the title says, I'm trying to load a hundred PNGs as an animation, fullscreen on Android, but no matter what I try, I always getting out of memory errors, ,or heavy lags.
I've tried different engines, as well as different approaches to loading assets, here's a list of what hasn't worked :
1 - Libgdx :
- Using Atlas textures, loaded in splash screen using the assets manager : Process killed with no errors after loading 20 2048*2048 Atlas.
- Atlas Textures without Assets Manager : Huge Lag before the animation actually starts.
- Sequence of PNGs using Assets Manager : Crash with explicit OOM.
P.S : All Atlas files have been compressed to the Max. Average Final file size is about 1.5MB.
2 - AndEngine :
Using Atlas Textures : So far I haven't been able to load multiple atlas pages. Seems like Andengine can only load single page atlases.
Using createTiledFromAssetDirectory() and loading every single PNG from the assets directory to a BuildableBitmapTextureAtlas : Seems like I need to set a fixed size for the BuildableBitmapTextureAtlas, and again, it doesn't support multiple pages. So I'm stuck with loading all my 100s of assets, into a single 2048*2048 atlas. Not what I'm looking for.
Please keep in mind all PNGs are exactly 480*800px and I'm looking to play those in full screen android devices. Each PNG is about 20KB - 40KB after compression with PNGQuant.