Jump to content
  • Advertisement
Sign in to follow this  
dave

Memory Management Question

This topic is 5072 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

So in the Enginuity articles, do you create a memory managed object via the memory manager. So: a) Look memory manager i would like a memory managed object of type ClassA. b) The memory manager would then create the object on the heap, the object would be pointed to by a smart pointer. c) it would then add the smartpointer to its internal list of live objects? Am i right? Other questions. 1) when it says you would run through the list of liveobject to see if the object is being used. If the object isnt being used would this be marked by a simple bool variable within the object. So if this were true you could have every object that would be on the heap derive from a base object with this variable. 2) An instance of when an object wouldn't be being used would be kinda if something on a map was destroyed, therefore invisible, or like when there is a level change or something. 3) In order for the memory manager to be able to store 1 list containing smartpointers to different types of objects, would this be done with a polymorphic collection? ace

Share this post


Link to post
Share on other sites
Advertisement
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!