#include <textrenderer.hpp>
|
| | TextRenderer () |
| |
| | TextRenderer (const std::string &font_path, float glyph_size, bool fixed) |
| |
| | TextRenderer (const std::string &font_path, float glyph_size, bool fixed, uint32_t id) |
| |
| | ~TextRenderer () |
| |
| void | DrawText (const std::string &text, float x, float y, float scale, int layer, Vec3 color) |
| |
| void | _DrawText (const std::string &text, float x, float y, float scale, Vec3 color) |
| |
| std::pair< float, float > | GetTextSize (std::string text, float scale) |
| |
| void | UpdateProjMat (glm::mat4 &proj) |
| |
Definition at line 14 of file textrenderer.hpp.
◆ TextRenderer() [1/3]
| TextRenderer::TextRenderer |
( |
| ) |
|
|
inline |
◆ TextRenderer() [2/3]
| TextRenderer::TextRenderer |
( |
const std::string & | font_path, |
|
|
float | glyph_size, |
|
|
bool | fixed ) |
- Parameters
-
| fixed | false if its position should be relative to the camera |
Definition at line 6 of file textrenderer.cpp.
◆ TextRenderer() [3/3]
| TextRenderer::TextRenderer |
( |
const std::string & | font_path, |
|
|
float | glyph_size, |
|
|
bool | fixed, |
|
|
uint32_t | id ) |
- Parameters
-
| fixed | false if its position should be relative to the camera |
Definition at line 24 of file textrenderer.cpp.
◆ ~TextRenderer()
| TextRenderer::~TextRenderer |
( |
| ) |
|
◆ _DrawText()
| void TextRenderer::_DrawText |
( |
const std::string & | text, |
|
|
float | x, |
|
|
float | y, |
|
|
float | scale, |
|
|
Vec3 | color ) |
Istantaneously draw the text. Coordinates are expected in engine units (screen width = 10 units)
- Parameters
-
| text | a string containing the text |
| x | the x position of the text |
| y | the y position of the text |
| scale | the scale of the text |
| color | the color of the text |
Definition at line 61 of file textrenderer.cpp.
◆ DrawText()
| void TextRenderer::DrawText |
( |
const std::string & | text, |
|
|
float | x, |
|
|
float | y, |
|
|
float | scale, |
|
|
int | layer, |
|
|
Vec3 | color ) |
Draw the text. Coordinates are expected in engine units (screen width = 10 units)
- Parameters
-
| text | a string containing the text |
| x | the x position of the text |
| y | the y position of the text |
| scale | the scale of the text |
| color | the color of the text |
Definition at line 51 of file textrenderer.cpp.
◆ GetTextSize()
| std::pair< float, float > TextRenderer::GetTextSize |
( |
std::string | text, |
|
|
float | scale ) |
Get the size of the text.
- Parameters
-
| text | a string containing the text |
| scale | the scale of the text |
Definition at line 103 of file textrenderer.cpp.
◆ UpdateProjMat()
| void TextRenderer::UpdateProjMat |
( |
glm::mat4 & | proj | ) |
|
|
inline |
◆ FontManager
◆ SceneSerializer
◆ m_Fixed
| bool TextRenderer::m_Fixed |
◆ m_FontPath
| std::string TextRenderer::m_FontPath |
◆ m_GlyphSize
| float TextRenderer::m_GlyphSize |
◆ m_ID
| uint32_t TextRenderer::m_ID |
The documentation for this class was generated from the following files: