From c10e0d92f46e5eaf25a69e1fafe5f4dbd8eaab9d Mon Sep 17 00:00:00 2001 From: chai Date: Wed, 3 Nov 2021 09:52:26 +0800 Subject: *misc --- Runtime/GUI/Font.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'Runtime/GUI/Font.cpp') diff --git a/Runtime/GUI/Font.cpp b/Runtime/GUI/Font.cpp index 8cdfdf3..614792a 100644 --- a/Runtime/GUI/Font.cpp +++ b/Runtime/GUI/Font.cpp @@ -146,8 +146,8 @@ void Font::RenderCharacter(character::Codepoint codepoint, int pixelSize) int w = m_FTFace->glyph->bitmap.width; int h = m_FTFace->glyph->bitmap.rows; - - //TextHelper::print_glyph(m_FTFace->glyph->bitmap.buffer, w, h); + + TextHelper::print_glyph(m_FTFace->glyph->bitmap.buffer, w, h); GlyphAtals* atlas = RequestAtlas(pixelSize, Internal::Vector2(w, h)); Assert(atlas); @@ -173,6 +173,9 @@ void Font::RenderCharacter(character::Codepoint codepoint, int pixelSize) character.advance = m_FTFace->glyph->advance.x * 1/64.f; m_Characters.insert(std::pair(hash, character)); +/* + FT_Done_Face(m_FTFace); + FT_Done_FreeType(m_FTLibrary);*/ } const GlyphAtals* Font::GetGlyphAtlas(int index) -- cgit v1.1-26-g67d0