FreeType: LCD subpixel

This commit is contained in:
rtw1x1
2026-02-04 12:30:14 +00:00
parent ba514d2e9a
commit 87cfa1540f
4 changed files with 72 additions and 21 deletions

View File

@@ -1,6 +1,10 @@
#include "StdAfx.h"
#include "FontManager.h"
#include <ft2build.h>
#include FT_FREETYPE_H
#include FT_LCD_FILTER_H
#include <algorithm>
#include <cctype>
#include <sys/stat.h>
@@ -54,6 +58,9 @@ bool CFontManager::Initialize()
m_bInitialized = true;
// Enable LCD subpixel filter to reduce color fringing
FT_Library_SetLcdFilter(m_ftLibrary, FT_LCD_FILTER_DEFAULT);
// Register default font name -> file mappings
// Korean system fonts
m_fontPathMap["gulim"] = "gulim.ttc";