]> git.mxchange.org Git - flightgear.git/blobdiff - src/Main/bfi.cxx
Added support for managing fov via the property manager so the --fov= option
[flightgear.git] / src / Main / bfi.cxx
index 8b749b2bdee84887e6d8021057b00c9a946b2ca7..63687fea0d9cc513f6d956a59fd5e9543fbd1c6d 100644 (file)
@@ -209,6 +209,7 @@ FGBFI::init ()
   fgTie("/environment/wind-down", getWindDown, setWindDown);
 
                                // View
+  fgTie("/sim/field-of-view", getFOV, setFOV);
   fgTie("/sim/view/axes/long", (double(*)())0, setViewAxisLong);
   fgTie("/sim/view/axes/lat", (double(*)())0, setViewAxisLat);
 
@@ -1289,6 +1290,18 @@ FGBFI::setWindDown (double speed)
 // View.
 ////////////////////////////////////////////////////////////////////////
 
+double
+FGBFI::getFOV ()
+{
+  globals->get_current_view()->get_fov();
+}
+
+void
+FGBFI::setFOV (double fov)
+{
+  globals->get_current_view()->set_fov( fov );
+}
+
 void
 FGBFI::setViewAxisLong (double axis)
 {