jayanth
11-25-2009, 05:14 AM
Hi all,
I am an absolute openGL beginner. I am learning iphone game programming using cocoa and openGL . Using the below function I did draw a slanted line successfully.
static const GLfloat squareVertices[] = {
-0.50f, -0.33f,
-0.55f, -0.38f,
};
.....
.....
.....
glLineWidth(2.0);
// Draw
glDrawArrays(GL_LINE_STRIP, 0, 2);
I did draw a line successfully. But it is not smooth. I tried some google and got the following antialiasing methods and inserted the below given line before glDrawArray() in the code above.
glEnable(GL_SMOOTH_LINE)
But when I tried to build I am getting an error.
error : GL_LINE_SMOOTH undeclared.
Can anyone help me...
I am an absolute openGL beginner. I am learning iphone game programming using cocoa and openGL . Using the below function I did draw a slanted line successfully.
static const GLfloat squareVertices[] = {
-0.50f, -0.33f,
-0.55f, -0.38f,
};
.....
.....
.....
glLineWidth(2.0);
// Draw
glDrawArrays(GL_LINE_STRIP, 0, 2);
I did draw a line successfully. But it is not smooth. I tried some google and got the following antialiasing methods and inserted the below given line before glDrawArray() in the code above.
glEnable(GL_SMOOTH_LINE)
But when I tried to build I am getting an error.
error : GL_LINE_SMOOTH undeclared.
Can anyone help me...