purgeGlyphs() → {integer}
If a BitmapText changes from having a large number of characters to having very few characters it will cause lots of
Sprites to be retained in the BitmapText._glyphs array. Although they are not attached to the display list they
still take up memory while sat in the glyphs pool waiting to be re-used in the future.
If you know that the BitmapText will not grow any larger then you can purge out the excess glyphs from the pool
by calling this method.
Calling this doesn't prevent you from increasing the length of the text again in the future.
Returns
integer -
The amount of glyphs removed from the pool.
- Source code: gameobjects/BitmapText.js (Line 477)
Please login to continue.