Module OpenGL
Lua OpenGL API
See also:
Text
Draw Basics
Text
gl.Text(text, x, y, size[, options])
Parameters:
-
text
string -
x
number -
y
number -
size
number -
options
stringconcatenated string of option characters.
- horizontal alignment:
- 'c' = center
- 'r' = right
- vertical alignment:
- 'a' = ascender
- 't' = top
- 'v' = vertical center
- 'x' = baseline
- 'b' = bottom
- 'd' = descender
- decorations:
- 'o' = black outline
- 'O' = white outline
- 's' = shadow
- other:
- 'n' = don't round vertex coords to nearest integer (font may get blurry)
- horizontal alignment:
Returns:
- nil
Draw Basics
gl.Color(r[, g[, b[, a]]])
Parameters:
-
r
number or {number,number,number,number} red when number, rgba quadruple or rgb triple otherwise -
g
number (optional) -
b
number (optional) -
a
number (optional)
Returns:
- nil