**I use in the cocos2dx ParticleSystem in my game program,but it can appear memory clear off and crash problem.who can help me solve it?
Specific questions as follows:
1, when I am switching scene, delete the emitter before, once again, to create, then the memory can’t completely empty, lead to switch scene every time, memory can increase a lot.
2, when the emitter is operating,the memory increase by itself.
3,My program is developped under Windows development,after transplanted to the iPad, it will appear crash every once in a while, the problem is the place where CCParticleSystemQuad.cpp #if CC_USES_VBO code there.
How to solve these problems? Is it cocos2dx’ bugs?
Hope masters as soon as possible to solve.
Thanks!
**
Hi, Tiger Feng,
Could you please offer the demo that can reappear this problem?
Yeah, I got the same problem on Android Platform as well.
To explain clearly, I write an example here:
- Suppose that we have two different scenes, called scene1 and scene2, where scene1 is the main screen when we enter the game.
- At scene2, we add a particle system using a plist file, say “bubbles.plist”, with the texture data in the plist file.
- On scene1, we have a button to go to scene2 using replace scene, same in scene2 having a button going back to scene1.
- On both scenes, we have onExit() called to clear the Texture and SpriteFrame Cache.
- Keep switching in between these scenes will crash the program, sometimes will cause blank spriteFrames (White boxes) on other scenes when those scenes are loading spriteframes and texture using a plist+pvr.ccz combo.