Hi i wonder how many textures/textureAtlases can be used in runtime and where exactly they are stored: in gpu memory or in ram memory?
where texture are stored?
(7 posts) (6 voices)-
Posted 10 months ago #
-
It depends on how much memory is avaliable. In GPU memory.
Posted 10 months ago # -
i have read somewhere that it gives priority to the ram memory
Posted 10 months ago # -
Both actually if you don't dispose the source, since the underlaying bitmap data is stored in RAM and then it is uploaded to GPU memory. Bitmapdata is kept in RAM to handle situations like device loss.
Anything that is drawn onto a screen needs to be in GPU memory you can't draw stuff that isn't in GPU memory
Posted 10 months ago # -
Exactly! If the bitmap data stays in RAM can be configured using "starling.handleLostContext". On iOS and OS X, it's not necessary (they don't ever lose the context), but on Android and Windows, it's required to activate it.
Posted 10 months ago # -
In mobile project how many texture atlses (2048x2048) can be used in the same time? What is a good practice for that?
Posted 10 months ago # -
Depending of your device but of course less you have, more good it is. The best practice is to remove the unused texture atlas.
For example if you use one texture atlas for your home(button/background/etc), when you launch the game scene, remove texture atlas used for the home and load textures atlas of your game, etc..
I hope it will help you.
Posted 10 months ago #
Reply
You must log in to post.