#include<windows.h>
#include<iostream.h>
#include<gl\gl.h>
#include<gl\glu.h>
#include<gl\glut.h>
void main()
{
int mm;
glGetIntegerv(GL_MAX_TEXTURE_UNITS,&mm);
cout <<"mm = " << mm << endl;
}
but when i compiled i received the error message: error C2065: 'GL_MAX_TEXTURE_UNITS' : undeclared identifier
i'm using VC6++ now. I really don't know that ! help me !!!
find out how many texture units ... ?
I want to find out how many texture units are supported by OpenGL implementation, so i write a program like this:
GL_MAX_TEXTURE_UNITS is defined in glext.h, you can download the extension header files from here:
http://www.opengl.org/registry/
http://www.opengl.org/registry/
Also, that won't work. You need to have created a valid OpenGL context (ie. display) before gl commands will work.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement