
#ifndef SPECTRE_GRAPHICS_FONT_ENGINE_FREETYPEENGINE_H
#define SPECTRE_GRAPHICS_FONT_ENGINE_FREETYPEENGINE_H

#include <ft2build.h>
#include FT_FREETYPE_H

#include <string>
#include <Spectre/Graphics/Font/FontDescription.h>
#include "FontEngine.h"

namespace sp {

class FreeTypeEngine : public FontEngine
{
public:
	FreeTypeEngine(FontDescription desc = FontDescription());
	~FreeTypeEngine();

	virtual bool setCharacterSize(unsigned int size);

	virtual bool loadFromFile(const std::string& filename);

	virtual Glyph loadGlyph(unsigned int codepoint, Image& img, unsigned int outlineSize = 0);

	virtual std::string getName();

private :

	FT_Face m_face;
	FontDescription m_desc;
};

} // namespace sp

#endif /* SPECTRE_GRAPHICS_FONT_ENGINE_FREETYPEENGINE_H */
