Sign in to follow this  
billconan

how to use glSelectBuffer

Recommended Posts

billconan    200
hello guys, i'm tring to render water with reflection, so i need to render the scene on a texture first to do the reflection scene. but the question is how to use glSelectBuffer cause every time i run the program, i got the error of stack overflaw. i think that i must be wrong somewhere. here is the code: GLuint bmp[1024*768*3]; glColor4ub(255,255,255,255); glSelectBuffer(1024*768*3,bmp); glRenderMode(GL_SELECT); btw, how to specify the size of the buffer? cause the glSelectBuffer function does not specify the color format like rgba or rgb. thanks

Share this post


Link to post
Share on other sites
billconan    200
there seems to be no such function as glCopyTexture?

i find this function on the article about render to texture in a nvidia article but i just can not use it? why

Share this post


Link to post
Share on other sites
Boder    938
glSelectBuffer has nothing to do with RGB/RGBA/bmp. Nothing is actually rendered in Selection Mode. Check the docs.

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