From efe600c38d0a862a4034a7b8ca8aeb42f247cbea Mon Sep 17 00:00:00 2001 From: Kirill Vainer Date: Tue, 22 Sep 2015 21:57:42 -0400 Subject: [PATCH] GLRenderer: put max anisotropy into limits map --- jme3-core/src/main/java/com/jme3/renderer/Limits.java | 2 ++ jme3-core/src/main/java/com/jme3/renderer/opengl/GLExt.java | 1 + .../src/main/java/com/jme3/renderer/opengl/GLRenderer.java | 1 + 3 files changed, 4 insertions(+) diff --git a/jme3-core/src/main/java/com/jme3/renderer/Limits.java b/jme3-core/src/main/java/com/jme3/renderer/Limits.java index 86cddb178..81db88f5e 100644 --- a/jme3-core/src/main/java/com/jme3/renderer/Limits.java +++ b/jme3-core/src/main/java/com/jme3/renderer/Limits.java @@ -77,4 +77,6 @@ public enum Limits { DepthTextureSamples, VertexUniformVectors, + + TextureAnisotropy, } diff --git a/jme3-core/src/main/java/com/jme3/renderer/opengl/GLExt.java b/jme3-core/src/main/java/com/jme3/renderer/opengl/GLExt.java index 27f0eb8bd..c77ff6449 100644 --- a/jme3-core/src/main/java/com/jme3/renderer/opengl/GLExt.java +++ b/jme3-core/src/main/java/com/jme3/renderer/opengl/GLExt.java @@ -68,6 +68,7 @@ public interface GLExt { public static final int GL_MAX_DEPTH_TEXTURE_SAMPLES = 0x910F; public static final int GL_MAX_DRAW_BUFFERS_ARB = 0x8824; public static final int GL_MAX_SAMPLES_EXT = 0x8D57; + public static final int GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT = 0x84FF; public static final int GL_MULTISAMPLE_ARB = 0x809D; public static final int GL_NUM_PROGRAM_BINARY_FORMATS = 0x87FE; public static final int GL_PIXEL_PACK_BUFFER_ARB = 0x88EB; diff --git a/jme3-core/src/main/java/com/jme3/renderer/opengl/GLRenderer.java b/jme3-core/src/main/java/com/jme3/renderer/opengl/GLRenderer.java index 276453117..ee7f7a560 100644 --- a/jme3-core/src/main/java/com/jme3/renderer/opengl/GLRenderer.java +++ b/jme3-core/src/main/java/com/jme3/renderer/opengl/GLRenderer.java @@ -374,6 +374,7 @@ public class GLRenderer implements Renderer { if (hasExtension("GL_EXT_texture_filter_anisotropic")) { caps.add(Caps.TextureFilterAnisotropic); + limits.put(Limits.TextureAnisotropy, getInteger(GLExt.GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT)); } if (hasExtension("GL_EXT_framebuffer_object")