From 689f468e368adb7ab378570b26051d4658c2585b Mon Sep 17 00:00:00 2001 From: Radek Dutkiewicz Date: Sat, 9 Mar 2019 03:54:45 +0000 Subject: [PATCH] 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. --- src/SFML/Graphics/Text.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/SFML/Graphics/Text.cpp b/src/SFML/Graphics/Text.cpp index 7cb4f889b..45172c872 100644 --- a/src/SFML/Graphics/Text.cpp +++ b/src/SFML/Graphics/Text.cpp @@ -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;