Character

* Holds information about a certain glyph in the font texture atlas. * All sizes are defined for a font-size of 1 point.

Constructors

this
this(int id, Vector2F texCoords, Vector2F texSize, Vector2F offset, Vector2F size, Vector2F advance)

* id: * - stores the ASCII value of the character. * texCoords: * - x: stores the texture x-coordinate for the top left corner of the character in texture atlas. * - y: stores the texture y-coordinate for the top left corner of the character in texture atlas. * texSize: * - x: stores the width of the character in the texture atlas. * - y: stores the height of the character in the texture atlas. * offset: * - x: stores the x distance from the curser to the left edge of the character's quad. * - y: stores the y distance from the curser to the top edge of the character's quad. * size: * - x: stores the width of the character's quad in screen space. * - y: stores the height of the character's quad in screen space. * advance: * - x: stores how far in pixels the cursor should advance after adding this character on x-axis. * - y: stores how far in pixels the cursor should advance after adding this character on y-axis.

Members

Functions

getASCIIValue
int getASCIIValue()

* Returns the ASCII value of the character.

getAdvance
Vector2F getAdvance()

* Returns how far in pixels the cursor should advance after adding this character.

getMaxTexCoords
Vector2F getMaxTexCoords()

* Returns the character maximum texture coordinates.

getOffset
Vector2F getOffset()

* Returns the character offset.

getSize
Vector2F getSize()

* Returns the dimension of the character's quad in screen space.

getTexCoords
Vector2F getTexCoords()

* Returns the character texture coordinates.

Meta