Hi,

The Java3D tutorial bundle has an example called TexturedText3DApp.java
under the subdir texture/, which depicts 2D texturing on a rotating
Text3D.

On Text2D being a Shape3D rather than a geometry, my opinion ($0.02)
is that it would have been more convenient if Text2D were indeed
a Geometry. For one thing, the last time I examined the code,
it creates an appearance for each instance of Text2D, and you may also
need a TransformGroup to position the label if you don't want to expend
much effort. But to be fair, the Text2D was probably conceived to be an
all-in-one ready-made object for the general convenience of everyone. If
you needed the geometry, an option (kinda inefficient) may be to try to
grab it from the Shape3D.

On multi-line labels, just thinking aloud, would html-ized strings
work ( works for buttons and such I think ) ?

Rgds

Raj


>On Sun, 17 Mar 2002 18:04:02 +1100, Justin Couch <[EMAIL PROTECTED]> wrote:

>I'm looking at the implementation of the VRML Text node in Xj3D. I have
>a few of questions, which relate to performance, and hence how I'll
>implement it. Any insights as to the best way of implementing this would
>greatly appreciated.
>
>The VRML spec states that Text is a "two-sided flat text-string object".
>This object has a status somewhere between true 3D geometry and
>effectively just a string written as a texture. The interesting
>statement though is that the text "geometry" object is still effected by
>textures and material/lighting. The texturing bit is the worry. Without
>that, it would be a simple choice to just use a texture. It becomes more
>of a pain with texturing because then I have to do either multitexturing
>or some sort of manual composition process. So, some questions:
>
>1. The Text3D class does not state how or whether it is effected by
>textures. Does it?
>
>2. Performance of Text3D in changing the text string. A very typical use
>of Text nodes in VRML is to implement HUD-type readouts of information.
>That means high-speed text modification. As it appears that Text3D
>internally tesselates geometry to create a 3D object. That has me
>concerned about the performance impacts of high-speed text changing. Any
>way of making this into something that will not be the major bottleneck?
>
>3.Creating flat text. The FontExtrusion basically implies geometry that
>has thickness. There's nothing to say how the shape is defined to
>describe such a situation. In fact, I'm not really sure what limitations
>are on the Shape instance. The docs seem to imply a single
>straight-line, but it doesn't say what happens when I pass in, say a
>Rectangle or GeneralPath instance.
>
>
>Points to note.
>
>- I've never seen, in real life, VRML content that uses textures on text
>nodes. If we have to cop a performance penalty or architecture change to
>accommodate this, then that's acceptable.
>
>- The "best" solution is defined in terms of frame-rate performance. It
>is mostly expected that the string(s) will change every frame, not doing
>things like colour cycling or texturing. VRML allows a single Text node
>to describe many strings (ie like a paragraph), which would result in
>needing to update multiple Text3D instances every frame if that was the
>chosen solution.
>
>--
>Justin Couch                         http://www.vlc.com.au/~justin/
>Java Architect & Bit Twiddler              http://www.yumetech.com/
>Author, Java 3D FAQ Maintainer                  http://www.j3d.org/
>-------------------------------------------------------------------
>"Humanism is dead. Animals think, feel; so do machines now.
>Neither man nor woman is the measure of all things. Every organism
>processes data according to its domain, its environment; you, with
>all your brains, would be useless in a mouse's universe..."
>                                               - Greg Bear, Slant
>-------------------------------------------------------------------
>
> ==========================================================================
>To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
>of the message "signoff JAVA3D-INTEREST".  For general help, send email to
>[EMAIL PROTECTED] and include in the body of the message "help".

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA3D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to