MCPcopy Create free account
hub / github.com/OpenTTD/OpenTTD / GfxClearFontSpriteCache

Function GfxClearFontSpriteCache

src/spritecache.cpp:925–931  ·  view source on GitHub ↗

* Remove all encoded font sprites from the sprite cache without * discarding sprite location information. */

Source from the content-addressed store, hash-verified

923 * discarding sprite location information.
924 */
925void GfxClearFontSpriteCache()
926{
927 /* Clear sprite ptr for all cached font items */
928 for (SpriteCache &sc : _spritecache) {
929 if (sc.type == SpriteType::Font && sc.ptr != nullptr) sc.ClearSpriteData();
930 }
931}
932
933/* static */ SpriteCollMap<ReusableBuffer<SpriteLoader::CommonPixel>> SpriteLoader::Sprite::buffer;

Callers 1

AdjustGUIZoomFunction · 0.85

Calls 1

ClearSpriteDataMethod · 0.80

Tested by

no test coverage detected