Changed: #573 Get the maximum anisotropic value

This commit is contained in:
kervala 2010-12-22 14:21:40 +01:00
parent fcd7edc6b3
commit e363ebe2e8
2 changed files with 11 additions and 1 deletions

View file

@ -1420,6 +1420,12 @@ void registerGlExtensions(CGlExtensions &ext)
// Check GL_EXT_texture_filter_anisotropic
ext.EXTTextureFilterAnisotropic = setupEXTTextureFilterAnisotropic(glext);
if (ext.EXTTextureFilterAnisotropic)
{
// get the maximum value
glGetFloatv(GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT, &ext.EXTTextureFilterAnisotropicMaximum);
}
// Check GL_EXT_framebuffer_object
ext.FrameBufferObject = setupFrameBufferObject(glext);

View file

@ -84,6 +84,8 @@ struct CGlExtensions
bool FrameBufferMultisample;
bool PackedDepthStencil;
bool EXTTextureFilterAnisotropic;
float EXTTextureFilterAnisotropicMaximum;
// true if NVVertexProgram and if we know that VP is emulated
bool NVVertexProgramEmulated;
bool EXTSecondaryColor;
@ -170,6 +172,7 @@ public:
NVTextureRectangle = false;
EXTTextureRectangle = false;
EXTTextureFilterAnisotropic = false;
EXTTextureFilterAnisotropicMaximum = 1.f;
ARBTextureRectangle = false;
ARBTextureNonPowerOfTwo = false;
ARBMultisample = false;
@ -206,7 +209,7 @@ public:
result += NVTextureRectangle ? "NVTextureRectangle " : "";
result += EXTTextureRectangle ? "EXTTextureRectangle " : "";
result += ARBTextureRectangle ? "ARBTextureRectangle " : "";
result += EXTTextureFilterAnisotropic ? "EXTTextureFilterAnisotropic " : "";
result += EXTTextureFilterAnisotropic ? "EXTTextureFilterAnisotropic (Maximum = " + NLMISC::toString(EXTTextureFilterAnisotropicMaximum) + ") " : "";
result += ARBTextureNonPowerOfTwo ? "ARBTextureNonPowerOfTwo " : "";
result += "texture stages(*) = ";
result += NLMISC::toString(NbTextureStages);
@ -236,6 +239,7 @@ public:
result += WGLEXTSwapControl ? "WGLEXTSwapControl " : "";
#elif defined(NL_OS_MAC)
#elif defined(NL_OS_UNIX)
result += "\n GLX: ";
result += GLXEXTSwapControl ? "GLXEXTSwapControl " : "";
result += GLXSGISwapControl ? "GLXSGISwapControl " : "";
result += GLXMESASwapControl ? "GLXMESASwapControl " : "";