Note: Font SOP deprecated build 2019.14650, use Text TOP.
The Font SOP allows you to create text in your model from Adobe Type 1 Postscript Fonts.
To install fonts, copy the font files to the
$TFS/touch/fonts directory of your installation path. They will be ready to be used in the Font SOP after restarting TouchDesigner.
The fonts located in
$TFS/touch/fonts_gl are not for the Font SOP, they are for the TouchDesigner UI only.
Parameters - Page
type - ⊞ - Select from the following types. For information on the different types, see the Geometry Types section. Bzier Curves and Polygons provide the most efficient use of memory, because they use polygons for letters containing straight segments, and Bzier curves for all others.
Note: Due to an Open GL bug, holes in Bzier fonts may shade incorrectly.
- Bezier Curves and Polygons
- Beziers Only
- Polygons Only
file - Choose the font to create the text. By clicking on the + button a File Dialog will appear, and clicking menu drop down brings up a menu of the most used fonts.
text - Enter the text you want to generate here.
Your text can contain the following special characters:
\- Take the next character literally (so you can use the / and ` characters in your text);
`string`- Evaluate the string contained by the backquotes (above the T key) as an expression;
\n- Start a new line;
\xxx- Specify a character by it's ascii code (e.g. \007).
For Example: If you put something like
\\$F3 in the text string, you should see all the possible characters of a font as you play the animation (set the last frame to 256).
Entering Expressions as Text - You can also use expressions for the text.
me.time.frame - will display the current frame.
op('null1')['chan1'] - will display the current value of channel chan1 in CHOP
'hello world'[int(me.time.frame)%11] - causes the eleven letters of the text to appear in succession during the first eleven frames.
Other Methods of Entering Text - You can use the
\xxx decimal notation to specify characters. The available characters will depend on the font type used.
For Example: \065 - will display '
op('font1').par.text = 'hello world' - will display the words: hello world
Center Text Horizontally
hcenter - This check box allows you to center the text horizontally about X = 0.
Center Text Vertically
vcenter - This check box allows you to center the text vertically about Y = 0.
t - ⊞ - Translates the geometry in x, y and z.
s - ⊞ - Scales the text in the X and Y axis.
kern - ⊞ - Letter spacing in the X direction. Line spacing in the Y direction if there are multiple lines. If you need manual character-by-character, you can do it in Model mode.
italic - Doesn't actually give an italic version of the font, but rather obliques the text by shearing it the specified number of degrees. A negative number makes the text slant to the left.
Level of Detail
lod - Adobe fonts are defined by Bzier curves. If polygons only is selected, the Font SOP converts these to polygons. This value adjusts the number of points in the polygons that it gets converted to.
hole - Generates holes in polygons and Bzier faces.
texture - ⊞ - This adds uv coordinates to the geometry created by the Font SOP.
off- No uv coordinates added.
ortho- Orthographic uv coordinates added.