Quantcast
Channel: Latest Questions on Unity Answers
Viewing all articles
Browse latest Browse all 171066

Determining Texture Memory Usage

$
0
0
I'm currently trying to port a game to iOS and running into memory issues. I know that the game is pretty liberal with memory usage, and I'd like to track down the biggest offenders so I can clean them up. However, running the profiler produces results that I don't quite understand, and I was hoping somebody could help me shed some light on what they mean. Here's what I see when I look at the memory usage reported by the profiler on the iOS build from within the editor: Total: 180.7 MB **Textures: 1127 / 65.3 MB** Meshes: 596 / 0.9MB Materials: 261 / 102.9 KB AnimationClips: 0 / 0 B AudioClips: 16 / 3.4 MB Assets: 2206 GameObjects in Scene: 764 Total Objects in Scene: 4232 Total Object Count: 6438 This claims that I'm using far more memory than I would have expected on textures. However, when I look at the same scene using [Resource Checker][1], what I see is much closer to what I expect: - 25 Textures total, whose combined sizes are 14.03 Mb - 3 textures that are 2048x2048 RGBA Compressed PVRTC 4 bits, each taking up 2.0Mb - 7 textures of various non-power-of-two dimensions. They aren't compressed, but they're also not particularly large; they range in size from 556k to 750k. - 5 textures that are 1024x1024 RGBA Compressed PVRTC 4 bits, each taking up 512k - 9 remaining textures that are all power-of-two sizes between 4x4 and 512x512. None of these take up more than 256k. I can't find any objects in my scene that are using a texture that isn't one of these 25. This leaves me with two primary questions: 1) What are the other 1121 textures that the profiler claims that I'm using? Are these textures being used by the editor? If so, how can I get a better sense of where my memory is actually being used on device? 2) The profiler claims that I'm using 180.7 MB total, but the breakdown below only adds up to around 70 MB. Where is the extra 110 MB coming from? Thanks for any help. [1]: http://forum.unity3d.com/threads/132008-Resource-Checker-(FREE)-List-Texture-Material-Mesh-Memory-use-in-scene

Viewing all articles
Browse latest Browse all 171066

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>