As the title says, the JMEDesktopState class does not have javadocs in it other than the class author tag.
just for your info (and this is just my opinion), JMEDesktop is kind of a band-aid to have a GUI system built into jME. The way it functions is not only inefficient but also only works well on Windows (and there may be additional issues with it).
If you need a more robust system look at FengGUI or GBUI (I think thats the 'current' named 'version')…
GBUI is the current name…if anyone else has a better name we're all ears…but yes GBUI is the "enhanced" BUI
I know about the performance issues of the JDesktopPane, having worked with it since it was first in the J2SE, but whereas it used to be a huge problem to get it to start up and react with acceptable performance, IMO these issues are negligible for a game targeting 3D gamers in 2009. Sure there are 3D games where you want to accommodate lowest-common-demoninator 3D hardware (or software-only 3D rendering); but for a PC that meets the sys reqs for a current commercial 3D MMO, for example, the difference between Swing and JDesktopPane is unnoticeable. It's just that the comparative resource consumption has gone from like 20:20 for 2D-desktop:3D-canvas to 1:20. If somebody has a jME game that suffers from too many widgets on a JDesktopPane, on a gamer PC, I'd like to know about it.
JMEDesktop works just fine on UNIX with J2SE 6. I am doing all sorts of stuff with it, including fullscreen/windowed in different resolutions. The only problem I know of is that I had to learn to adjust the JMEDesktop myself since the supplied tests and examples don't cover everything you need for the most basic game (+ the mentioned lack of docs). If anybody has questions about getting basic UI-over-gameworld working with JMEDesktop, post the question here and PM me to bring it to my attention.
I would say that you should not use JMEDesktop (regardless of BasicGame vs. StandardGame states) if you are targeting legacy PCs; but beyond that you should choose depending on whether your design warrants an MDI. If you want an MDI, JDesktopPane takes care of a lot of details that you would otherwise need to implement, and swt doesn't support MDI at all. I prefer not to go outside of the J2SE unless necessary (minimizes what me and my code maintainers need to know; teaches an optimally reusable skill; minimizes distributable size).
If anybody wants a copy of my JMEDesktop branch, which has working toolbars, menu bar, JOptionPane, JFileChooser (plus many general fixes, mostly to do with multi-threading bugs), let me know. Pretty much all of the limitations of JMEDesktop (compared to a standard JDesktopPane) are due to JMEDesktop being built upon a Frame instead of a JFrame. Maybe at one time it would only work with a Frame, but it sure works better when you give the JDesktopPane the JFrame that it was designed to live under.
My new app, though certainly not production quality yet, does show what is possible with JMEDesktop.
http://pub.admc.com/misc/modeler.jnlp or http://pub.admc.com/misc/modeler-samesettings.jnlp, depending on whether you want to re-run the setup screen.
I get this:
4/24/09 9:52:36 AM [0x0-0x15f15f].com.apple.JavaWebStart Exception in thread "main" java.lang.NullPointerException
4/24/09 9:52:36 AM [0x0-0x15f15f].com.apple.JavaWebStart at com.sun.javaws.LaunchSelection.selectJRE(LaunchSelection.java:60)
4/24/09 9:52:36 AM [0x0-0x15f15f].com.apple.JavaWebStart at com.sun.javaws.jnl.LaunchDesc.<init>(LaunchDesc.java:78)
4/24/09 9:52:36 AM [0x0-0x15f15f].com.apple.JavaWebStart at com.sun.javaws.jnl.XMLFormat.parse(XMLFormat.java:117)
4/24/09 9:52:36 AM [0x0-0x15f15f].com.apple.JavaWebStart at com.sun.javaws.jnl.LaunchDescFactory.buildDescriptor(LaunchDescFactory.java:48)
4/24/09 9:52:36 AM [0x0-0x15f15f].com.apple.JavaWebStart at com.sun.javaws.jnl.LaunchDescFactory.buildDescriptor(LaunchDescFactory.java:60)
4/24/09 9:52:36 AM [0x0-0x15f15f].com.apple.JavaWebStart at com.sun.javaws.jnl.LaunchDescFactory.buildDescriptor(LaunchDescFactory.java:117)
4/24/09 9:52:36 AM [0x0-0x15f15f].com.apple.JavaWebStart at com.sun.javaws.Main.launchApp(Main.java:183)
4/24/09 9:52:36 AM [0x0-0x15f15f].com.apple.JavaWebStart at com.sun.javaws.Main.main(Main.java:137)
OSX 10.5
Java 1.5
32bit CoreDuo
basixs said:
I get this:
4/24/09 9:52:36 AM [0x0-0x15f15f].com.apple.JavaWebStart Exception in thread "main" java.lang.NullPointerException ...
4/24/09 9:52:36 AM [0x0-0x15f15f].com.apple.JavaWebStart at com.sun.javaws.Main.main(Main.java:137)
OSX 10.5
Java 1.5
32bit CoreDuo
Looks like a WebStart system problem unrelated to my app, based on the following. The exception shows that the error is occuring when WebStart is trying to select a JRE. That could be my problem if I had anything to do with JRE selection, but in this case you can see that there is no platform or JRE specification in my JNLP file. Those dependencies are deferred to the LWJGL and JOGL maintainers.
Are you able to run any WebStart app successfully?
All the jMonkeyWeb starts work for me (except the island one, which is unrelated…). So do all the of the JOGL webstarts, however there seems to be an issue w/ the LWJGL webstarts. I doubt its related though, it gives a runtime exception; whereas yours errors out before even launching the JRE (I had to go to the javaws logs to get the above trace). I am not sure why it is coming up w/ that error (never actually seen it before even), I only have the standard Sun 1.5 and 1.4.2 JREs installed here…
basixs said:
All the jMonkeyWeb starts work for me (except the island one, which is unrelated...). So do all the of the JOGL webstarts, however there seems to be an issue w/ the LWJGL webstarts. I doubt its related though, it gives a runtime exception; whereas yours errors out before even launching the JRE (I had to go to the javaws logs to get the above trace). I am not sure why it is coming up w/ that error (never actually seen it before even), I only have the standard Sun 1.5 and 1.4.2 JREs installed here...
In that case, I'll have to load up 1.5 somewhere and try to reproduce.
Maybe the JRE specification was required before 1.6 or something (as opposed to defaulting to any).
Thanks very much for the good testing info.
WebStart 5 has terrible a terrible JRE discovery implementation, but the root cause is that my app does need Java 6 (implicitly). I do not have the time to dedicate to making it 1.5-conformant :(.
UPDATED. I made a JNLP to automatically load the Ninja model into the Modeler:
I would encourage anybody interested in fancy animation who has access to Java 6, to run http://pub.admc.com/misc/ninja.jnlp Open up the scene tree widget, click background, / to display a grid, and click on “Ninja” node in tree. You can then play with the 20 animations provided by the Radakan team.