From: curt Date: Mon, 13 Jul 1998 21:28:00 +0000 (+0000) Subject: Converted the aoa scale to a radio altimeter. X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=21cba3900796a6156926c33945ca0266e096242f;p=flightgear.git Converted the aoa scale to a radio altimeter. --- diff --git a/Cockpit/cockpit.cxx b/Cockpit/cockpit.cxx index 165da001e..d984944ce 100644 --- a/Cockpit/cockpit.cxx +++ b/Cockpit/cockpit.cxx @@ -204,6 +204,17 @@ double get_altitude( void ) return( FG_Altitude * FEET_TO_METER /* -rough_elev */ ); } +double get_agl( void ) +{ + fgFLIGHT *f; + double agl; + + f = current_aircraft.flight; + agl = FG_Altitude * FEET_TO_METER - scenery.cur_elev; + + return( agl ); +} + double get_sideslip( void ) { fgFLIGHT *f; @@ -288,10 +299,13 @@ void fgCockpitUpdate( void ) { /* $Log$ -/* Revision 1.11 1998/07/13 21:00:45 curt -/* Integrated Charlies latest HUD updates. -/* Wrote access functions for current fgOPTIONS. +/* Revision 1.12 1998/07/13 21:28:00 curt +/* Converted the aoa scale to a radio altimeter. /* + * Revision 1.11 1998/07/13 21:00:45 curt + * Integrated Charlies latest HUD updates. + * Wrote access functions for current fgOPTIONS. + * * Revision 1.10 1998/07/08 14:41:08 curt * Renamed polar3d.h to polar3d.hxx * diff --git a/Cockpit/hud.cxx b/Cockpit/hud.cxx index 62a9a8041..1e2cf55d3 100644 --- a/Cockpit/hud.cxx +++ b/Cockpit/hud.cxx @@ -194,19 +194,19 @@ int fgHUDInit( fgAIRCRAFT * /* current_aircraft */ ) break; - case 3: // Angle of Attack + case 3: // Radio Altimeter HIptr = (instr_item *) new hud_card( 420, 195, 25, 150, - get_aoa, + get_agl, HUDS_LEFT | HUDS_VERT, - 50, -40, + 1000, 0, 1.0, - 2, 1, + 25, 5, 0, - 1, - 5.0, + 0, + 200.0, true); break; @@ -686,10 +686,13 @@ void fgUpdateHUD( void ) { } /* $Log$ -/* Revision 1.16 1998/07/13 21:00:47 curt -/* Integrated Charlies latest HUD updates. -/* Wrote access functions for current fgOPTIONS. +/* Revision 1.17 1998/07/13 21:28:02 curt +/* Converted the aoa scale to a radio altimeter. /* + * Revision 1.16 1998/07/13 21:00:47 curt + * Integrated Charlies latest HUD updates. + * Wrote access functions for current fgOPTIONS. + * * Revision 1.15 1998/07/08 14:41:08 curt * Renamed polar3d.h to polar3d.hxx * diff --git a/Cockpit/hud.hxx b/Cockpit/hud.hxx index e1d1150c3..b555568a4 100644 --- a/Cockpit/hud.hxx +++ b/Cockpit/hud.hxx @@ -165,6 +165,7 @@ extern double get_roll ( void ); extern double get_pitch ( void ); extern double get_heading ( void ); extern double get_altitude ( void ); +extern double get_agl ( void ); extern double get_sideslip ( void ); extern double get_frame_rate ( void ); extern double get_latitude ( void ); @@ -522,10 +523,13 @@ void fgHUDSetTimeMode( Hptr hud, int time_of_day ); #endif // _HUD_H /* $Log$ -/* Revision 1.9 1998/07/13 21:00:48 curt -/* Integrated Charlies latest HUD updates. -/* Wrote access functions for current fgOPTIONS. +/* Revision 1.10 1998/07/13 21:28:02 curt +/* Converted the aoa scale to a radio altimeter. /* + * Revision 1.9 1998/07/13 21:00:48 curt + * Integrated Charlies latest HUD updates. + * Wrote access functions for current fgOPTIONS. + * * Revision 1.8 1998/07/03 13:16:29 curt * Added Charlie Hotchkiss's HUD updates and improvementes. *