X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FMain%2Fbfi.hxx;h=dadebcfeb6142fe322530f241f31f9f2f3712d09;hb=f367e6d432525b40379529d5d64fe6d997ddf138;hp=75f617485d815dd33d5c7490bcf36b8ab0c64749;hpb=b6d04020740f2a6c67edc102b02edd58a18cd021;p=flightgear.git diff --git a/src/Main/bfi.hxx b/src/Main/bfi.hxx index 75f617485..dadebcfeb 100644 --- a/src/Main/bfi.hxx +++ b/src/Main/bfi.hxx @@ -4,6 +4,8 @@ // // Copyright (C) 2000 David Megginson - david@megginson.com // +// THIS INTERFACE IS DEPRECATED; USE THE PROPERTY MANAGER INSTEAD. +// // This program is free software; you can redistribute it and/or // modify it under the terms of the GNU General Public License as // published by the Free Software Foundation; either version 2 of the @@ -25,8 +27,13 @@ #include -FG_USING_NAMESPACE(std); +SG_USING_NAMESPACE(std); + +// Uncomment the appropriate line to get the desired heading hold +// autopilot behavior +// #define DEFAULT_AP_HEADING_LOCK FGAutopilot::FG_TRUE_HEADING_LOCK +#define DEFAULT_AP_HEADING_LOCK FGAutopilot::FG_DG_HEADING_LOCK /** * Big Flat Interface @@ -53,176 +60,153 @@ public: static void update (); // Simulation - static int getFlightModel (); - static const string getAircraft (); - static const string getAircraftDir (); - static time_t getTimeGMT (); - static const string &getGMTString (); - static bool getHUDVisible (); - static bool getPanelVisible (); - - static void setFlightModel (int flightModel); - static void setAircraft (const string &aircraft); - static void setAircraftDir (const string &aircraftDir); - static void setTimeGMT (time_t time); - static void setHUDVisible (bool hudVisible); - static void setPanelVisible (bool panelVisible); + static string getAircraftDir (); + static void setAircraftDir (string aircraftDir); + + static double getViewOffset (); + static void setViewOffset (double offset); + static double getGoalViewOffset (); + static void setGoalViewOffset (double offset); + + static string getDateString ();// ISO 8601 subset + static void setDateString (string time_string); // ISO 8601 subset + // deprecated + static string getGMTString (); // Position - static double getLatitude (); - static double getLongitude (); - static double getAltitude (); - static double getAGL (); + static double getLatitude (); // degrees + static void setLatitude (double latitude); // degrees - static void setLatitude (double latitude); - static void setLongitude (double longitude); - static void setAltitude (double altitude); + static double getLongitude (); // degrees + static void setLongitude (double longitude); // degrees + + static double getAltitude (); // feet + static void setAltitude (double altitude); // feet + + static double getAGL (); // feet // Attitude - static double getHeading (); // true heading - static double getHeadingMag (); // exact magnetic heading - static double getPitch (); - static double getRoll (); + static double getHeading (); // degrees + static void setHeading (double heading); // degrees + + static double getHeadingMag (); // degrees + + static double getPitch (); // degrees + static void setPitch (double pitch); // degrees - static void setHeading (double heading); - static void setPitch (double pitch); - static void setRoll (double roll); + static double getRoll (); // degrees + static void setRoll (double roll); // degrees // Engine - static double getRPM (); - static void setRPM ( double rpm ); - static double getEGT (); + static double getRPM (); // revolutions/minute + static void setRPM ( double rpm ); // revolutions/minute + + static double getEGT (); // deg Fahrenheit + static double getCHT (); // deg Fahrenheit + static double getMP (); // inches mercury + static double getFuelFlow (); // gals/hr + + // Consumables + static double getTank1Fuel (); // gals + static void setTank1Fuel( double gals ); + static double getTank2Fuel (); // gals + static void setTank2Fuel( double gals ); // Velocities - static double getAirspeed (); - static double getSideSlip (); - static double getVerticalSpeed (); - static double getSpeedNorth (); - static double getSpeedEast (); - static double getSpeedDown (); - - static void setSpeedNorth (double speed); - static void setSpeedEast (double speed); - static void setSpeedDown (double speed); - - - // Controls - static double getThrottle (); - static double getMixture (); - static double getPropAdvance (); - static double getFlaps (); - static double getAileron (); - static double getRudder (); - static double getElevator (); - static double getElevatorTrim (); - static double getBrakes (); - static double getLeftBrake (); - static double getRightBrake (); - static double getCenterBrake (); - - static void setThrottle (double throttle); - static void setMixture (double mixture); - static void setPropAdvance (double pitch); - static void setFlaps (double flaps); - static void setAileron (double aileron); - static void setRudder (double rudder); - static void setElevator (double elevator); - static void setElevatorTrim (double trim); - static void setBrakes (double brake); - static void setLeftBrake (double brake); - static void setRightBrake (double brake); - static void setCenterBrake (double brake); + static double getAirspeed (); // knots + static void setAirspeed (double speed); // knots + + static double getSideSlip (); // [unit??] + + static double getVerticalSpeed (); // feet/second + + static double getSpeedNorth (); // feet/second + + static double getSpeedEast (); // feet/second + + static double getSpeedDown (); // feet/second + +// static void setSpeedNorth (double speed); +// static void setSpeedEast (double speed); +// static void setSpeedDown (double speed); // Autopilot static bool getAPAltitudeLock (); - static double getAPAltitude (); - static bool getAPHeadingLock (); - static double getAPHeading (); - static double getAPHeadingMag (); - static void setAPAltitudeLock (bool lock); - static void setAPAltitude (double altitude); + + static bool getAPGSLock (); + static void setAPGSLock (bool lock); + + static double getAPAltitude (); // feet + static void setAPAltitude (double altitude); // feet + + static double getAPClimb (); // fpm + static void setAPClimb (double rate); // fpm + + static bool getAPHeadingLock (); static void setAPHeadingLock (bool lock); - static void setAPHeading (double heading); - static void setAPHeadingMag (double heading); + + static double getAPHeadingBug (); // degrees + static void setAPHeadingBug (double heading); // degrees + + static bool getAPWingLeveler (); + static void setAPWingLeveler (bool lock); static bool getAPNAV1Lock (); static void setAPNAV1Lock (bool lock); - // Radio Navigation - static double getNAV1Freq (); - static double getNAV1AltFreq (); - static double getNAV1Radial (); - static double getNAV1SelRadial (); - static double getNAV1DistDME (); - static bool getNAV1TO (); - static bool getNAV1FROM (); - static bool getNAV1InRange (); - static bool getNAV1DMEInRange (); - - static double getNAV2Freq (); - static double getNAV2AltFreq (); - static double getNAV2Radial (); - static double getNAV2SelRadial (); - static double getNAV2DistDME (); - static bool getNAV2TO (); - static bool getNAV2FROM (); - static bool getNAV2InRange (); - static bool getNAV2DMEInRange (); - - static double getADFFreq (); - static double getADFAltFreq (); - static double getADFRotation (); - - static void setNAV1Freq (double freq); - static void setNAV1AltFreq (double freq); - static void setNAV1SelRadial (double radial); - - static void setNAV2Freq (double freq); - static void setNAV2AltFreq (double freq); - static void setNAV2SelRadial (double radial); - - static void setADFFreq (double freq); - static void setADFAltFreq (double freq); - static void setADFRotation (double rot); + static bool getAPAutoThrottleLock (); + static void setAPAutoThrottleLock (bool lock); + + static double getAPRudderControl (); + static void setAPRudderControl (double value); + static double getAPElevatorControl (); + static void setAPElevatorControl (double value); + static double getAPThrottleControl (); + static void setAPThrottleControl (double value); + // GPS - static const string getTargetAirport (); - static bool getGPSLock (); - static double getGPSTargetLatitude (); - static double getGPSTargetLongitude (); + static string getTargetAirport (); + static void setTargetAirport (string targetAirport); - static void setTargetAirport (const string &targetAirport); + static bool getGPSLock (); static void setGPSLock (bool lock); - static void setGPSTargetLatitude (double latitude); - static void setGPSTargetLongitude (double longitude); + static double getGPSTargetLatitude (); // degrees - // Weather - static double getVisibility (); - static bool getClouds (); - static double getCloudsASL (); + static double getGPSTargetLongitude (); // degrees - static void setVisibility (double visiblity); - static void setClouds (bool clouds); - static void setCloudsASL (double cloudsASL); + + // Weather + static double getVisibility ();// meters + static void setVisibility (double visiblity); // meters + static double getWindNorth (); // feet/second + static void setWindNorth (double speed); // feet/second + static double getWindEast (); // feet/second + static void setWindEast (double speed); // feet/second + static double getWindDown (); // feet/second + static void setWindDown (double speed); // feet/second + + // View + static double getFOV (); // degrees + static void setFOV (double fov); // degrees + static void setViewAxisLong (double axis);// -1.0:1.0 + static void setViewAxisLat (double axis); // -1.0:1.0 // Time (this varies with time) huh, huh - static double getMagVar (); - static double getMagDip (); + static double getMagVar (); // degrees + static double getMagDip (); // degrees private: // Will cause a linking error if invoked. FGBFI (); - static void reinit (); - static void needReinit () { _needReinit = true; } - static bool _needReinit; }; // end of bfi.hxx