help!!! Memory usage problem!


29-02-2012 12:45:25

hi everyone. :D

i am not speak english, so hope someone can understand what i said.

i use mygui 3.20_RC1 in my project. and i found it fast like many people said. but there is a problem that plagued me for a long time. :(

my project is a mmo game. and in my project, there is a bag system for player( like wow ). so i use itembox for parent widget, and imagebox for item widget, and i call ItemBox::addItem() interface to add item data. then the problem is coming... i found it very slow and the memory usage increase very fast when i add many times( 50 or 100 times. ) :(

so i read the source code of mygui. i found it will create many RenderItem object in LayerNode, and not delete until the LayerNode be destroy when i call imagebox::setImageTexture() many times of different texture. this mean... more times different texture i set to imagebox, more RenderItem will be create. and more memory will be usaged...oh... :(

i thought i can use texture caching, make all small icon( 32 * 32 ) to one big texture, then this problem will be resolved. but there are so many icon file ( 2000 or more ) in my game. :(

i am not sure if there have other way to resolve this problem. if you know, please tell me. thanks very much.


10-12-2012 08:48:55

No one had the same problem? :cry:


04-01-2013 08:45:07

i same to you :( i agree with you