From e25d5383555a8cbc6e435823aca2bb4a78312c2e Mon Sep 17 00:00:00 2001 From: John O'Neil Date: Thu, 21 Mar 2024 11:35:15 -0700 Subject: [PATCH] Bug #145421 Fix glyph padding in STB atlas impl. Fixes incorrect glyph padding in the STB based Glyph Atlas. --- impeller/typographer/backends/stb/typographer_context_stb.cc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/impeller/typographer/backends/stb/typographer_context_stb.cc b/impeller/typographer/backends/stb/typographer_context_stb.cc index 6c5bcad667483..ffcda770277bf 100644 --- a/impeller/typographer/backends/stb/typographer_context_stb.cc +++ b/impeller/typographer/backends/stb/typographer_context_stb.cc @@ -220,8 +220,7 @@ static void DrawGlyph(BitmapSTB* bitmap, // Glyph in place if (!has_color || DISABLE_COLOR_FONT_SUPPORT) { stbtt_MakeGlyphBitmap(typeface_stb->GetFontInfo(), output, - location.GetWidth() - kPadding, - location.GetHeight() - kPadding, + location.GetWidth(), location.GetHeight(), bitmap->GetRowBytes(), scale_x, scale_y, glyph.index); } else { // But for color bitmaps we need to get the glyph pixels and then carry all