From 368443a4b36e73b11b5529eda5868617157c6367 Mon Sep 17 00:00:00 2001 From: Julian Smith Date: Sun, 1 Mar 2020 18:12:32 +0000 Subject: [PATCH] src/Viewer/view.cxx: Fixed Walker Orbit view. The fix is to add handling of target-lon-deg-path etc in View::recalcLookAt. --- src/Viewer/view.cxx | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/src/Viewer/view.cxx b/src/Viewer/view.cxx index f87a2549e..355ace49c 100644 --- a/src/Viewer/view.cxx +++ b/src/Viewer/view.cxx @@ -1031,6 +1031,25 @@ View::recalcLookAt () ); } + _target.setLongitudeDeg( + ViewPropertyEvaluator::getDoubleValue( + "((/sim/view[(/sim/current-view/view-number-raw)]/config/root)(/sim/view[(/sim/current-view/view-number-raw)]/config/target-lon-deg-path))", + _target.getLongitudeDeg() + ) + ); + _target.setLatitudeDeg( + ViewPropertyEvaluator::getDoubleValue( + "((/sim/view[(/sim/current-view/view-number-raw)]/config/root)(/sim/view[(/sim/current-view/view-number-raw)]/config/target-lat-deg-path))", + _target.getLatitudeDeg() + ) + ); + _target.setElevationFt( + ViewPropertyEvaluator::getDoubleValue( + "((/sim/view[(/sim/current-view/view-number-raw)]/config/root)(/sim/view[(/sim/current-view/view-number-raw)]/config/target-alt-ft-path))", + _target.getElevationFt() + ) + ); + if (_lookat_agl) { handleAGL(); }