OpenGL 2D and DisplayMode changes

I’ve just downloaded 1,5 beta 2. One of many reasons that made me wait for long hours by my 56k connection to get this was the ability to use the ogl accelerated 2D rendering pipeline, but… If I run my app in windowed mode it’s ok, and if I want to change the resolution to 800x600x32 or whatever, it throws a java.lang.IllegalArgumentException: Invalid display mode at sun.awt.Win32GraphicsDevice.setDisplayMode…etc

I’m running XP pro with a NVidia Geforce FX something with the latest drivers supplied at www.nvidia.com

Do i need to mention that if I don’t use the “Dsun.java2d.opengl=true” command line option it runs fine.The same happends with “Balls.jar”, so my code can’t be blamed (atleast not this time) or is opengl acceleration not supported with FSEM??

Have you filed the bug? what’s the bug number?

I think this is a known bug (I don’t have the ID handy, will post it tomorrow). Try this: run your test with ddraw disabled, and no other options (-Dsun.java2d.noddraw=true) - you probaby will get the same error.

The problem is in the way we’re comparing the display modes, and because of the bug in our code we think that this particular display mode is not supported.

The workaround is to do the work yourself: instead of specifying a particular display mode, you’ll have to pick one from the list of display modes returned by GraphicsDevice.getDisplayModes()…

Unfortunately I don’t think this will be fixed in 1.5, as it’s hardly a showstopper. However, if you think it’s really important, try voting on the bug…

[quote]The workaround is to do the work yourself: instead of specifying a particular display mode, you’ll have to pick one from the list of display modes returned by GraphicsDevice.getDisplayModes()…
[/quote]
Will test that… Only a minor change to my code so I can live with it…incase it works… :wink:

Not at home right now so I can’t test, but I’ll try it later… I’m off on a 4 week vacation, starting today, so I guess I’ll find time for it later ;D
Thanks for the replies

God Speed