diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/classes/jogl/javax/media/j3d/JoglPipeline.java | 8 | ||||
-rw-r--r-- | src/classes/share/javax/media/j3d/Canvas3D.java | 6 | ||||
-rw-r--r-- | src/native/d3d/D3dCtx.cpp | 3 |
3 files changed, 16 insertions, 1 deletions
diff --git a/src/classes/jogl/javax/media/j3d/JoglPipeline.java b/src/classes/jogl/javax/media/j3d/JoglPipeline.java index eae3ab2..40a0b7e 100644 --- a/src/classes/jogl/javax/media/j3d/JoglPipeline.java +++ b/src/classes/jogl/javax/media/j3d/JoglPipeline.java @@ -6961,6 +6961,9 @@ class JoglPipeline extends Pipeline { gl.glDepthFunc(GL.GL_LEQUAL); gl.glEnable(GL.GL_COLOR_MATERIAL); gl.glReadBuffer(GL.GL_FRONT); + + // Workaround for issue 400: Enable separate specular by default + gl.glLightModeli(GL.GL_LIGHT_MODEL_COLOR_CONTROL, GL.GL_SEPARATE_SPECULAR_COLOR); } finally { context.release(); } @@ -8657,6 +8660,11 @@ class JoglPipeline extends Pipeline { // (Java3D's native code has a loop trying 8, 6, 4, 3, and 2 samples) caps.setNumSamples(4); + // Issue 399: Request alpha buffer if transparentOffScreen is set + if (VirtualUniverse.mc.transparentOffScreen) { + caps.setAlphaBits(1); + } + java.util.List<Integer> capsToDisable = new ArrayList<Integer>(); // Add PREFERRED capabilities in order we will try disabling them if (gct.getStereo() == GraphicsConfigTemplate.PREFERRED) { diff --git a/src/classes/share/javax/media/j3d/Canvas3D.java b/src/classes/share/javax/media/j3d/Canvas3D.java index 7efad89..99b7f1a 100644 --- a/src/classes/share/javax/media/j3d/Canvas3D.java +++ b/src/classes/share/javax/media/j3d/Canvas3D.java @@ -4772,7 +4772,11 @@ public class Canvas3D extends Canvas { if (obj == null) { continue; } - assert id == ((TextureRetained)obj).objectId; + + // Issue 403 : this assertion doesn't hold in some cases + // TODO KCR : determine why this is the case +// assert id == ((TextureRetained)obj).objectId; + freeTexture(ctx, id); if (obj instanceof TextureRetained) { tex = (TextureRetained) obj; diff --git a/src/native/d3d/D3dCtx.cpp b/src/native/d3d/D3dCtx.cpp index dccfd8f..ec01327 100644 --- a/src/native/d3d/D3dCtx.cpp +++ b/src/native/d3d/D3dCtx.cpp @@ -623,6 +623,9 @@ else setViewport(); setDefaultAttributes(); + + // Issue 400: initialize local viewer (for lighting) to false + pDevice->SetRenderState(D3DRS_LOCALVIEWER, FALSE); createVertexBuffer(); |