]> git.mxchange.org Git - flightgear.git/commitdiff
Make the indicator a little less jumpy.
authordavid <david>
Sun, 26 Jan 2003 20:57:57 +0000 (20:57 +0000)
committerdavid <david>
Sun, 26 Jan 2003 20:57:57 +0000 (20:57 +0000)
src/Instrumentation/turn_indicator.cxx

index 7e56b5b346a8ed49098ff5f603a8c44ff32dde8b..6cdaef9dc18cf15326df7a1a9399d5a7c3a92f73 100644 (file)
@@ -8,6 +8,11 @@
 #include <Main/util.hxx>
 
 
+// Use a bigger number to be more responsive, or a smaller number
+// to be more sluggish (the base time is 1.0).
+#define RESPONSIVENESS 0.25
+
+
 TurnIndicator::TurnIndicator ()
 {
 }
@@ -64,9 +69,7 @@ TurnIndicator::update (double dt)
 
                                 // Lag left, based on gyro spin
     rate = -2.5 + (factor * (rate + 2.5));
-
-                                // Add a lag, based on gyro spin
-    rate = fgGetLowPass(_last_rate, rate, dt/factor);
+    rate = fgGetLowPass(_last_rate, rate, dt*RESPONSIVENESS);
     _last_rate = rate;
     
                                 // Publish the indicated rate