Hi,
We are trying to get our game running on older iOS devices and noticed that some of our atlases are being loaded into memory multiple times when I check in the profiler (both when running the game in the editor and also on device).
Research into this area suggests that tinting a sprite causes that texture to be loaded multiple times, is that correct? So if I tint the colour of one sprite that is part a big atlas, that entire atlas is loaded into memory again?
I understand having it read/write enabled will double the amount of memory needed too. Is there anything else that can cause a sprite/texture to be loaded multiple times?
Just trying to learn as much as possible about textures and memory usage on mobile platforms, any advice, tips and tricks would be greatly appreciated.
Just returning to this issue as had to put it on the back burner for a while.
Pretty sure I found the cause. We are using asset bundles, and when we load an asset bundle we were loading the sprites from an atlas into a dictionary for quick access (they are all needed in the scene anyway). These were been referenced in memory by ManagedStaticReferences which makes sense.
We were also loading prefabs from Resources folder during gameplay, and these prefabs had reference to sprites in the asset bundle. Even though the sprite was already referenced by ManagedStaticReferences, the prefabs were causing the atlas to be loaded again. Seems like the texture attained from the assetbundle is different from the texture referenced in the prefab in the resources folder. Perhaps I need my prefabs to be part of the asset bundle?