• Advertisement
Sign in to follow this  

auxDIBImageLoad problem

This topic is 3943 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 have been walking though the tutorials on NeHe's website. I keep getting this error when i try and compile my code. 'auxDIBImageLoadW' : cannot convert parameter 1 from 'char *' to 'LPCWSTR' the biggest difference is that i am using glut to handle my windows instead of coding them myself. would that be causing my problems?
AUX_RGBImageRec* LoadBMP(char *Filename)
{
	FILE *File=NULL;	
	File=fopen(Filename,"r");				
	fclose(File);
	return auxDIBImageLoad(Filename); <-error on this line				
}

void LoadGLTextures()
{
	AUX_RGBImageRec *TextureImage[1];				
	TextureImage[0]=LoadBMP("img1.bmp");
	glGenTextures(1, &texture[0]);
	glBindTexture(GL_TEXTURE_2D, texture[0]);
	glTexImage2D(GL_TEXTURE_2D, 0, 3, TextureImage[0]->sizeX,    TextureImage[0]->sizeY, 0, GL_RGB, GL_UNSIGNED_BYTE, TextureImage[0]->data);
	glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR);
	glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);	
	
	free(TextureImage[0]->data);				
	free(TextureImage[0]);		
}

Share this post


Link to post
Share on other sites
Advertisement
You have unicode support enabled
Maybe auxDIBImageLoadA would force it to use ASCII
Also, someone should update these Nehe tutorials already. Get rid of that old junk known as GLaux

Share this post


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

  • Advertisement