I am a complete beginner to Corona (you can see from other similar questions I am asking). I am using the Director Class and following some tutorials, but none of these tutorials explains to me how memory is handled by the Director Class.
When I replace a scene with another one, should I also free memory “manually”, or are all the items in the local group freed automatically for me?
I am trying to read through the code, but I am a complete newbie and it is a bit complex for me.
Just to follow up with this. My understanding (and what I do) is that there are four things you need to dispose of and nil manually (so long as all objects are in your local group and all varibles and functions are defined as local).
Audio
Timers
EventListeners
SpriteSheets (not the spriteinstance, but the spritesheets themselves) - This is not something that I found that anyone had noted before when I originally searched, but I found that if they are not disposed then it did not free up the texture memory. It could be something that I am doing wrong though.
(I feel like I am missing one more)
Hopefully this helps. There should be examples of how to dispose of each of these if you search the API information.
Jeff is right, I also listed a couple of links for ya
the first one is a little older version of Director
but the principles are the same …
Screen Transitions with Director Class:(Plus a playable game) http://www.youtube.com/watch?v=KudLE8h4kWw