Badluck
02-01-2008, 07:08 AM
If you need more code, please tell me what part you need.
When i do the antialiasing, there is a diagonal line that appear in my quad, making it look a bit like 2 triangle, or simoply a diagonal line in my each of my square.
There is a background color.
If i try it without the anti-aliasing, the 2 triangle inside my quad aren't there.
i have a floor like a check game.
Quad Code
glBegin(GL_QUADS); // Plancher droit dans son monde.
glVertex3f(-fDemiLarg + fPosX1, HAUTEUR, -fDemiLarg + fPosZ1);
glVertex3f(-fDemiLarg + fPosX1, HAUTEUR, -fDemiLarg + fPosZ2);
glVertex3f(-fDemiLarg + fPosX2, HAUTEUR, -fDemiLarg + fPosZ2);
glVertex3f(-fDemiLarg + fPosX2, HAUTEUR, -fDemiLarg + fPosZ1);
glEnd();
Anti-Aliasing Code
if(ANTI_ALIASING_ON == (int)a2dCombin[ANTI_ALIASING][VALUE])
{
//glEnable(GL_BLEND);
//glEnable(GL_POLYGON_SMOOTH);
//glBlendFunc(GL_SRC_ALPHA_SATURATE,GL_ZERO);
//glHint(GL_POLYGON_SMOOTH_HINT,GL_FASTEST);
//glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
glEnable(GL_MULTISAMPLE_ARB);
}
When i do the antialiasing, there is a diagonal line that appear in my quad, making it look a bit like 2 triangle, or simoply a diagonal line in my each of my square.
There is a background color.
If i try it without the anti-aliasing, the 2 triangle inside my quad aren't there.
i have a floor like a check game.
Quad Code
glBegin(GL_QUADS); // Plancher droit dans son monde.
glVertex3f(-fDemiLarg + fPosX1, HAUTEUR, -fDemiLarg + fPosZ1);
glVertex3f(-fDemiLarg + fPosX1, HAUTEUR, -fDemiLarg + fPosZ2);
glVertex3f(-fDemiLarg + fPosX2, HAUTEUR, -fDemiLarg + fPosZ2);
glVertex3f(-fDemiLarg + fPosX2, HAUTEUR, -fDemiLarg + fPosZ1);
glEnd();
Anti-Aliasing Code
if(ANTI_ALIASING_ON == (int)a2dCombin[ANTI_ALIASING][VALUE])
{
//glEnable(GL_BLEND);
//glEnable(GL_POLYGON_SMOOTH);
//glBlendFunc(GL_SRC_ALPHA_SATURATE,GL_ZERO);
//glHint(GL_POLYGON_SMOOTH_HINT,GL_FASTEST);
//glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
glEnable(GL_MULTISAMPLE_ARB);
}