Advertisement

Resource Mgr w\ ref counting

Started by March 12, 2001 09:06 PM
-1 comments, last by gimp 23 years, 10 months ago
I''m having trouble coming up with a good resource manager that does reference counting and allows easy access to it''s members. I won''t bore you with the many designes I''ve some up with that don''t work. The way I''d like it to work would have the object ''add'' itself to the list, loading it''s data from disk if it isn''t loaded and adding a reference if it is loaded, likewise on the object destruction it should remove a reference from the list, and if need be delete the object from memory on ref=0; new\delete should be pure virtual I guess as the implemtation will be dependent on the concrete class(ie deleting a texture should call say opengl apis etc). How would I structure such a beast?
Chris Brodie

This topic is closed to new replies.

Advertisement