Page 1 of 1

Optimizing Memory Management

Posted: Thu Jan 20, 2011 00:49
by tedlin01
Hello!
I am using a total of +-100mb of systemmemory using CEGUI. What can I possible do to decrease the usage of system memory?
One way I was thinking of was to release memory that I don't need for the moment but I havnt figured out how to destroy objects in CEGUI to retreive the memory that was allocated for it when loading the imageset.

Also, Is it possible to modify textures in some how or load imagesets and textures in some how to decrease the allocated memory?

Kind Regards..

Re: Optimizing Memory Management

Posted: Thu Jan 20, 2011 12:22
by Kulik
Using std::string instead of the utf32 CEGUI string will be possible in CEGUI 0.8 so if you don't need unicode, all your strings will effectively be 4x smaller in memory with no additional utf8 buffer. You can destroy entire Window hierarchies that you don't need using WindowManager::destroyWindow

Are you sure the 100 MB is entirely taken by just CEGUI?

Re: Optimizing Memory Management

Posted: Fri Jan 28, 2011 10:47
by tedlin01
yes, its accually more then 100mb.. And i noticed it wasnt so easy to just delete stuff hehe. Alot of work to unnestle things from each others... Is there easyfixes to improve memorystorage? Like change the format textures is stored in or gain some memory per windows by some setting. I mean when I load some layouts they just take 25mb+. and yes its alot of windows :)