mirror of
https://github.com/love2d/love.git
synced 2026-08-16 00:02:12 +02:00
Fix a Font texture memory leak when love.window.setMode is called (resolves issue #1338).
--HG-- branch : minor
This commit is contained in:
@@ -122,6 +122,8 @@ Font::TextureSize Font::getNextTextureSize() const
|
||||
bool Font::loadVolatile()
|
||||
{
|
||||
textureCacheID++;
|
||||
glyphs.clear();
|
||||
images.clear();
|
||||
createTexture();
|
||||
return true;
|
||||
}
|
||||
@@ -183,6 +185,8 @@ void Font::createTexture()
|
||||
|
||||
void Font::unloadVolatile()
|
||||
{
|
||||
glyphs.clear();
|
||||
images.clear();
|
||||
}
|
||||
|
||||
love::font::GlyphData *Font::getRasterizerGlyphData(uint32 glyph)
|
||||
|
||||
Reference in New Issue
Block a user