|
| | gFont () |
| |
| virtual | ~gFont () |
| |
| bool | load (const std::string &fullPath, int size, bool isAntialiased=true, int dpi=96) |
| |
| bool | loadFont (const std::string &fontPath, int size, bool isAntialiased=true, int dpi=96) |
| |
| void | drawText (const std::string &text, float x, float y) |
| |
| void | drawTextVerticallyFlipped (const std::string &text, float x, float y) |
| | Draws the given text vertically flipped at the specified position.
|
| |
| void | drawTextHorizontallyFlipped (const std::string &text, float x, float y) |
| | Draws the given text horizontally flipped at the specified location.
|
| |
| float | getStringWidth (const std::string &text) |
| |
| float | getStringHeight (const std::string &text) |
| |
| float | getLineHeight () const |
| |
| const std::string & | getPath () const |
| |
| int | getSize () const |
| |
| bool | isLoaded () const |
| |
| bool | isAntialised () const |
| |
| int | getDpi () const |
| |
| std::vector< std::string > | wrapSentenceByWidth (const std::string &text, float maxWidth, TextAlign align=TextAlign::LEFT) |
| |
| void | onEvent (gEvent &event) override |
| |
| | gNode () |
| |
| virtual | ~gNode () |
| |
| void | move (float dx, float dy, float dz) |
| |
| void | move (const glm::vec3 &dv) |
| |
| void | rotate (const glm::quat &q) |
| |
| void | rotate (float radians, float ax, float ay, float az) |
| |
| void | rotateDeg (float degrees, float ax, float ay, float az) |
| |
| void | rotateAround (float radians, const glm::vec3 &axis, const glm::vec3 &point) |
| |
| void | rotateAroundDeg (float degrees, const glm::vec3 &axis, const glm::vec3 &point) |
| |
| void | scale (float sx, float sy, float sz) |
| |
| void | scale (float s) |
| |
| void | setPosition (float px, float py, float pz) |
| |
| void | setPosition (const glm::vec3 &pv) |
| |
| void | setOrientation (const glm::quat &o) |
| |
| void | setOrientation (const glm::vec3 &angles) |
| |
| void | setScale (const glm::vec3 &s) |
| |
| void | setScale (float sx, float sy, float sz) |
| |
| void | setScale (float s) |
| |
| void | truck (float distance) |
| |
| void | boom (float distance) |
| |
| void | dolly (float distance) |
| |
| void | tilt (float radians) |
| |
| void | tiltDeg (float degrees) |
| |
| void | pan (float radians) |
| |
| void | panDeg (float degrees) |
| |
| void | roll (float radians) |
| |
| void | rollDeg (float degrees) |
| |
| float | getPosX () const |
| |
| float | getPosY () const |
| |
| float | getPosZ () const |
| |
| const glm::vec3 & | getPosition () const |
| |
| const glm::quat & | getOrientation () const |
| |
| const glm::vec3 & | getScale () const |
| |
| glm::vec3 | getScalarDirectionX () const |
| |
| glm::vec3 | getScalarDirectionY () const |
| |
| glm::vec3 | getScalarDirectionZ () const |
| |
| void | setTransformationMatrix (const glm::mat4 &transformationMatrix) |
| |
| const glm::mat4 & | getTransformationMatrix () const |
| |
| int | getId () const |
| |
| void | setParent (gNode *parent) |
| |
| gNode * | getParent () const |
| |
| void | removeParent () |
| |
| void | addChild (gNode *child) |
| |
| void | removeChild (gNode *child) |
| |
| void | removeChild (int gObjectId) |
| |
| void | setEnabled (bool isEnabled) |
| |
| bool | isEnabled () const |
| |
| void | pushMatrix () const |
| |
| void | popMatrix () const |
| |
| | gRenderObject () |
| |
| int | getScreenWidth () |
| |
| int | getScreenHeight () |
| |
| void | pushMatrix () |
| |
| void | popMatrix () |
| |
| | gObject () |
| |
| void | logi (std::string message) |
| |
| void | logd (std::string message) |
| |
| void | logw (std::string message) |
| |
| void | loge (std::string message) |
| |
| void | logi (std::string tag, std::string message) |
| |
| void | logd (std::string tag, std::string message) |
| |
| void | logw (std::string tag, std::string message) |
| |
| void | loge (std::string tag, std::string message) |
| |
| | gEventHook () |
| |
| virtual | ~gEventHook () |
| |
| bool gFont::load |
( |
const std::string & |
fullPath, |
|
|
int |
size, |
|
|
bool |
isAntialiased = true, |
|
|
int |
dpi = 96 |
|
) |
| |
Loads a font from the given fullPath
Developers could use this function for loading font and giving text's features.
Developers do not need to enter the isAntialiased and the dpi values because those values are given automatically.
Font files may be stored anywhere on the drives.
- Parameters
-
| std::string | fullPath The full path to the font file. It should contain the full path of the folder where the font is located. |
| int | size - The size of the font |
| bool | isAntialised - This is used in digital imaging to reduce visual imperfections and developers don't need to give value. |
| int | dpi - The measure of resolution used for printed text or images and developers don't need to give value |
- Returns
- boolean indicating if font is loaded
| bool gFont::loadFont |
( |
const std::string & |
fontPath, |
|
|
int |
size, |
|
|
bool |
isAntialiased = true, |
|
|
int |
dpi = 96 |
|
) |
| |
Loads a font from the given fontPath
Developers could use this function for loading font and giving text's features.
Developers do not need to enter the isAntialiased and the dpi values because those values are given automatically.
Font files should be stored in the GlistEngine's assets/fonts folder.
- Parameters
-
| std::string | fontPath - The font path to the font file. It should contain the font path of the folder where the font is located. |
| int | size - This is the size of the font. Developers are recommended to use 6 and its multiples. |
| bool | isAntialised - This is used in digital imaging to reduce visual imperfections and developers don't need to give value. |
| int | dpi - This is a measure of resolution used for printed text or images and developers don't need to give value |
- Returns
- boolean indicating if font is loaded