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 cwodarcz · Feb 23, 2012 at 11:14 PM · wwwlocationstorage

Question regarding where WWW stores content

This is more of a question regarding how files are stored when downloading them through the WWW class. Once a file is successfully downloaded from a server using WWW, is the file placed some place physically on the client side, or is everything just stored in a big cache blob of some kind?

I also noticed that the time taken to download the file also doesn't correspond to actually accessing the data in the file. In other words, if I download about 50 1 MB files, they all download, according to my logs and WWW's isDone and error != null property, along with some timestamps, within 1 second. However, when I actually go to access the texture through the texture property, there seems to be additional lag, so it's like the physical contents of the file are getting loaded at that point? Also, the memory seems to drop a lot at this point, so I'm guessing this is when the actual Texture2D is allocated? If so, what is in the WWW object before this access is done that takes up so much less space?

The last question is, eventually, after accessing about 20 of these files (~29 MB from my calculations), the unity run browser crashes due to being out of memory (d3d: out of memory). If I don't access the texture property at all, and just store the WWW objects by their lonesome, I don't have any out of memory crash. Is this the purpose of downloading an entire AssetBundle, to sort of cram more data into a compressed bundle to save memory in this instance? Also, would there be a way to free up that Texture2D if I don't need it anymore? The texture property is readonly, so I can't set it to null afterwards, and I wouldn't want to null out the WWW, since then I take it the downloaded file itself is then no longer accessible?

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 rabbitfang · Feb 24, 2012 at 04:53 AM 0
Share

Split this up into multiple questions.

1 Reply

· Add your reply
  • Sort: 
avatar image
0
Best Answer

Answer by Dreamora · Feb 26, 2012 at 09:22 AM

Where is it stored: nowhere. if it runs in the browser, the browser might store it but thats up to the browser.

Lag on load: Thats correct, www.texture will load the image. before this point its only meaningless byte blob data. Also keep in mind that when meshes / textures are rendered for the first time, they need to be uploaded to vram, thats a blocking process, the heavier the asset is the longer it goes. For asset bundles, the accessing to them kicks of the 7zip decompression as asset bundles are 7zip compressed

Crash: thats expected if you don't unload the asset bundle, at least if the graphics chip is low on VRAM. If you destroy the texture that won't change anything, you need to unload the bundle too as it keeps the texture alive.

Comment
Add comment · Share
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

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

7 People are following this question.

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

Related Questions

WWW Downloaded file 1 Answer

Problems entering in Fly Mode 1 Answer

Transform coordinates where the cursor clicks... 2 Answers

Update position of an object to match a high velocity object and still allow OnMouseOver() 1 Answer

I want to change the object position random in five particular position only. 0 Answers


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