Hi horati, hi Marvin,
So, the correct choice for your application is to change the bit depth to something supported by hardware rendering...
I'm not quite sure you understood my last post.
The strange thing here is, there is no problem to render within AWT canvas. The problem occurs when switching to JOGL_SWING. The bit depth (16) choosen within the call javax.media.opengl.GLJPanel.initialize() obviously differs from what has been set by the application (24). I found 16 the default value of the buffer bit depth within Xith3D class
CanvasConstructionInfo. However, this is executed by the application:
CanvasConstructionInfo canvasInfo = new CanvasConstructionInfo(
OpenGLLayer.JOGL_SWING
, width
, height
, 24
, DisplayMode.WINDOWED
, true
, antialiasing
, "Virtual Theater"
);
canvasPanel = new Canvas3DJPanel(canvasInfo);
canvasPanel.enableLighting();
canvasPanel.setOpaque(false);
canvasPanel.getCanvas().setBackgroundColor(Colorf.BLACK);
env.addCanvas(canvasPanel);
Next thing, found very strange is what happens within the Xith3D class
DisplayModeSelector when setting "debug" to true. It seems, there is no display mode tried with the correct bit depth. The app sets screen to 1024x768 with bit depth 24. However, the Xith3D framework choses 800x600 with bit depth (-1) after three rounds of trying display modes with bbp=-1.
I really don't find the reason for the strange behaviour. Where will Xith3d obtain and try a bit depth of -1?
Trying to find best mode matching (Width = 1024, Height = 768 , BPP = 24)
Found Mode 0... Width = 320, Height = 240, BPP = -1, frequency = 0
Found Mode 1... Width = 640, Height = 480, BPP = -1, frequency = 0
Found Mode 2... Width = 800, Height = 600, BPP = -1, frequency = 0
Found Mode 3... Width = 1024, Height = 768, BPP = -1, frequency = 0
Found Mode 4... Width = 1152, Height = 864, BPP = -1, frequency = 0
Found Mode 5... Width = 1280, Height = 960, BPP = -1, frequency = 0
Found Mode 6... Width = 1280, Height = 1024, BPP = -1, frequency = 0
Found Mode 7... Width = 1480, Height = 925, BPP = -1, frequency = 0
Found Mode 8... Width = 1600, Height = 1200, BPP = -1, frequency = 0
Found Mode 9... Width = 1680, Height = 1050, BPP = -1, frequency = 0
Found Mode 10... Width = 1920, Height = 1200, BPP = -1, frequency = 0
Using mode: Width = 1024, Height = 768, BPP = -1, frequency = 0
Trying to find best mode matching (Width = 800, Height = 600 , BPP = -1)
Found Mode 0... Width = 320, Height = 240, BPP = -1, frequency = 0
Found Mode 1... Width = 640, Height = 480, BPP = -1, frequency = 0
Found Mode 2... Width = 800, Height = 600, BPP = -1, frequency = 0
Found Mode 3... Width = 1024, Height = 768, BPP = -1, frequency = 0
Found Mode 4... Width = 1152, Height = 864, BPP = -1, frequency = 0
Found Mode 5... Width = 1280, Height = 960, BPP = -1, frequency = 0
Found Mode 6... Width = 1280, Height = 1024, BPP = -1, frequency = 0
Found Mode 7... Width = 1480, Height = 925, BPP = -1, frequency = 0
Found Mode 8... Width = 1600, Height = 1200, BPP = -1, frequency = 0
Found Mode 9... Width = 1680, Height = 1050, BPP = -1, frequency = 0
Found Mode 10... Width = 1920, Height = 1200, BPP = -1, frequency = 0
Using mode: Width = 800, Height = 600, BPP = -1, frequency = 0
Trying to find best mode matching (Width = 800, Height = 600 , BPP = -1)
Found Mode 0... Width = 320, Height = 240, BPP = -1, frequency = 0
Found Mode 1... Width = 640, Height = 480, BPP = -1, frequency = 0
Found Mode 2... Width = 800, Height = 600, BPP = -1, frequency = 0
Found Mode 3... Width = 1024, Height = 768, BPP = -1, frequency = 0
Found Mode 4... Width = 1152, Height = 864, BPP = -1, frequency = 0
Found Mode 5... Width = 1280, Height = 960, BPP = -1, frequency = 0
Found Mode 6... Width = 1280, Height = 1024, BPP = -1, frequency = 0
Found Mode 7... Width = 1480, Height = 925, BPP = -1, frequency = 0
Found Mode 8... Width = 1600, Height = 1200, BPP = -1, frequency = 0
Found Mode 9... Width = 1680, Height = 1050, BPP = -1, frequency = 0
Found Mode 10... Width = 1920, Height = 1200, BPP = -1, frequency = 0
Using mode: Width = 800, Height = 600, BPP = -1, frequency = 0