some more refactoring and improvements

This commit is contained in:
ohyzha
2024-12-31 10:13:36 +02:00
parent 84221f3e2b
commit 8d389db50c
5 changed files with 61 additions and 46 deletions

View File

@@ -80,14 +80,9 @@ namespace OpenVulkano
}
#if defined(MSDFGEN_AVAILABLE) && CREATE_NEW_ATLAS
std::set<uint32_t> s = SdfFontAtlasGenerator::LoadAllGlyphs(fontPath);
msdf_atlas::Charset charset;
for (uint32_t c : s)
{
charset.add(c);
}
m_atlasGenerator.GenerateAtlas(fontPath, charset);
m_msdfAtlasGenerator.GenerateAtlas(fontPath, charset);
std::set<uint32_t> s = SdfFontAtlasGeneratorT::LoadAllGlyphs(fontPath);
m_atlasGenerator.GenerateAtlas(fontPath, s);
m_msdfAtlasGenerator.GenerateAtlas(fontPath, s);
m_atlasGenerator.SaveAtlasMetadataInfo("sdf_atlas.png");
m_msdfAtlasGenerator.SaveAtlasMetadataInfo("msdf_atlas");
#else