So I'm writing my texture class in my opengl game, I get to the part where I would normally set GL_TEXTURE_MAX_ANISOTROPY_EXT, and I'm shocked to discover that it's undefined! This exact same extensions worked perfectly in a different application, so I know it's not a typo or something.

It's worth noting that I'm getting my extensions using glcorearb.h, instead of glext.h, because I have no intention of supporting the compatibility profile. Could this be my problem, and if so, how do I work around it?


2 Answers 2


It's hard to say without seeing the whole project so here are a few ideas:

  • Check if you have the project's paths properly set up - maybe a path to some library/header file is missing. Check the other project (the one which works) and compare. Make sure to adjust the paths/settings for the new project's location.
  • Are you using the same version of library/ies that in the other project? If not maybe this version doesn't support GL_TEXTURE_MAX_ANISOTROPY_EXT (I don't know if it should, just looking for possible explanations).
  • Make sure you have necessary header file(s) included in the source file where you're trying to use GL_TEXTURE_MAX_ANISOTROPY_EXT.


From what I gather, it seems that anisotropic filtering is still implemented as an extension and isn't included in OpenGL Core. Therefore you have to use it like any other extension (if you don't know how, there are plenty of tutorials).

As for the value itself, the docs define it as:


If you don't want to define it by yourself or if need more OpenGL extensions you should just use glext.h or some other library like you used to.

  • \$\begingroup\$ In my other project i was using SDL and Glew. This time, I'm using pure win32 and glcorearb.h. \$\endgroup\$
    – Haydn
    Feb 23, 2014 at 0:38
  • \$\begingroup\$ I've updated my answer, please check it out. \$\endgroup\$
    – NPS
    Feb 23, 2014 at 1:13
  • \$\begingroup\$ glcorearb.h is described as having every opengl extension available, except for the stuff that isn't available in the core profile. Is that incorrect? \$\endgroup\$
    – Haydn
    Feb 23, 2014 at 7:25
  • \$\begingroup\$ @Haydn From the file itself: "glcorearb.h includes only APIs in the latest OpenGL core profile implementation together with APIs in newer ARB extensions which can be can be supported by the core profile." This description is very unclear for me - if anyone has a link to some detail description of the file's purpose, please share. But either way - the file doesn't contain GL_TEXTURE_MAX_ANISOTROPY_EXT. \$\endgroup\$
    – NPS
    Feb 23, 2014 at 10:47
  • \$\begingroup\$ Yep, you were absolutely right, glcorearb.h doesn't contain anything besides the extensions that are in OpenGL core. Looks like I'm going back to GLEW. \$\endgroup\$
    – Haydn
    Feb 25, 2014 at 1:37

This information may not be completely relevant/true since the latest OpenGL versions

If you are wondering why anisotropy is not included in OpenGL core, I found that the following page had a good explanation:


The “Open” in OpenGL refers to the availability of the specification, but also to the ability for anyone to implement it. As it turns out, anisotropic filtering has intellectual property issues associated with it. If it were adopted into the core, then core OpenGL would not be able to be implemented without licensing the technology from the holder of the IP. It is not a proprietary extension because none of the ARB members have the IP; it is held by a third party.

  • 3
    \$\begingroup\$ Actually it could go into core if a hypothetical core version was modified to allow a minimum value of MAX_TEXTURE_MAX_ANISOTROPY of 1; a similar compromise was made for GL_ARB_occlusion_query where QUERY_COUNTER_BITS was allowed to be 0 (according to ARB meeting notes this was so that Intel could claim GL 1.5 support despite not supporting occlusion queries). So the implementation just returns 1, it never actually has to implement anisotropic filtering, and IP issues are bypassed. \$\endgroup\$ May 29, 2014 at 22:57

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .