I was wondering id there is a special call you can make that destructs all objects that CEGUI made. I now do the following:
Code: Select all
CEGUI::TCEGuiEximionRenderer* renderer = new CEGUI::TCEGuiEximionRenderer(width,height);
CEGUI::LuaScriptModule* scriptModule = new CEGUI::LuaScriptModule( safeCast(TLuaApi*, engine.getScriptingAgentRef()->getApi() )->getLuaState());
new CEGUI::System(renderer,NULL,NULL,scriptModule,(CEGUI::utf8*)"../assets/interface/datafiles/configs/cegui.config");And when closing the application i do
delete CEGUI::System::getSingletonPtr()
But this still leaves a memory leak.

