Fixed text rendering artifacts on Radeon cards.

Padding set to 1.0 was causing adjacent glyphs leaking on Radeon cards. The initial padding value for glyphs was too high anyway, the proper value should be 0.5 on each side.
This commit is contained in:
Radek Dutkiewicz 2019-03-09 03:54:45 +00:00 committed by Lukas Dürrenberger
parent 6272f853c1
commit 689f468e36

View File

@ -50,7 +50,7 @@ namespace
// Add a glyph quad to the vertex array
void addGlyphQuad(sf::VertexArray& vertices, sf::Vector2f position, const sf::Color& color, const sf::Glyph& glyph, float italicShear, float outlineThickness = 0)
{
float padding = 1.0;
float padding = 0.5;
float left = glyph.bounds.left - padding;
float top = glyph.bounds.top - padding;