23 int initialize(
unsigned char* fontData,
int firstChar);
40 static unsigned int heightText(
float scale,
unsigned int maxWidth, std::string s);
42 static void drawText(
unsigned int x,
unsigned int y,
float scale,
43 glm::vec4 color, std::string s);
44 static void drawTextWrapped(
unsigned int x,
unsigned int y,
float scale,
45 glm::vec4 color,
unsigned int maxWidth, std::string s);
51 glm::vec4 color,
unsigned int maxWidth, std::string s,
55 static std::vector<FontMapTTF>
maps;
static int initialize(std::string f)
OpenGL Shader Implementation.
static unsigned int widthText(float scale, std::string s)
static std::vector< FontMapTTF > maps
static unsigned char * fontData
static void drawTextWrapped(unsigned int x, unsigned int y, float scale, glm::vec4 color, unsigned int maxWidth, std::string s)
static ShaderBuffer uvBuffer
static unsigned int heightText(float scale, unsigned int maxWidth, std::string s)
int initialize(unsigned char *fontData, int firstChar)
void getQuad(int c, float *xpos, float *ypos, stbtt_aligned_quad *quad)
static ShaderBuffer vertexBuffer
stbtt_packedchar * charInfo
static void drawTextInternal(unsigned int x, unsigned int y, float scale, glm::vec4 color, unsigned int maxWidth, std::string s, bool drawWrapped)
static int charIsMapped(int c)
static void drawText(unsigned int x, unsigned int y, float scale, glm::vec4 color, std::string s)
static int getQuad(int c, float *xpos, float *ypos, stbtt_aligned_quad *quad)