Flying on other planets: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
|||
Line 19: | Line 19: | ||
== File Locations == | == File Locations == | ||
The files are in /src/Enviroment | The files are in [https://gitorious.org/fg/flightgear/trees/next/src/Environment $FG_SRC/Enviroment]. The names are: | ||
The names are | * [https://gitorious.org/fg/flightgear/blobs/next/src/Environment/atmosphere.cxx atmosphere.cxx] | ||
* atmosphere.cxx | * [https://gitorious.org/fg/flightgear/blobs/next/src/Environment/atmosphere.hxx atmosphere.hxx] | ||
* atmosphere.hxx | * [https://gitorious.org/fg/flightgear/blobs/next/src/Environment/gravity.cxx gravity.cxx] | ||
* gravity.cxx | * [https://gitorious.org/fg/flightgear/blobs/next/src/Environment/gravity.hxx gravity.hxx] | ||
* gravity.hxx | |||
== Simulating gravity == | == Simulating gravity == |
Revision as of 22:38, 5 February 2013
Developed by | Wil Neeley |
---|---|
Written in | C++ |
OS | Only tested on Linux |
Platform | Ubuntu 12.04lts |
Development status | Active |
This Page is the documentation of trying to simulate flying on other planets in flightgear.
I located the files responsible for atmosphere and gravity in the flightgear source code.
File Locations
The files are in $FG_SRC/Enviroment. The names are:
Simulating gravity
After looking at the source code in the atmosphere and gravity files I decided to start by adjusting the gravity to that of titan because that planet is most likely able to be flown upon.
I changed lines 48-52 to
// Geodetic Reference System 1980 parameter
#define A 6576.0 // equatorial radius of Titan
#define B 6576.0 // semiminor axis
#define AGA (A*1.352) // A times normal gravity at equator
#define BGB (B*1.352) // B times normal gravity at pole
from
// original code
#define A 6378137.0 // equatorial radius of earth
#define B 6356752.3141 // semiminor axis
#define AGA (A*9.7803267715) // A times normal gravity at equator
#define BGB (B*9.8321863685) // B times normal gravity at pole
Now to compile ....