From: curt Date: Fri, 24 Jul 1998 21:56:59 +0000 (+0000) Subject: Set near clip plane to 0.5 meters when close to the ground. Also, let the view get... X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=009c34bd23a557664adb1b3f49479186d1a8e3e6;p=flightgear.git Set near clip plane to 0.5 meters when close to the ground. Also, let the view get a bit closer to the ground before hitting the hard limit. --- diff --git a/Main/GLUTmain.cxx b/Main/GLUTmain.cxx index a840efd7a..5d9f00aa2 100644 --- a/Main/GLUTmain.cxx +++ b/Main/GLUTmain.cxx @@ -202,7 +202,7 @@ static void fgUpdateViewParams( void ) { if ( FG_Altitude * FEET_TO_METER - scenery.cur_elev > 10.0 ) { gluPerspective(current_options.get_fov(), v->win_ratio, 10.0, 100000.0); } else { - gluPerspective(current_options.get_fov(), v->win_ratio, 1.0, 100000.0); + gluPerspective(current_options.get_fov(), v->win_ratio, 0.5, 100000.0); // printf("Near ground, minimizing near clip plane\n"); } // } @@ -924,6 +924,9 @@ int main( int argc, char **argv ) { // $Log$ +// Revision 1.40 1998/07/24 21:56:59 curt +// Set near clip plane to 0.5 meters when close to the ground. Also, let the view get a bit closer to the ground before hitting the hard limit. +// // Revision 1.39 1998/07/24 21:39:08 curt // Debugging output tweaks. // Cast glGetString to (char *) to avoid compiler errors. diff --git a/Main/views.cxx b/Main/views.cxx index 7fc96f1c5..6c837c488 100644 --- a/Main/views.cxx +++ b/Main/views.cxx @@ -123,10 +123,10 @@ void fgVIEW::Update( fgFLIGHT *f ) { // p.lon & p.lat are already defined earlier, p.radius was set to // the sea level radius, so now we add in our altitude. if ( FG_Altitude * FEET_TO_METER > - (scenery.cur_elev + 3.758099 * METER_TO_FEET) ) { + (scenery.cur_elev + 0.5 * METER_TO_FEET) ) { p.radius += FG_Altitude * FEET_TO_METER; } else { - p.radius += scenery.cur_elev + 3.758099 * METER_TO_FEET; + p.radius += scenery.cur_elev + 0.5 * METER_TO_FEET; } abs_view_pos = fgPolarToCart3d(p); @@ -470,6 +470,9 @@ void fg_gluLookAt( GLdouble eyex, GLdouble eyey, GLdouble eyez, // $Log$ +// Revision 1.18 1998/07/24 21:57:02 curt +// Set near clip plane to 0.5 meters when close to the ground. Also, let the view get a bit closer to the ground before hitting the hard limit. +// // Revision 1.17 1998/07/24 21:39:12 curt // Debugging output tweaks. // Cast glGetString to (char *) to avoid compiler errors.