Jump to content
  • Advertisement
Sign in to follow this  
raptorstrike

GL_CLAMP_TO_EDGE Undeclared

This topic is 4496 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

This is a stange error. I thought that GL_CLAMP_TO_EDGE was a standard enum with opengl (no extension needed) but I keep getting the error `GL_CLAMP_TO_EDGE' undeclared (first use this function) (gcc) The actual line is glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_WRAP_T,GL_CLAMP_TO_EDGE); There really isn't any reason why this shouldnt work. Is this a recent addition? All other opengl functions/params work Any thoughts? thanks [smile]

Share this post


Link to post
Share on other sites
Advertisement
Sometimes old OpenGL headers don't have it defined, for some reason.
Just define this at the top of your code, and your problem should be fixed:
#ifndef GL_CLAMP_TO_EDGE
#define GL_CLAMP_TO_EDGE 0x812F
#endif

Share this post


Link to post
Share on other sites
Well rather then take the quick fix for this one, I figure its probably not a good idea to have out of date stuff when It comes to OpenGl so where could I get V 1.2? I know generally that these are distrubuted through the grapics card vendors but I am having trouble finding the driver for my card

(ATI RADEON X600 SE)

Share this post


Link to post
Share on other sites
Just include <gl/glext.h> and if you don't have that www.opengl.org does :)

If you want version 1.2 functions.. that's another story.

~zix~

EDIT: More specifically it can be found here

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!