glAlphaFunc( GL_GREATER, 0 );
glEnable( GL_ALPHA_TEST );
glEnable(GL_BLEND);
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
or glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA)
QuoteBy file format I've meant the format of data A8R8G8B8 or something like that.
glAlphaFunc( GL_GREATER, 0 );
glEnable( GL_ALPHA_TEST );
QuoteI suspect that I need to explictly state somewhere the file format to OpenGL?
var
Textures: array[1..6] of GLuint;
Textures[4] := LoadGLTextureFromFile('Images\font_0.png');
glBindTexture(GL_TEXTURE_2D, Textures[4]);
glBegin(GL_QUADS);
glTexCoord2f(0, 0);
glVertex3f(-2, 2, 1);
glTexCoord2f(1, 0);
glVertex3f(2, 2, 1);
glTexCoord2f(1, 1);
glVertex3f(2, -2, 1);
glTexCoord2f(0, 1);
glVertex3f(-2, -2, 1);
glEnd();
Page created in 0.013 seconds with 20 queries.