I am using this code:
Init:
mytexdata := LoadBMP('tst.bmp');
glGenTextures(1, mytex);
glBindTexture(GL_TEXTURE_2D, mytex);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_NEAREST);
gluBuild2DMipmaps(GL_TEXTURE_2D, 3, mytexdata.sizeX, mytexdata.sizeY, GL_RGB, GL_UNSIGNED_BYTE, mytexdata.data);
[/quote]
Show:
glEnable(GL_LIGHTING);
glEnable(GL_TEXTURE_2D);
glColor4f(1.0, 1.0, 1.0, 1.0);
glBindTexture(GL_TEXTURE_2D, mytex);
glBegin(GL_QUADS);
glNormal3f( 0.0, 0.0, 1.0);
glTexCoord2f(0.0, 0.0); glVertex3f(-0.5, 19.5, 0.5);
glTexCoord2f(1.0, 0.0); glVertex3f( 0.5, 19.5, 0.5);
glTexCoord2f(1.0, 1.0); glVertex3f( 0.5, 20.5, 0.5);
glTexCoord2f(0.0, 1.0); glVertex3f(-0.5, 20.5, 0.5);
glEnd();
[/quote]
Iv'e attached the results: The picture on left is what I got, the picture on the right side is what I would like to see. Pls, advice. Why it seem so "blur"?