As Matthew has suggested, you can generate the texture using a smaller
point. Once this is done, you can scale the object up, or you can use
the texture on any object.
Text2D has a setRectangleScale(float) method, but it seems not to do
anything. I think is it meant to address this type of problem.
Since Text2D is a Shape3D object, you can use getAppearance() to get
the Appearance NodeComponent with the Texture. Once you have the
Appearance, you can use it for other objects.
A simple example:
Text2D text2d = new Text2D( .........);
Appearance textAppear = text2D.getAppearance();
Shape3D newTextShape = new Shape3D(someGeometry, textAppear);
objRoot.addChild(newTextShape);
Matthew Pocock wrote:
>
> Stephane Cloutier wrote:
>
> > I actually use j3d in a project where I absolutely need labels (which can
> > be really big). I can use Text2D or Text3D objects but I have problems
>
> Create a Text2D with a small font - 12 point or something, and then scale it up with
> a scale transform to the desired size. This way, hardly any texture memory is needed,
> and there is no 1024 point or texture size limit. You can wrap this up in a factory
> object with a method like
> Group buildText2D(String message, double size)
> (Sorry may have got class names wrong)
>
> >
> > Does anyone have experienced this strange effect? Anyone has an idea on
> > the cause or solution?
> >
> > Thanks.
> > Stephane Clouter
> > =====================================================================
> > To subscribe/unsubscribe, send mail to [EMAIL PROTECTED]
> > Java 3D Home Page: http://java.sun.com/products/java-media/3D/
>
> =====================================================================
> To subscribe/unsubscribe, send mail to [EMAIL PROTECTED]
> Java 3D Home Page: http://java.sun.com/products/java-media/3D/
--
-----
Dennis J Bouvier
Find the Java 3D Tutorial "Getting Started with the Java 3D API" at
http://sun.com/desktop/java3d/collateral
=====================================================================
To subscribe/unsubscribe, send mail to [EMAIL PROTECTED]
Java 3D Home Page: http://java.sun.com/products/java-media/3D/