Files
ppsspp/Common/Render/Text
Henrik RydgårdandClaude Opus 5.5 02b688e4f3 TextDrawer: Cache wrapped text, hash the string caches
MeasureString was slow mostly because of wrapping: DrawStringRect and
MeasureStringRect re-ran the word wrapper every frame, and it measures
every prefix of every word. Wrapped strings are now cached. The caches
are unordered_maps with an xxhash of the key, and lookups reuse a key
buffer so a hit doesn't allocate. UIContext also skips switching fonts
when measuring in the current style. In a Mac debug build, 200 cached
measures go from 0.26 to 0.06 ms and 10 wrapped paragraphs from 2.1 to
0.01 ms per frame.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-22 10:11:42 +02:00
..
2026-06-16 11:39:24 +02:00
2026-08-08 18:18:28 +02:00
2026-08-08 18:18:28 +02:00
2026-08-08 18:18:28 +02:00