Update fallback glyph handling

This commit is contained in:
Georg Hagen
2025-01-04 01:52:41 +01:00
parent f124a22910
commit f156ff5892
2 changed files with 25 additions and 19 deletions

View File

@@ -34,6 +34,16 @@ namespace OpenVulkano::Scene
{
static Shader DEFAULT_SHADER_BITMAP, DEFAULT_SHADER_SDF, DEFAULT_SHADER_MSDF;
Geometry m_geometry;
Material m_material;
UniformBuffer m_uniBuffer;
std::shared_ptr<AtlasData> m_atlasData;
Math::AABB m_bbox;
std::string m_text;
TextConfig m_cfg;
uint32_t GetFallbackGlyph() const;
public:
[[nodiscard]] static Shader& GetSdfDefaultShader() { return DEFAULT_SHADER_SDF; }
[[nodiscard]] static Shader& GetMsdfDefaultShader() { return DEFAULT_SHADER_MSDF; }
@@ -51,14 +61,5 @@ namespace OpenVulkano::Scene
[[nodiscard]] TextConfig& GetConfig() { return m_cfg; }
[[nodiscard]] const std::string& GetText() const { return m_text; }
[[nodiscard]] const std::shared_ptr<AtlasData> GetAtlasData() { return m_atlasData; }
private:
Geometry m_geometry;
Material m_material;
UniformBuffer m_uniBuffer;
std::shared_ptr<AtlasData> m_atlasData;
Math::AABB m_bbox;
std::string m_text;
TextConfig m_cfg;
};
}