Version: Unity 6.1 Alpha (6000.1)
Language : English
Create meshes for text strings
Mesh components reference

Text Mesh component reference

Switch to Scripting

The Text MeshThe main graphics primitive of Unity. Meshes make up a large part of your 3D worlds. Unity supports triangulated or Quadrangulated polygon meshes. Nurbs, Nurms, Subdiv surfaces must be converted to polygons. More info
See in Glossary
component generates 3D geometry that displays text strings.

Note: The Text Mesh component has limited functionality. For information on more recent, full-featured ways of displaying text, see Creating user interfaces (UI).

To create a new Text Mesh, go to Component > Mesh > Text Mesh.

Text Mesh properties

Property: Function:
Text The text that will be rendered
Offset Z How far should the text be offset from the transform.position.z when drawing
Character Size The size of each character (This scales the whole text.)
Line Spacing How much space will be in-between lines of text.
Anchor Which point of the text shares the position of the Transform.
Alignment How lines of text are aligned (Left, Right, Center).
Tab Size How much space will be inserted for a tab ‘\t’ character. This is a multiplum of the ‘spacebar’ character offset.
Font Size The size of the font. This can override the size of a dynamic font.
Font Style The rendering style of the font. The font needs to be marked as dynamic.
Rich Text When selected this will enable tag processing when the text is rendered.
Font The TrueType Font to use when rendering the text.
Color The global color to use when rendering the text.

TextMesh


对文档有任何疑问,请移步至开发者社区提问,我们将尽快为您解答
Create meshes for text strings
Mesh components reference
Copyright © 2023 Unity Technologies
优美缔软件(上海)有限公司 版权所有
"Unity"、Unity 徽标及其他 Unity 商标是 Unity Technologies 或其附属机构在美国及其他地区的商标或注册商标。其他名称或品牌是其各自所有者的商标。
公安部备案号:
31010902002961