hey mates, im really newbie with java3d, im learning this api, and
doing somes test, but i have my first question, i want to put some
text on the screen, i know its exist a Text2D class, but its interact
with the virtualuniverse , i want only put flat text on the screen,
with some data, maybe the fps , coordenates , etc
i was trying to use the getGraphics of Canvas3D and use drawString but
didnt work, i did the same thing with Frame also with Applet, i got
the graphics and used drawString, but nothing
how can i do to be able to do this? could you give me somes examples?
i hope you can help me:D
PD: sorry my bad english , i from venezuela :$
tugalsan - 26 Mar 2008 09:35 GMT
> hey mates, im really newbie with java3d, im learning this api, and
> doing somes test, but i have my first question, i want to put some
[quoted text clipped - 11 lines]
>
> PD: sorry my bad english , i from venezuela :$
just ovverride postRender method in Canvas3D
use getGraphics() method and use it
I know it flickering but itworks :)
if you find a better way please sent to my email (tugalsan@gmail.com)
as I am not using this site much.
byz
tugalsan karabacak TURKEY
tugalsan - 26 Mar 2008 09:37 GMT
just ovverride postRender method in Canvas3D
use getGraphics() method and use it
I know it flickering but itworks :)
if you find a better way please sent to my email (tugalsan@gmail.com)
as I am not using this site much.
byz
tugalsan karabacak TURKEY
tugalsan - 26 Mar 2008 09:38 GMT
just ovverride postRender method in Canvas3D
use getGraphics() method and use it
I know it flickering but itworks :)
if you find a better way please sent to my email (t u g a l s a n @ g
m a i l . c o m)
as I am not using this site much.
byz
tugalsan karabacak TURKEY
tugalsan - 26 Mar 2008 10:34 GMT
1. hey man, the code I wrote above, use it on postSwap method, iyt
filckers less.
2.I found a code on another thread in this site and made a class for
you:
class Canvas3DWithDebug extends Canvas3D {
Canvas3DWithDebug(GraphicsConfiguration graphicsConfiguration)
{
super(graphicsConfiguration);
}
public void postRender() {
getGraphics2D().drawString("asli", 30, 30);
getGraphics2D().flush(true);
}
}
it work fine but no font or color chnage can be made. its always
white.
if you find a good code, dont forget to send me email man,
byz