I got report that GTGE not working with Mac OS X.
And the exception is really weird, ClassCastException while drawing image
As I don’t have Mac OS X, I don’t know is this something wrong with Mac OS X, or there is something wrong with his Java.
So Mac OS X users, please try this out and see if you got same exception or not :
http://goldenstudios.or.id/products/games/bin/demorpgopengl.jnlp
And some games in here to be sure that it’s really working on Mac OS X or not :
http://goldenstudios.or.id/products/games/
The exception is thrown when I create new buffered image, grab the graphics and draw an image into it :
int width, height;
BufferedImage img = CONFIG.createCompatibleImage(width, height, Transparency.BITMASK);
Graphics2D g = img.createGraphics();
// in here the exception thrown, ClassCastException
g.drawImage(otherImage, 0, 0, null);
g.dispose();
This is the exception :
java.lang.ClassCastException
at
sun.awt.image.BufImgSurfaceData.createData(BufImgSurfaceData.java:434)
at
sun.java2d.SurfaceData.getSurfaceDataFromImage(SurfaceData.java:101)
at apple.awt.CRenderer.blitImage(CRenderer.java:477)
at apple.awt.CRenderer.scaleImage(CRenderer.java:443)
at apple.awt.CRenderer.copyImage(CRenderer.java:497)
at apple.awt.CRenderer.copyImage(CRenderer.java:581)
at sun.java2d.pipe.ValidatePipe.copyImage(ValidatePipe.java:147)
at sun.java2d.SunGraphics2D.drawImage(SunGraphics2D.java:2957)
at sun.java2d.SunGraphics2D.drawImage(SunGraphics2D.java:2947)
.................
Thank you so much