X-Git-Url: https://git.ucc.asn.au/?a=blobdiff_plain;ds=sidebyside;f=scene.c;h=cc687e7e5efb754ad6743843010c829b6e8fbf1e;hb=bab833c4516be2cf9015238dcefd6eef24cd19f8;hp=1cc9122a2ae68f1668050dfd08e898a02784b1cf;hpb=9bed07eee30fad2272cfba655542de064c2dc816;p=atyndall%2Fcits2231.git diff --git a/scene.c b/scene.c index 1cc9122..cc687e7 100644 --- a/scene.c +++ b/scene.c @@ -187,10 +187,10 @@ void windowReshape(int w, int h) { glMatrixMode(GL_PROJECTION); glLoadIdentity(); if (w <= h) - glOrtho(near, far, near*(GLfloat)h/(GLfloat)w, + glFrustum(near, far, near*(GLfloat)h/(GLfloat)w, far*(GLfloat)h/(GLfloat)w, -100, 100); else - glOrtho(near*(GLfloat)w/(GLfloat)h, + glFrustum(near*(GLfloat)w/(GLfloat)h, far*(GLfloat)w/(GLfloat)h, near, far, nearClip, farClip); glMatrixMode(GL_MODELVIEW); glLoadIdentity(); @@ -415,7 +415,7 @@ int main(int argc, char **argv) { glHint(GL_PERSPECTIVE_CORRECTION_HINT, GL_NICEST); - //glutReshapeFunc(windowReshape); + glutReshapeFunc(windowReshape); glutDisplayFunc(display); glutMouseFunc(mouse); glutKeyboardFunc(keyboard);