Text SOP

From TouchDesigner 088 Wiki


The Text SOP creates text geometry from any TrueType font that is installed on the system, or any TrueType font file on disk. Unicode is supported.

See also the Text TOP and Unicode.

PythonIcon.png textSOP_Class

Parameters - Text Page

Font font - Select the font for the text from this drop down menu. All fonts are provided by Windows, any TrueType font that is loaded into Windows can be used.

Font File fontfile - Specify any TrueType font file (.ttf file) to use for the text. When using a font file, the Font menu above is disabled.

Bold bold - Displays the text in bold.

Italic italic - Displays the text in Italic.

Font Size X, Y fontsizex fontsizey - Sets the font size in X (horizontal) and Y (vertical).

Keep Font Ratio keepfontratio - Ignores Y value in Font Size. Sets both X and Y size to Font Size X.

Language language - Language type hint to help format the glyphs correctly. This should be a abbreviation from the Text TOP/SOP Unicode Language Abbreviations table.

Reading Direction readingdirection - Use to set whether the language reads Left to Right or Right to Left.

Kerning kerningx kerningy - The amount of space to add between letters in X and Y. Kerning is way of adding an arbitrary offset between letters. There already is a default offset associated with each font so the letters are flush against each other. The Kerning parameter this adds to that and allows for a Y offset.

Line Spacing - Determines the amount of space between lines of text.

Horizontal Align alignx - Sets the horizontal alignment.

  • Left - Left justifies the text.
  • Center - Centers the text.
  • Right - Right justifies the text.

Word Wrap wordwrap - When checked text is automatically line wrapped once it takes up the space set in Word Wrap Size parameter below.

Word Wrap Size wordwrapsize - Determines the amount of 3D space used before the line wraps.

Text text - the string of text to create as geometry. You can use \n and \t, but see Legacy Parsing parameter.

Legacy Parsing legacyparsing - When enabled and if the Text parameter is in Constant Mode, \t and \n character sequences will be turned into tab and newline characters respectively. Otherwise the \t and \n sequences will be left as literal \ and t and \ and n.

Parameters - Transform Page

Transform Order xord - Sets the overall transform order for the transformations. The transform order determines the order in which transformations take place. Depending on the order, you can achieve different results using the exact same values. Choose the appropriate order from the menu.

Rotate Order rord - Sets the order of the rotations within the overall transform order.

Translate tx ty tz - These three fields move the geometry in the three axes.

Rotate rx ry rz - These three fields rotate the geometry in the three axes.

Scale sx sy sz - These three fields scale the geometry in the three axes.

Pivot px py pz - The pivot point for the transformations (not the same as the pivot point in the pivot channels). The pivot point parameters allow you to define the point about which geometry scales and rotates. Altering the pivot point produces different results depending on the transformation performed on the object.

For example, during a scaling operation, if the pivot point of an object is located at: -1, -1, 0 and you wanted to scale the object by 0.5 (reduce its size by 50%) the object would scale toward the pivot point and appear to slide down and to the left.

See Also