drmcnellis / collisiondetectionkit

Automatically exported from code.google.com/p/collisiondetectionkit
0 stars 0 forks source link

Call dispose() on BitmapData objects when done #11

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Its probably a good idea to call BitmapData.dispose() on BitmapData instances 
we the code is done 
with them, to ensure that the memory for them is reclaimed.

Original issue reported on code.google.com by mikechambers on 22 Jun 2009 at 6:12

GoogleCodeExporter commented 9 years ago
Couldn't hurt!  I didn't see a need since the three BitmapData objects in use 
are 
reinstantiated each time a collision is checked, but like you said, it's 
probably a 
good idea if just for piece of mind.  I'll have it in the next release.

Original comment by lessthan...@gmail.com on 22 Jun 2009 at 7:52

GoogleCodeExporter commented 9 years ago
When the collision detection is fully done, can you also null the properties 
bmd1 and
bmd2 in the CDK class? Or better, null everything that is not needed anymore to 
free
up memory.

Original comment by e.verd...@gmail.com on 24 Jun 2009 at 5:34