jav...@javadesktop.org wrote:
Hi All,
I'm creating a GUI that uses a custom skin using Synth. I would like to know more about
how I can determine how much rendering is being done using the hardware acceleration on
my machine. I've found that the Java 6 SE Troubleshooting Guide has some suggestions on
how to do this. It mentions that the [b]-Dsun.java2d.opengl=True[/b] setting (with a
capital "T") can be used to switch to using the OpenGL pipeline with trace
output enabled. Another setting [b]-Dsun.java2d.trace=count[/b] provides a summary of
primitives used that is dumped on application exit.
The problem I've having is that these system properties don't provide output
for me - I don't see any trace output on the console. The steps I followed are:
1) compile the GUI to a jar, [b]gui.jar[/b]
2) [b]export J2D_TRACE_LEVEL=4[/b]
3) try [b]java -jar gui.jar -Dsun.java2d.trace=count[/b] -> jar runs but no
trace counts on exit
4) try [b]java -jar gui.jar -Dsun.java2d.opengl=True[/b] -> jar runs but no
trace provided during run
You need to put -Dstuff=stuff before -jar, otherwise it is treated as a
parameter to your application, not java runtime.
Dmitr
The GUI is skinned using images and Java2D primitives so I expect that the mix
of graphics routines would invoke hardware acceleration of some kind. Is there
something I'm missing here? Were these system properties perhaps removed for
the update 10 stable builds?
I've tried this with Java 6 update 10 and update 13. Interestingly, the GUI ran
very slow on update 10 without the [b]opengl=True[/b] setting but not in the
case of update 13 so I'm assuming 13 came out with more optimised / accelerated
routines. Also the [b]opengl=True[/b] setting provided some output on update 10
but not on update 13.
I've tried this on Ubuntu Jaunty (9.04) and Hardy (8.04). My graphics card is a
NVidia GeForce series card.
Thanks for reading,
Mark
[Message sent by forum member 'bowsermail' (bowsermail)]
http://forums.java.net/jive/thread.jspa?messageID=347167
===========================================================================
To unsubscribe, send email to lists...@java.sun.com and include in the body
of the message "signoff JAVA2D-INTEREST". For general help, send email to
lists...@java.sun.com and include in the body of the message "help".
===========================================================================
To unsubscribe, send email to lists...@java.sun.com and include in the body
of the message "signoff JAVA2D-INTEREST". For general help, send email to
lists...@java.sun.com and include in the body of the message "help".