]> git.mxchange.org Git - flightgear.git/commitdiff
<option>top</option> draws tbi on top (vertically mirrored)
authormfranz <mfranz>
Fri, 28 Jul 2006 10:11:34 +0000 (10:11 +0000)
committermfranz <mfranz>
Fri, 28 Jul 2006 10:11:34 +0000 (10:11 +0000)
src/Instrumentation/HUD/HUD.hxx
src/Instrumentation/HUD/HUD_tbi.cxx

index 0afc934fdf36fea258e1ec88c3f866bb29728189..3c1baa3aa563621c0923b5ce5b182d1f85d8c2d7 100644 (file)
@@ -530,6 +530,7 @@ public:
 private:
     void draw_scale();
     void draw_tee();
+    void draw_line(float, float, float, float);
     void draw_tick(float angle, float r1, float r2, int side);
 
     Input _bank;
index dc8384e48e0cc5661a268a4fa03812740d7cfb76..69cb70d5a1fed28e6b3af9cc9113eb7176508ff2 100644 (file)
@@ -207,3 +207,13 @@ void HUD::TurnBankIndicator::draw_tick(float angle, float r1, float r2, int side
 }
 
 
+void HUD::TurnBankIndicator::draw_line(float x1, float y1, float x2, float y2)
+{
+    if (option_top()) {
+        float y = 2.0 * _center_y;  // mirror vertically
+        Item::draw_line(x1, y - y1, x2, y - y2);
+    } else
+        Item::draw_line(x1, y1, x2, y2);
+}
+
+