Sign in to follow this  
Merlino

Retreiving Function/Tokens Adress [multitexturing extensions]

Recommended Posts

I would like to retreive the multitexturing function adresses, since they are not "supported" by default. Say I want to retreive the adress of the function "glActiveTexture()". How do I do it?? I've been looking for a while on the internet but I didn't really understand the procedure... And also how do I use tokens? (ex: GL_TEXTURE0: my compiler says that it's undeclared just like the other functions...); Thanks in advance, Merlino.

Share this post


Link to post
Share on other sites
If you're using windows, wglGetProcAddress("FunctionName");. In this case, FunctionName would be glActiveTextureARB. This'll return a pointer to your function if the video card supports it. You can get a list of supported extensions for the card you're using with glGetString(GL_EXTENSIONS). Alternatively you could use GLEW which handles getting extension function pointers for you. I believe its cross platform as well.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this