Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 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 OtmNick · Feb 05, 2016 at 10:48 AM · buildpipelinebuilds

Unity Build Memory Usage Patterns

Hi all,

We are on Unity 4, and are hitting build issues now that our project has reached a certain size. We got away with this for a while by running builds in batch mode, but we've exhausted the savings from that now.

Unfortunately, the structure of the game requires that a lot of assets are not tied to particular scenes, therefore are included under the Resources folder. We are now hitting the 32-bit process limit and crashing.

I wanted to see if my understanding of my options is correct, if someone with a deeper knowledge of memory usage during the build process was able to chime in I'd be really grateful.

So, as far as I know, Unity builds assets on a scene-by-scene basis, and tackles stuff in the Resources or StreamingAssets folders separately. Obviously some of the memory 'load' is therefore split between the build preparation for each scene, and stuff gets unloaded once a scene is built. But the problems come from the monolithic asset folders like Resources.

Does anyone understand what happens during this part of the build? Does it deal with assets on a type-by-type basis? Or path? Does it prepare assets in batches, or serially? I'm assuming it must hoover up a bunch, bake them down into the build then move on , but what's the process? If I have too many large assets of a single type am I more likely to hit the 32-bit limit?

Is there any way to mitigate this by doing things like using multiple resources folders? Or perhaps even by including a dummy scene in the build which had some of the resources assets in its hierarchy (which could force them to be built during the 'scene build' stage, and skipped later)?

Basically, are there any other options other than remove or shrink assets? Can anyone shed light on some of the internals of the build process?

Comment
Add comment · Show 1
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 abnu · Feb 05, 2016 at 04:41 PM 0
Share

I can't help you with all of the questions but regarding the multiple Resources folder approach, I don't think that would work because Unity puts everything that is in a Resources folder anywhere under the Assets folder in a combined Resources folder for the build. Splitting the Assets in the Resources folder into a few Asset Bundles (http://docs.unity3d.com/ScriptReference/AssetBundle.html) and loading them from disk (depending on the target platform that might be annoying) when the game starts/you need them would probably work here

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

34 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Getting the current BuildOptions 1 Answer

Unity -executeMethod Problem (executeMethod method 'Build' in class 'TestScript' could not be found.) 2 Answers

Batch File and Script to Make Multiple Builds 1 Answer

How to create a BuildOptions mask in the Editor Window? 2 Answers

Building Question 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