Commit 449861be authored by Don Gagne's avatar Don Gagne

parent 61bdd7f2
......@@ -6,7 +6,7 @@ Note: This file only contains high level features or important fixes.
### 3.6.0 - Daily Build
* No changes yet
* Major rewrite and bug fix pass through Structure Scan. Previous version had such bad problems that it can no longer be supported. Plans with Structure Scan will need to be recreated. New QGC will not load old Structure Scan plans.
### 3.5.1 - Not yet released
* Fix tile set count but in OfflineMaps which would cause image and elevation tile set to have incorrect counts and be incorrectly marked as download incomplete.
......
......@@ -18,8 +18,8 @@
"defaultValue": 50
},
{
"name": "Altitude",
"shortDescription": "Altitude for the bottom layer of the structure scan.",
"name": "ScanBottomAlt",
"shortDescription": "Altitude for the bottomost covered area of the scan. You can adjust this value such that the Bottom Layer Alt will fly above obstacles on the ground.",
"type": "double",
"units": "m",
"decimalPlaces": 1,
......@@ -43,7 +43,7 @@
},
{
"name": "StartFromTop",
"shortDescription": "Start scan from top of structure.",
"shortDescription": "Start scanning from top of structure.",
"type": "bool",
"defaultValue": true
}
......
......@@ -32,12 +32,13 @@ public:
Q_PROPERTY(CameraCalc* cameraCalc READ cameraCalc CONSTANT)
Q_PROPERTY(Fact* entranceAlt READ entranceAlt CONSTANT)
Q_PROPERTY(Fact* scanBottomAlt READ scanBottomAlt CONSTANT)
Q_PROPERTY(Fact* structureHeight READ structureHeight CONSTANT)
Q_PROPERTY(Fact* scanBottomAlt READ scanBottomAlt CONSTANT)
Q_PROPERTY(Fact* layers READ layers CONSTANT)
Q_PROPERTY(Fact* gimbalPitch READ gimbalPitch CONSTANT)
Q_PROPERTY(Fact* startFromTop READ startFromTop CONSTANT)
Q_PROPERTY(bool altitudeRelative READ altitudeRelative WRITE setAltitudeRelative NOTIFY altitudeRelativeChanged)
Q_PROPERTY(double bottomFlightAlt READ bottomFlightAlt NOTIFY bottomFlightAltChanged)
Q_PROPERTY(double topFlightAlt READ topFlightAlt NOTIFY topFlightAltChanged)
Q_PROPERTY(int cameraShots READ cameraShots NOTIFY cameraShotsChanged)
Q_PROPERTY(double timeBetweenShots READ timeBetweenShots NOTIFY timeBetweenShotsChanged)
Q_PROPERTY(QGCMapPolygon* structurePolygon READ structurePolygon CONSTANT)
......@@ -51,14 +52,13 @@ public:
Fact* gimbalPitch (void) { return &_gimbalPitchFact; }
Fact* startFromTop (void) { return &_startFromTopFact; }
bool altitudeRelative (void) const { return _altitudeRelative; }
double bottomFlightAlt (void);
double topFlightAlt (void);
int cameraShots (void) const;
double timeBetweenShots (void);
QGCMapPolygon* structurePolygon (void) { return &_structurePolygon; }
QGCMapPolygon* flightPolygon (void) { return &_flightPolygon; }
void setAltitudeRelative (bool altitudeRelative);
Q_INVOKABLE void rotateEntryPoint(void);
// Overrides from ComplexMissionItem
......@@ -90,8 +90,8 @@ public:
void applyNewAltitude (double newAltitude) final;
double additionalTimeDelay (void) const final { return 0; }
bool coordinateHasRelativeAltitude (void) const final { return _altitudeRelative; }
bool exitCoordinateHasRelativeAltitude (void) const final { return _altitudeRelative; }
bool coordinateHasRelativeAltitude (void) const final { return true; }
bool exitCoordinateHasRelativeAltitude (void) const final { return true; }
bool exitCoordinateSameAsEntry (void) const final { return true; }
void setDirty (bool dirty) final;
......@@ -111,7 +111,8 @@ public:
signals:
void cameraShotsChanged (int cameraShots);
void timeBetweenShotsChanged (void);
void altitudeRelativeChanged (bool altitudeRelative);
void bottomFlightAltChanged (void);
void topFlightAltChanged (void);
private slots:
void _setDirty(void);
......@@ -124,7 +125,7 @@ private slots:
void _recalcLayerInfo (void);
void _updateLastSequenceNumber (void);
void _updateGimbalPitch (void);
void _validateEntryVertex (void);
void _signalTopBottomAltChanged (void);
private:
void _setExitCoordinate(const QGeoCoordinate& coordinate);
......@@ -135,10 +136,8 @@ private:
QMap<QString, FactMetaData*> _metaDataMap;
int _sequenceNumber;
bool _dirty;
QGCMapPolygon _structurePolygon;
QGCMapPolygon _flightPolygon;
bool _altitudeRelative;
int _entryVertex; // Polygon vertext which is used as the mission entry point
bool _ignoreRecalc;
......@@ -157,7 +156,6 @@ private:
SettingsFact _entranceAltFact;
static const char* _jsonCameraCalcKey;
static const char* _jsonAltitudeRelativeKey;
static const char* _entranceAltName; // This value cannot be overriden
......
......@@ -11,7 +11,7 @@
#include "QGCApplication.h"
StructureScanComplexItemTest::StructureScanComplexItemTest(void)
: _offlineVehicle(NULL)
: _offlineVehicle(nullptr)
{
_polyPoints << QGeoCoordinate(47.633550640000003, -122.08982199) << QGeoCoordinate(47.634129020000003, -122.08887249) <<
QGeoCoordinate(47.633619320000001, -122.08811074) << QGeoCoordinate(47.633189139999999, -122.08900124);
......@@ -74,13 +74,6 @@ void StructureScanComplexItemTest::_testDirty(void)
_multiSpy->clearAllSignals();
}
rgFacts.clear();
QVERIFY(!_structureScanItem->dirty());
_structureScanItem->setAltitudeRelative(!_structureScanItem->altitudeRelative());
QVERIFY(_multiSpy->checkSignalByMask(dirtyChangedMask));
QVERIFY(_multiSpy->pullBoolFromSignalIndex(dirtyChangedIndex));
_structureScanItem->setDirty(false);
_multiSpy->clearAllSignals();
}
void StructureScanComplexItemTest::_initItem(void)
......
......@@ -110,38 +110,26 @@ Rectangle {
QGCLabel {
text: qsTr("Structure height")
visible: !missionItem.cameraCalc.isManualCamera
}
FactTextField {
fact: missionItem.structureHeight
Layout.fillWidth: true
visible: !missionItem.cameraCalc.isManualCamera
}
QGCLabel {
text: qsTr("# Layers")
visible: missionItem.cameraCalc.isManualCamera
}
FactTextField {
fact: missionItem.layers
Layout.fillWidth: true
visible: missionItem.cameraCalc.isManualCamera
}
QGCLabel { text: qsTr("Scan bottom alt") }
QGCLabel { text: qsTr("Scan Bottom Alt") }
FactTextField {
fact: missionItem.scanBottomAlt
Layout.fillWidth: true
}
QGCLabel { text: qsTr("Entrance/Exit alt") }
QGCLabel { text: qsTr("Entrance/Exit Alt") }
FactTextField {
fact: missionItem.entranceAlt
Layout.fillWidth: true
}
QGCLabel {
text: qsTr("Gimbal pitch")
text: qsTr("Gimbal Pitch")
visible: missionItem.cameraCalc.isManualCamera
}
FactTextField {
......@@ -149,13 +137,6 @@ Rectangle {
Layout.fillWidth: true
visible: missionItem.cameraCalc.isManualCamera
}
QGCCheckBox {
text: qsTr("Relative altitude")
checked: missionItem.altitudeRelative
Layout.columnSpan: 2
onClicked: missionItem.altitudeRelative = checked
}
}
Item {
......@@ -182,16 +163,22 @@ Rectangle {
QGCLabel { text: qsTr("Layers") }
QGCLabel { text: missionItem.layers.valueString }
QGCLabel { text: qsTr("Layer height") }
QGCLabel { text: qsTr("Layer Height") }
QGCLabel { text: missionItem.cameraCalc.adjustedFootprintFrontal.valueString + " " + QGroundControl.appSettingsDistanceUnitsString }
QGCLabel { text: qsTr("Photo count") }
QGCLabel { text: qsTr("Top Layer Alt") }
QGCLabel { text: QGroundControl.metersToAppSettingsDistanceUnits(missionItem.topFlightAlt).toFixed(1) + " " + QGroundControl.appSettingsDistanceUnitsString }
QGCLabel { text: qsTr("Bottom Layer Alt") }
QGCLabel { text: QGroundControl.metersToAppSettingsDistanceUnits(missionItem.bottomFlightAlt).toFixed(1) + " " + QGroundControl.appSettingsDistanceUnitsString }
QGCLabel { text: qsTr("Photo Count") }
QGCLabel { text: missionItem.cameraShots }
QGCLabel { text: qsTr("Photo interval") }
QGCLabel { text: qsTr("Photo Interval") }
QGCLabel { text: missionItem.timeBetweenShots.toFixed(1) + " " + qsTr("secs") }
QGCLabel { text: qsTr("Trigger distance") }
QGCLabel { text: qsTr("Trigger Distance") }
QGCLabel { text: missionItem.cameraCalc.adjustedFootprintSide.valueString + " " + QGroundControl.appSettingsDistanceUnitsString }
}
} // Column
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment