multisampling and shit
authorJohn Tsiombikas <nuclear@mutantstargoat.com>
Sat, 17 Sep 2016 02:31:20 +0000 (05:31 +0300)
committerJohn Tsiombikas <nuclear@mutantstargoat.com>
Sat, 17 Sep 2016 02:31:20 +0000 (05:31 +0300)
src/gear.cc
src/main.cc

index 865679c..03a3b7d 100644 (file)
@@ -63,6 +63,7 @@ void Gear::draw() const
        glVertex3f(0, 0, -10);
        glVertex3f(0, 0, 10);
        glEnd();
+       glLineWidth(1.0);
        glPopAttrib();
 
        glPopMatrix();
index 0447748..b5d430b 100644 (file)
@@ -31,7 +31,7 @@ int main(int argc, char **argv)
 {
        glutInitWindowSize(1024, 768);
        glutInit(&argc, argv);
-       glutInitDisplayMode(GLUT_RGB | GLUT_DEPTH | GLUT_DOUBLE);
+       glutInitDisplayMode(GLUT_RGB | GLUT_DEPTH | GLUT_DOUBLE | GLUT_MULTISAMPLE);
        glutCreateWindow("Antikythera");
 
        glutDisplayFunc(display);
@@ -54,6 +54,7 @@ bool init()
 {
        glewInit();
 
+       glEnable(GL_MULTISAMPLE);
        glEnable(GL_DEPTH_TEST);
        glEnable(GL_CULL_FACE);
        glEnable(GL_LIGHTING);
@@ -177,7 +178,7 @@ void motion(int x, int y)
                glutPostRedisplay();
        }
        if(bnstate[2]) {
-               cam_dist += dy * 0.05;
+               cam_dist += dy * 0.01;
                if(cam_dist < 0.0) cam_dist = 0.0;
                glutPostRedisplay();
        }