Text component
Contents:
For complete demos and tests of these features,
see the text subdirectory inside our VRML/X3D demo models.
Text,
FontStyle
Most important properties
(size, spacing, justify, family, style) are handled fully.
TODO: But some properties are ignored for now:
- FontStyle properties: From section
6.22.3 Direction and justification
horizontal, leftToRight, topToBottom fields are ignored
(and things are always handled like they had default values
TRUE, TRUE, TRUE). From section 6.22.4 Language
language field is ignored.
- Text: length, maxExtent are
ignored (and handled like they had
default values, which means that the text is not stretched).
Text is "clickable" within
Anchor and TouchSensor nodes.
Although I didn't find any mention in the specifications that I should
do this, many VRML models seem to assume this.
We make an ultra-simple triangulation of the text
(just taking 2 triangles to cover whole text, you don't want
to produce real triangles for text node, as text node would have
a lot of triangles!).
TODO: unfortunately, for now these triangles also participate
in collision detection, while spec says that text shouldn't collide.
TODO: Text and Text3D are rendered
without vertex arrays and vertex buffers (they may be slower than normal
nodes), and they don't support multi-texturing yet.
This also means that bump mapping doesn't work on them,
and that they cannot be used as shadow maps receivers.
|