Files
shadowcrest/src/game/systems/FontManager.hpp
2025-07-14 23:44:36 +02:00

15 lines
384 B
C++

#pragma once
#include <string>
#include <unordered_map>
#include <vector>
#include "stb_truetype.h"
class FontManager {
public:
bool LoadFont(const std::string& id, const std::string& path);
stbtt_fontinfo* GetFont(const std::string& id);
private:
std::unordered_map<std::string, std::vector<unsigned char>> fontBuffers;
std::unordered_map<std::string, stbtt_fontinfo> fonts;
};