View Full Version : TGA Texturing - Char comparison question

12-19-2002, 04:25 PM
Alright here's the deal. I'm trying to determine if a tga file is of the new type or the old type by reading in the footer. In the footer it should contain the string:


So I fread() it in appropriately but here's my problem. I read it into an unsigned char array. When I cout << footer << endl; It shows me the string appropriately, however when I try to strcmp(footer, "TRUEVISION-XFILE") it complains that the first arguement is an unsigned char, and the second is a signed char. How do I check this?? Thanks

12-19-2002, 09:57 PM
Hi !

I can't say that I find the relation to OpenGL here, but anyway...

strcmp((char*) your_unsigned_array, "string_to_compare");