View Full Version : (strstr(glGetString(GL_EXTENSIONS), "EXT_multitexture") != NULL) ????

05-23-2002, 11:26 AM
What is wrong with this??

if(strstr(glGetString(GL_EXTENSIONS), "EXT_multitexture") != NULL)
do stuff

why do i keep getting the error, parameter one cannot be converted from, const usigned char * to const char * ???? any one got a clue?? damn i am really starting to get annoyed with this extensions thing.

[This message has been edited by dabeav (edited 05-23-2002).]

05-23-2002, 11:36 AM
Your problem is C++. It is an annoying, officious language. Try:

if(strstr((const char*)glGetString(GL_EXTENSIONS), "EXT_multitexture") != NULL)


i.e. force the type conversion.

I hate C++, it insults my intelligence.

05-23-2002, 12:32 PM
There is no EXT_multitexture extension ( as far as I know). Use ARB_multitexture instead. You need to search for GL_ARB_MULTITEXTURE, not just ARB_MULTITEXTURE.

05-23-2002, 12:56 PM
Thank you polygon gods. That worked like a dream. Cant believe i missed that REPEATEDLY. oh im sooooo over worked. Oh, and once again, sorry about the miss type, i knew that it was ARB, instead of EXT, my bad. Thank you once again.

Leyder Dylan
05-24-2002, 07:27 AM
Extension = (char *) glGetString(GL_EXTENSIONS);

if (!(strstr(Extension, "GL_ARB_multitexture")) == 1)
{//not supported}