LWJGL Webstart problems.

This problem only occurs with LWJGL and I have yet to figure out why. Whenever I try to make a LWJGL application ‘webstartable’ it will load into a blank screen and then close. Note that it doesn’t crash- at least to any extent that I can notice. In some cases the program will error out even before the display gets initialized- errors range from ‘bad program entrance point’ to ‘NoClassDefFoundError’ depending on the machine.

Here’s a test for you guys:
This is a ‘webstartable’ version of Captain Jesters’s NeHe Tutorial #19- the particle system test. It’s simple enough to see if webstart works or not.

EDIT: Problem solved, file taken down.

Note:

I’ve used webstart before with success, though, I have never been able to get things to work when multiple jar files are involved. As long as the program and all of it’s media is contained within a single jar, I’m fine.

I just get a

[quote]java.lang.NoClassDefFoundError: org/lwjgl/Display
at ParticleTest.createWindow(ParticleTest.java:144)
at ParticleTest.init(ParticleTest.java:167)
at ParticleTest.run(ParticleTest.java:61)
at ParticleTest.main(ParticleTest.java:56)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.sun.javaws.Launcher.executeApplication(Unknown Source)
at com.sun.javaws.Launcher.executeMainClass(Unknown Source)
at com.sun.javaws.Launcher.continueLaunch(Unknown Source)
at com.sun.javaws.Launcher.handleApplicationDesc(Unknown Source)
at com.sun.javaws.Launcher.handleLaunchFile(Unknown Source)
at com.sun.javaws.Launcher.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
[/quote]
Last time I checked, there were no org.lwjgl.Display class - but rather a org.lwjgl.opengl.Display

Sorry, Eclipse was pointing to the wrong version of LWJGL. That problem is fixed, though, the blank screen is still a problem.

still errors - try making it run in a console before doing a webstart solution

[quote]java.lang.IllegalArgumentException: Width (-1) and height (-1) must be > 0
at java.awt.image.SampleModel.(Unknown Source)
at java.awt.image.ComponentSampleModel.(Unknown Source)
at java.awt.image.PixelInterleavedSampleModel.(Unknown Source)
at java.awt.image.Raster.createInterleavedRaster(Unknown Source)
at java.awt.image.Raster.createInterleavedRaster(Unknown Source)
at java.awt.image.BufferedImage.(Unknown Source)
at ParticleTest.loadTexture(ParticleTest.java:318)
at ParticleTest.loadTextures(ParticleTest.java:185)
at ParticleTest.init(ParticleTest.java:180)
at ParticleTest.run(ParticleTest.java:71)
at ParticleTest.main(ParticleTest.java:66)
[/quote]
extracting the stuff and placing the Data directory at the root it works (some weird expanding stuff at right corner - can’t see what it does, rund awfully slow ?). It looks like you’re failing in reading data from a jar archive. Try getResourceAsStream instead.

I just signed the jar that Captain Jester distributed. The jar works fine by itself.

I didn’t actually take a look at the classloader- completely forgot about that sort of thing. Using a NeHe tutorial to webstart was a quick (and vain) attempt to fix a problem that happens with my own webstart programs. I just figured that it would work… since it wasn’t written by me.

Anyway, all of this is obsolete now. I have figured out the problem: My webserver doesn’t update files that have been overwritten until overnight. This was creating a version mismatch and lead to the first problem Matzon had where I was referring to an older version of LWJGL. The quick fix for me is to delete the files and upload them rather than overwrite.

Thanks for your help. That error message helped me reach a solution!

Please could you say which one + which version? I once had a webserver (from a hosting company) that did the same and it caused no end of pain.

It would be good to put in a future webstart article in the troubleshooting section!

My host is oneandone.com

They offered a free subscription for 3 years about a few months ago. All I paid was $15 for the domain (for 3 years!) I don’t know their particular server build, however, it might be safe to assume that it is on a different server cluster from the actual paying customers. Perhaps even with different settings.