jit.gl.text3d Write vector text

The jit.gl.text3d object requires one argument: the name of a drawing context. A named drawing context is a named instance of a jit.window, jit.pwindow, or jit.matrix object that has an instance of the jit.gl.render object associated with it. This value may also be set via the OB3D drawto attribute.

The jit.gl.text3d object lets you draw 3D text in the named drawing context. According to the OB3D attributes, the text can be drawn solid or wireframe, with different colors and textures, etc. The text which is drawn can be sent as a symbol, a list of symbols, or as a jit.matrix containing char data. When a jit.matrix is used to send the text, each row of the matrix is interpreted as one line of text.

Because jit.gl.text3d creates GL geometry by reading the TrueType glyphs directly, only fonts which are stored explicitly in the TrueType format will draw. Attempting to read Type1 fonts and bitmap fonts will generate an error.

Notes:

Setting the depth attribute and sending the methods font and face each cause the font to be rebuilt from the TrueType outlines, which is a slow operation, on the order of a second.

Only True Type outline fonts are supported

GL Group

Attributes:
Name Type Description
align int Text alignment mode (default = 0 (left))
0 = left
1 = center
2 = right
depth float The depth (z extent) of the 3D geometry relative to the height of the font (default = 0.) If a depth of 0 is used, no extruded character sides are generated, which will draw much faster.
leadscale float The leading between multiple rows of text as a multiple of the standard leading. (default = 1.)
plane int The plane of a multi-plane char input matrix which will be interpreted as text. (default = 0)
tracking float The tracking (intra-character spacing) as a multiple of the standard tracking for the face. (default = 1.)

Messages:
append [text-to-append (list)]
Appends the specified symbol or list to the stored text string.

face [face-variant (list)]
Specifies the face variant of the current font. One or more face variants may be specified. The Supported font faces are normal, bold, italic, underline, outline, shadow, condense, and extend.

font [fontname (symbol)] [size (int)]
Specifies the font and size in which to draw.

jit_matrix [matrix-name (symbol)]
Replace the current text string with the contents of the jit.matrix containing char data. The data are interpreted as ASCII text.

text [text (list)]
Replace the current text string with a symbol or list of symbols.

Example:

See Also:
jit.gl.graph, jit.gl.gridshape, jit.gl.handle, jit.gl.isosurf, jit.gl.mesh, jit.gl.isosurf, jit.gl.mesh, jit.gl.model, jit.gl.nurbs, jit.gl.plato, jit.gl.render, jit.gl.shader, jit.gl.sketch, jit.gl.slab, jit.gl.text2d, jit.gl.texture, jit.gl.videoplane, jit.gl.volume