Jump to content
  • Advertisement
Sign in to follow this  
karx11erx

OpenGL glEnableClientState (): GL_INVALID_OPERATION

This topic is 4054 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

I am getting an error GL_INVALID_OPERATION when calling glEnableClientState (GL_VERTEX_ARRAY) in my application. Other functions (e.g. GL_COLOR_ARRAY) work fine, and the problematic call is definitely not made inside a glBegin() ... glEnd() sequence. I am also making sure to call glDisableClientState() for all enabled client states when done rendering a primitive. I tried putting a glEnd() and a glDisableClientState (GL_VERTEX_ARRAY) call in front of the failing call just to make sure, but it didn't help. I am having that at two different locations in my program, and apparently only if rather large vertex arrays are involved (though OpenGL should not know anything about buffer size when passing a buffer address with that call). What could that be? I am totally clueless and pretty frustrated. Edit: I just found out that the error occurs on whatever client state I try to set first when entering the primitive renderer. When I just issue the failed call a second time, it suddenly works. What could that be? Btw, even if successfully setting all client states, nothing gets rendered. The buffers all seem fine though. I am having other code rendering using glDrawArrays() that works fine, so it doesn't seem to be that I don't understand how to handle this. [Edited by - karx11erx on June 14, 2007 5:22:48 PM]

Share this post


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

  • Advertisement
×

Important Information

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

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!