Author Topic: Spritesheets being referenced in profiler, even though they are not in the scene  (Read 3686 times)

huevoquilmes

  • Newbie
  • *
  • Thank You
  • -Given: 2
  • -Receive: 0
  • Posts: 10
    • View Profile
When I run the scene on the Unity Editor (freshly opened), with a simple scene, I get the following in the profiler:

(see attachment1)

If I then go, and run this on a device, with the profiler attached (Ipad, clean install), the reference count is now as follows:

(see attachment2)

I have read a lot of post on the forum, about older versions of NGUI, having old references to atlases/ spritesheets, and never letting go of them. Could this be the case again? I think I did have a reference to that spritesheet before in the scene, but not anymore, and I'm 100% certain that nothing is referencing those things anymore.

Whats the solution here?

Thanks

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
I'm not sure what I should be looking at in your screenshots. It's up to you to unload atlas textures when you want to release them if you've loaded them dynamically, otherwise they will be automatically released when you switch scenes. NGUI handles the drawing. It doesn't Resource.Load anything, so neither will it Resource.Unload anything.

huevoquilmes

  • Newbie
  • *
  • Thank You
  • -Given: 2
  • -Receive: 0
  • Posts: 10
    • View Profile
Sorry, maybe I should have explained better.

That is the profiler for my first scene in the game. It references some spritesheets, which nothing in the scenes references to them, making me wonder why they are there.

I did some research, and found some old issues of this happening in NGUI, and was wondering if it could be the same, and what a solution to this would be.

For example, this is one of the posts:
http://www.tasharen.com/forum/index.php?topic=5591.0