diff options
author | Chien Yang <[email protected]> | 2007-03-09 00:58:28 +0000 |
---|---|---|
committer | Chien Yang <[email protected]> | 2007-03-09 00:58:28 +0000 |
commit | 637d8427266fd3108764700b9f95d9a3b03893ff (patch) | |
tree | 29be17c24091efda5589d8bcc8cf84153aa7dd0c /src/classes/jogl/javax/media | |
parent | 88d9f0a85c8f8ddcfb758676296b86236cffaa2e (diff) |
Added support to query GL_SGIS_generate_mipmap and GL_VERSION_1_4 (OpenGL only).
git-svn-id: https://svn.java.net/svn/j3d-core~svn/trunk@790 ba19aa83-45c5-6ac9-afd3-db810772062c
Diffstat (limited to 'src/classes/jogl/javax/media')
-rw-r--r-- | src/classes/jogl/javax/media/j3d/JoglPipeline.java | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/classes/jogl/javax/media/j3d/JoglPipeline.java b/src/classes/jogl/javax/media/j3d/JoglPipeline.java index a6a134a..a8d6db5 100644 --- a/src/classes/jogl/javax/media/j3d/JoglPipeline.java +++ b/src/classes/jogl/javax/media/j3d/JoglPipeline.java @@ -8248,6 +8248,11 @@ class JoglPipeline extends Pipeline { gl.isExtensionAvailable("GL_ARB_texture_non_power_of_two")) { cv.textureExtendedFeatures |= Canvas3D.TEXTURE_NON_POWER_OF_TWO; } + + if (gl.isExtensionAvailable("GL_SGIS_generate_mipmap")) { + cv.textureExtendedFeatures |= Canvas3D.TEXTURE_AUTO_MIPMAP_GENERATION; + } + } @@ -8407,10 +8412,12 @@ class JoglPipeline extends Pipeline { } boolean gl20 = false; + boolean gl14 = false; boolean gl13 = false; if (major > 1) { // OpenGL 2.x -- set flags for 1.3 and 2.0 or greater gl20 = true; + gl14 = true; gl13 = true; } else { if (minor == 2) { @@ -8422,8 +8429,15 @@ class JoglPipeline extends Pipeline { if (gl20) { assert gl13; + assert gl14; assert gl.isExtensionAvailable("GL_VERSION_2_0"); } + + if (gl14) { + assert gl13; + assert gl.isExtensionAvailable("GL_VERSION_1_4"); + } + if (gl13) { assert gl.isExtensionAvailable("GL_VERSION_1_3"); } @@ -8434,6 +8448,10 @@ class JoglPipeline extends Pipeline { // Note that we don't query for GL_ARB_imaging here cv.textureExtendedFeatures |= Canvas3D.TEXTURE_LOD_RANGE; + + if (gl14) { + cv.textureExtendedFeatures |= Canvas3D.TEXTURE_AUTO_MIPMAP_GENERATION; + } // look for OpenGL 2.0 features // Fix to Issue 455 : Need to disable NPOT textures for older cards that claim to support it. |