Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by higgorleimig · Jan 21, 2015 at 02:25 AM · performancewindows phone 8out of memory

WP Out of Memory

Hey guys, can I borrow your wisdom for a few minutes? I'm developing a 2D game with Unity 4.6.1.f1 and I'm having issues with memory usage in low-end Windows Phone devices (Lumia 520). So,

  • I already know that WP have limitations with memory usage (180MB in my case)

  • I did several improvements in my materials and load/unload process

  • I encoded my sounds and I'm streaming them from the disk.

My point is, I read and followed a lot of articles around the internet about Unity optimization and it doesn't seen to have any effect on WP devices. My game runs smoothly in low-end android devices and iPhone 4S/iPad 2. Can you guys help me? I used the XCode profiler and saw that my game uses (while changing scenes, the moment with higher memory usage) 140MB, which is way less than the WP limit. Here's the Out of Memory error:

 Could not allocate memory: System out of memory!
 Trying to allocate: 695364B with 32 alignment. MemoryLabel: Texture
 Allocation happend at: Line:411 in C:/BuildAgent/work/d63dfc6385190b60/Runtime/Graphics/Texture2D.cpp
 Memory overview
 
 
 [ ALLOC_DEFAULT ] used: 3468146B | peak: 6641054B | reserved: 3954205B 
 
 [ ALLOC_GAMEOBJECT ] used: 134088B | peak: 134088B | reserved: 159687B 
 
 [ ALLOC_GFX ] used: 120714620B | peak: 120714620B | reserved: 120718714B 
 
 [ ALLOC_PROFILER ] used: 13516B | peak: 13516B | reserved: 33526B 
 
 Could not allocate memory: System out of memory!
 Trying to allocate: 695364B with 32 alignment. MemoryLabel: Texture
 Allocation happend at: Line:411 in C:/BuildAgent/work/d63dfc6385190b60/Runtime/Graphics/Texture2D.cpp
 Memory overview
 
 
 [ ALLOC_DEFAULT ] used: 3468146B | peak: 6641054B | reserved: 3954205B 
 
 [ ALLOC_GAMEOBJECT ] used: 134088B | peak: 134088B | reserved: 159687B 
 
 [ ALLOC_GFX ] used: 120714620B | peak: 120714620B | reserved: 120718714B 
 
 [ ALLOC_PROFILER ] used: 13516B | peak: 13516B | reserved: 33526B 
 
  
 (Filename: C:/BuildAgent/work/d63dfc6385190b60/Runtime/Allocator/MemoryManager.cpp Line: 917)

I cannot understand everything in this error message (it's kinda strange to be honest), but I'm guessing the reason is peak in the ALLOC_DEFAULT? I had the same situation before the improvements where the ALLOC_GFX peak was higher than the reserved, but now it seems ok. Can somebody give me a light?

EDIT

Ok, more information. I know that WP != iOS != Android and that compare them is not very uselful is my case. But I couldn't find a way to profile my WP for its memory usage. Unity doesn't find it when I search for its IP and the Visual Studio profiler only gives me CPU usage. That's why I used the iOS profiler just to have an idea.

About compressing the images, they are all compressed (with a few exceptions since they would lost gradient). I even tried to use mipmaping to reduce the image, but the only thing it did was to increase the memory usage for ALLOC_GFX, that's why I left them without it. If anybody needs for information, just ask, please. About the log, does anyone knows how to read it? What does the ALLOC_DEFAULT means?

Comment
Add comment · Show 2
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Landern · Jan 21, 2015 at 03:03 AM 0
Share

Windows Phone != Android != iOS, this is silly and using a profiler for one doesn't not equal the others. You could have separate importation settings for each platform. Your textures could be nuts in size and use a very high bit rate, you haven't even mentioned the texture sizes or compression's used on windows phone. There isn't enough information to form an opinion other then your comparisons. Add more information please that is meaningful.

avatar image higgorleimig · Jan 21, 2015 at 02:18 PM 0
Share

I edited the post, what kind of information you need besides that?

0 Replies

· Add your reply
  • Sort: 

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

3 People are following this question.

avatar image avatar image avatar image

Related Questions

The size of the XAP and performance, after the publication in the shop 0 Answers

Performance difference WP8 and Android - Even in a very simple 2D game 1 Answer

Huge memory usage textures 1 Answer

OnAudioFilterRead causes unneccessary GC on WP8? 0 Answers

Unity WP8 Better Performance When Connected to Visual Studio 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges