SecondHalfGames / yakui

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

Should all vertices be rounded to the nearest pixel? #153

Open LPGhatguy opened 2 months ago

LPGhatguy commented 2 months ago

In #151, yakui started rounding the positions of vertices in the text pipeline to the nearest physical pixel. This fixed our longtime blurry text issue, but we were only able to apply it to text because it caused new artifacts in some other geometry.

I think it's possible that the math I wrote for rounded rectangles is actually what's at fault here. It's possible that we can fix that (or throw it away in favor of something like lyon's version of the same code) and start rounding all vertices to the nearest physical pixel.