SecondHalfGames / yakui

yakui is a declarative Rust UI library for games
Apache License 2.0
228 stars 19 forks source link

Improve Text Rendering Under Non-Integer Scaling #1

Open LPGhatguy opened 2 years ago

LPGhatguy commented 2 years ago

Text looks funny under 1.25x scaling.

ApplicationFrameHost_e5smdAD4e8

sapir commented 2 years ago

I think that what's happening is that fontdue is already rounding the glyph positions. e.g. The documentation for GlyphPosition.x says that it's always a whole number. Then when you scale it up, the rounding error is multiplied.

LPGhatguy commented 2 years ago

502b67f946764a555325f4d61361ba84578fb38d was a minor improvement here based on your comment on #36.