|
|
|
@ -500,7 +500,7 @@ int TransectStyleComplexItem::_maxPathHeight(const TerrainPathQuery::PathHeightI
@@ -500,7 +500,7 @@ int TransectStyleComplexItem::_maxPathHeight(const TerrainPathQuery::PathHeightI
|
|
|
|
|
void TransectStyleComplexItem::_adjustForMaxRates(QList<CoordInfo_t>& transect) |
|
|
|
|
{ |
|
|
|
|
double maxClimbRate = _terrainAdjustMaxClimbRateFact.rawValue().toDouble(); |
|
|
|
|
double maxDescentRate = -_terrainAdjustMaxDescentRateFact.rawValue().toDouble(); |
|
|
|
|
double maxDescentRate = _terrainAdjustMaxDescentRateFact.rawValue().toDouble(); |
|
|
|
|
double flightSpeed = _missionFlightStatus.vehicleSpeed; |
|
|
|
|
|
|
|
|
|
if (qIsNaN(flightSpeed) || (maxClimbRate == 0 && maxDescentRate == 0)) { |
|
|
|
@ -510,6 +510,7 @@ void TransectStyleComplexItem::_adjustForMaxRates(QList<CoordInfo_t>& transect)
@@ -510,6 +510,7 @@ void TransectStyleComplexItem::_adjustForMaxRates(QList<CoordInfo_t>& transect)
|
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if (maxClimbRate > 0) { |
|
|
|
|
// Adjust climb rates
|
|
|
|
|
bool climbRateAdjusted; |
|
|
|
|
do { |
|
|
|
@ -534,9 +535,12 @@ void TransectStyleComplexItem::_adjustForMaxRates(QList<CoordInfo_t>& transect)
@@ -534,9 +535,12 @@ void TransectStyleComplexItem::_adjustForMaxRates(QList<CoordInfo_t>& transect)
|
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} while (climbRateAdjusted); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if (maxDescentRate > 0) { |
|
|
|
|
// Adjust descent rates
|
|
|
|
|
bool descentRateAdjusted; |
|
|
|
|
maxDescentRate = -maxDescentRate; |
|
|
|
|
do { |
|
|
|
|
//qDebug() << "descent rate pass";
|
|
|
|
|
descentRateAdjusted = false; |
|
|
|
@ -559,6 +563,7 @@ void TransectStyleComplexItem::_adjustForMaxRates(QList<CoordInfo_t>& transect)
@@ -559,6 +563,7 @@ void TransectStyleComplexItem::_adjustForMaxRates(QList<CoordInfo_t>& transect)
|
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} while (descentRateAdjusted); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
void TransectStyleComplexItem::_adjustForTolerance(QList<CoordInfo_t>& transect) |
|
|
|
|