Commit 69f3e50a authored by Valentin Platzgummer's avatar Valentin Platzgummer

wimaDok edited

parent d346ca5a
,valentin,rick,31.01.2020 11:41,file:///home/valentin/.config/libreoffice/4;
\ No newline at end of file
\newcommand{\etc}{etc.\xspace}
\newcommand{\qgc}{QGroundControl\xspace} \newcommand{\qgc}{QGroundControl\xspace}
\newcommand{\wima}{WiMA\xspace} \newcommand{\wima}{WiMA\xspace}
\newcommand{\ethz}{ETH Zürich\xspace} \newcommand{\ethz}{ETH Zürich\xspace}
\newcommand{\uav}{Unmaned Arial Vehicle\xspace} \newcommand{\uav}{Unmaned Arial Vehicle\xspace}
\newcommand{\gitrepourl}{\url{https://dummyurl.com}}
\newcommand{\qgcdocurl}{\url{https://docs.qgroundcontrol.com/en/}}
...@@ -5,37 +5,60 @@ ...@@ -5,37 +5,60 @@
\@writefile{toc}{\contentsline {subsection}{\numberline {1.2}Scope}{3}} \@writefile{toc}{\contentsline {subsection}{\numberline {1.2}Scope}{3}}
\@writefile{toc}{\contentsline {section}{\numberline {2}System Description}{3}} \@writefile{toc}{\contentsline {section}{\numberline {2}System Description}{3}}
\@writefile{toc}{\contentsline {subsection}{\numberline {2.1}Key Features}{3}} \@writefile{toc}{\contentsline {subsection}{\numberline {2.1}Key Features}{3}}
\@writefile{toc}{\contentsline {subsection}{\numberline {2.2}Structure of QGroundControl with WiMA-Extension}{3}} \@writefile{toc}{\contentsline {subsection}{\numberline {2.2}Inventory}{3}}
\@writefile{lof}{\contentsline {figure}{\numberline {1}{\ignorespaces Detail view of the QGC window, which appears after start-up. Marked in red is the button for switching to the Plan View Window, green indicates the Flight View button (current window) and marked in magenta is the button for switching to the WiMA Main Window.}}{4}} \@writefile{toc}{\contentsline {section}{\numberline {3}Menus and Instructions}{3}}
\newlabel{fig:QGCMainButtonExplain}{{1}{4}} \@writefile{toc}{\contentsline {subsection}{\numberline {3.1}Brief Summary}{3}}
\@writefile{toc}{\contentsline {subsection}{\numberline {2.3}WiMA Main Window}{4}} \@writefile{lof}{\contentsline {figure}{\numberline {1}{\ignorespaces Flight view tool strip. Used to command the vehicle.}}{4}}
\@writefile{toc}{\contentsline {subsubsection}{\numberline {2.3.1}WiMA Tool Strip}{4}} \newlabel{fig:flightViewToolStrip}{{1}{4}}
\newlabel{sec:wimaToolStrip}{{2.3.1}{4}} \@writefile{lof}{\contentsline {figure}{\numberline {2}{\ignorespaces Detail view of the QGC window, which appears after start-up. Marked in red is the button for switching to the Plan View Window, green indicates the Flight View button (current window) and marked in magenta is the button for switching to the WiMA Main Window.}}{4}}
\@writefile{lof}{\contentsline {figure}{\numberline {2}{\ignorespaces WiMA Toolstrip inside WiMA Main Window.}}{4}} \newlabel{fig:QGCMainButtonExplain}{{2}{4}}
\newlabel{fig:WimaToolstrip}{{2}{4}} \@writefile{lof}{\contentsline {figure}{\numberline {3}{\ignorespaces Flight view top indicator strip. Show's data about a connected vehicle. Among others satellite count, telemetry quality, battery level etc.\xspace are displayed.}}{5}}
\@writefile{toc}{\contentsline {subsubsection}{\numberline {2.3.2}WiMA Areas}{5}} \newlabel{fig:flightViewTopIndicatorStrip}{{3}{5}}
\@writefile{lof}{\contentsline {figure}{\numberline {3}{\ignorespaces WiMA Item Editor at the right edge of the WiMA Main Window.}}{6}} \@writefile{toc}{\contentsline {subsection}{\numberline {3.2}WiMA\xspace View}{5}}
\newlabel{fig:WimaItemEditor}{{3}{6}} \@writefile{toc}{\contentsline {subsubsection}{\numberline {3.2.1}WiMA Tool Strip}{5}}
\@writefile{lof}{\contentsline {figure}{\numberline {4}{\ignorespaces Flight path of a real vehicle (red line).}}{6}} \newlabel{sec:wimaToolStrip}{{3.2.1}{5}}
\newlabel{fig:optimPaht}{{4}{6}} \@writefile{lof}{\contentsline {figure}{\numberline {4}{\ignorespaces WiMA Toolstrip inside WiMA Main Window.}}{5}}
\@writefile{toc}{\contentsline {subsubsection}{\numberline {2.3.3}The generated Flight Path}{6}} \newlabel{fig:WimaToolstrip}{{4}{5}}
\@writefile{toc}{\contentsline {subsubsection}{\numberline {2.3.4}Circular Survey}{6}} \@writefile{toc}{\contentsline {subsubsection}{\numberline {3.2.2}WiMA Areas}{5}}
\newlabel{sec:circularSurvey}{{2.3.4}{6}} \newlabel{sec:wimaAreas}{{3.2.2}{5}}
\@writefile{lof}{\contentsline {figure}{\numberline {5}{\ignorespaces Adjust the vertex by dragging it's handle.}}{7}} \@writefile{lof}{\contentsline {figure}{\numberline {5}{\ignorespaces WiMA\xspace area with border polygon. Shown is a measurement area (green).}}{6}}
\newlabel{fig:vertexHandle}{{5}{7}} \newlabel{fig:wimaArea}{{5}{6}}
\@writefile{lof}{\contentsline {figure}{\numberline {6}{\ignorespaces Add vertices by hitting the plus sign.}}{7}} \@writefile{toc}{\contentsline {subsubsection}{\numberline {3.2.3}Saving and Loading WiMA\xspace Missions}{6}}
\newlabel{fig:vertexPlus}{{6}{7}} \newlabel{sec:savingLoadingWima}{{3.2.3}{6}}
\@writefile{lof}{\contentsline {figure}{\numberline {7}{\ignorespaces Move any area by dragging its drag handle.}}{7}} \@writefile{toc}{\contentsline {subsubsection}{\numberline {3.2.4}Clearing WiMA\xspace Missions}{6}}
\newlabel{fig:moveArea}{{7}{7}} \newlabel{sec:clearingWima}{{3.2.4}{6}}
\@writefile{lof}{\contentsline {figure}{\numberline {8}{\ignorespaces A valid configuration of Measurement, Service Area and Corridor.}}{7}} \@writefile{toc}{\contentsline {subsubsection}{\numberline {3.2.5}Uploading, Downloading and Clearing vehicle Missions}{6}}
\newlabel{fig:validConfig}{{8}{7}} \newlabel{sec:uploadDownloadVehicle}{{3.2.5}{6}}
\@writefile{lof}{\contentsline {figure}{\numberline {9}{\ignorespaces Checking the Mission radio button displays the mission items.}}{8}} \@writefile{lof}{\contentsline {figure}{\numberline {6}{\ignorespaces WiMA Item Editor at the right edge of the WiMA Main Window.}}{7}}
\newlabel{fig:wimaRadioButtons}{{9}{8}} \newlabel{fig:WimaItemEditor}{{6}{7}}
\@writefile{lof}{\contentsline {figure}{\numberline {10}{\ignorespaces The flight path generated from the areas depicted in fig. 8\hbox {}.}}{8}} \@writefile{lof}{\contentsline {figure}{\numberline {7}{\ignorespaces Flight path of a real vehicle (red line).}}{7}}
\newlabel{fig:flightPath}{{10}{8}} \newlabel{fig:optimPaht}{{7}{7}}
\@writefile{lof}{\contentsline {figure}{\numberline {11}{\ignorespaces An example of a Circular Survey pattern.}}{9}} \@writefile{lof}{\contentsline {figure}{\numberline {8}{\ignorespaces Adjust the vertex by dragging it's handle.}}{7}}
\newlabel{fig:circularSurvey}{{11}{9}} \newlabel{fig:vertexHandle}{{8}{7}}
\@writefile{toc}{\contentsline {subsection}{\numberline {2.4}ArduPilot Simulator}{10}} \@writefile{lof}{\contentsline {figure}{\numberline {9}{\ignorespaces Add vertices by hitting the plus sign.}}{7}}
\newlabel{fig:vertexPlus}{{9}{7}}
\@writefile{lof}{\contentsline {figure}{\numberline {10}{\ignorespaces Move any area by dragging its drag handle.}}{7}}
\newlabel{fig:moveArea}{{10}{7}}
\@writefile{lof}{\contentsline {figure}{\numberline {11}{\ignorespaces A valid configuration of Measurement, Service Area and Corridor.}}{8}}
\newlabel{fig:validConfig}{{11}{8}}
\@writefile{lof}{\contentsline {figure}{\numberline {12}{\ignorespaces WiMA\xspace tool strip save/load dialog.}}{8}}
\newlabel{fig:wimaViewSaveLoad}{{12}{8}}
\@writefile{lof}{\contentsline {figure}{\numberline {13}{\ignorespaces Checking the Mission radio button, on the right hand side, displays the mission items.}}{9}}
\newlabel{fig:wimaRadioButtons}{{13}{9}}
\@writefile{toc}{\contentsline {subsubsection}{\numberline {3.2.6}Inserting WiMA\xspace Areas}{9}}
\newlabel{sec:insertAreas}{{3.2.6}{9}}
\@writefile{toc}{\contentsline {subsubsection}{\numberline {3.2.7}Generating a WiMA\xspace flight plan}{9}}
\newlabel{sec:generatingFlightPlan}{{3.2.7}{9}}
\@writefile{toc}{\contentsline {subsubsection}{\numberline {3.2.8}Navigating the Map}{9}}
\newlabel{sec:navigatingMap}{{3.2.8}{9}}
\@writefile{lof}{\contentsline {figure}{\numberline {14}{\ignorespaces The flight path generated from the areas depicted in fig. 11\hbox {}.}}{10}}
\newlabel{fig:flightPath}{{14}{10}}
\@writefile{toc}{\contentsline {subsubsection}{\numberline {3.2.9}How to display the generated flight plan}{10}}
\@writefile{toc}{\contentsline {subsubsection}{\numberline {3.2.10}Circular Survey}{10}}
\newlabel{sec:circularSurvey}{{3.2.10}{10}}
\@writefile{lof}{\contentsline {figure}{\numberline {15}{\ignorespaces The circular survey item editor. Can be found at the right edge of the screen.}}{11}}
\newlabel{fig:circularSurveyItemEditor}{{15}{11}}
\@writefile{toc}{\contentsline {subsection}{\numberline {3.3}ArduPilot Simulator}{12}}
\global\@namedef{scr@dte@section@lastmaxnumwidth}{10.84047pt} \global\@namedef{scr@dte@section@lastmaxnumwidth}{10.84047pt}
\global\@namedef{scr@dte@subsection@lastmaxnumwidth}{18.37163pt} \global\@namedef{scr@dte@subsection@lastmaxnumwidth}{18.37163pt}
\global\@namedef{scr@dte@subsubsection@lastmaxnumwidth}{26.8883pt} \global\@namedef{scr@dte@subsubsection@lastmaxnumwidth}{32.36331pt}
No preview for this file type
No preview for this file type
This diff is collapsed.
...@@ -3,10 +3,18 @@ ...@@ -3,10 +3,18 @@
\contentsline {subsection}{\numberline {1.2}Scope}{3} \contentsline {subsection}{\numberline {1.2}Scope}{3}
\contentsline {section}{\numberline {2}System Description}{3} \contentsline {section}{\numberline {2}System Description}{3}
\contentsline {subsection}{\numberline {2.1}Key Features}{3} \contentsline {subsection}{\numberline {2.1}Key Features}{3}
\contentsline {subsection}{\numberline {2.2}Structure of QGroundControl with WiMA-Extension}{3} \contentsline {subsection}{\numberline {2.2}Inventory}{3}
\contentsline {subsection}{\numberline {2.3}WiMA Main Window}{4} \contentsline {section}{\numberline {3}Menus and Instructions}{3}
\contentsline {subsubsection}{\numberline {2.3.1}WiMA Tool Strip}{4} \contentsline {subsection}{\numberline {3.1}Brief Summary}{3}
\contentsline {subsubsection}{\numberline {2.3.2}WiMA Areas}{5} \contentsline {subsection}{\numberline {3.2}WiMA\xspace View}{5}
\contentsline {subsubsection}{\numberline {2.3.3}The generated Flight Path}{6} \contentsline {subsubsection}{\numberline {3.2.1}WiMA Tool Strip}{5}
\contentsline {subsubsection}{\numberline {2.3.4}Circular Survey}{6} \contentsline {subsubsection}{\numberline {3.2.2}WiMA Areas}{5}
\contentsline {subsection}{\numberline {2.4}ArduPilot Simulator}{10} \contentsline {subsubsection}{\numberline {3.2.3}Saving and Loading WiMA\xspace Missions}{6}
\contentsline {subsubsection}{\numberline {3.2.4}Clearing WiMA\xspace Missions}{6}
\contentsline {subsubsection}{\numberline {3.2.5}Uploading, Downloading and Clearing vehicle Missions}{6}
\contentsline {subsubsection}{\numberline {3.2.6}Inserting WiMA\xspace Areas}{9}
\contentsline {subsubsection}{\numberline {3.2.7}Generating a WiMA\xspace flight plan}{9}
\contentsline {subsubsection}{\numberline {3.2.8}Navigating the Map}{9}
\contentsline {subsubsection}{\numberline {3.2.9}How to display the generated flight plan}{10}
\contentsline {subsubsection}{\numberline {3.2.10}Circular Survey}{10}
\contentsline {subsection}{\numberline {3.3}ArduPilot Simulator}{12}
WimaDok/pics/WiMAItemEditor.png

36.9 KB | W: | H:

WimaDok/pics/WiMAItemEditor.png

31.8 KB | W: | H:

WimaDok/pics/WiMAItemEditor.png
WimaDok/pics/WiMAItemEditor.png
WimaDok/pics/WiMAItemEditor.png
WimaDok/pics/WiMAItemEditor.png
  • 2-up
  • Swipe
  • Onion skin
WimaDok/pics/WiMAToolstrip.png

127 KB | W: | H:

WimaDok/pics/WiMAToolstrip.png

50.4 KB | W: | H:

WimaDok/pics/WiMAToolstrip.png
WimaDok/pics/WiMAToolstrip.png
WimaDok/pics/WiMAToolstrip.png
WimaDok/pics/WiMAToolstrip.png
  • 2-up
  • Swipe
  • Onion skin
...@@ -138,8 +138,8 @@ Rectangle { ...@@ -138,8 +138,8 @@ Rectangle {
visible: transectsHeader.checked visible: transectsHeader.checked
FactCheckBox { FactCheckBox {
text: qsTr("Snake Path") text: qsTr("Fixed Direction")
fact: missionItem.isSnakePath fact: missionItem.fixedDirection
} }
QGCCheckBox { QGCCheckBox {
......
...@@ -28,8 +28,8 @@ ...@@ -28,8 +28,8 @@
"defaultValue": 5.0 "defaultValue": 5.0
}, },
{ {
"name": "IsSnakePath", "name": "FixedDirection",
"shortDescription": "Determines whether the transects are arranged in a snake or a zig-zag manner.", "shortDescription": "Determines whether all transects have the same direction or not.",
"type": "bool", "type": "bool",
"defaultValue": 1 "defaultValue": 1
}, },
......
...@@ -8,7 +8,7 @@ const char* CircularSurveyComplexItem::settingsGroup = "CircularSur ...@@ -8,7 +8,7 @@ const char* CircularSurveyComplexItem::settingsGroup = "CircularSur
const char* CircularSurveyComplexItem::deltaRName = "DeltaR"; const char* CircularSurveyComplexItem::deltaRName = "DeltaR";
const char* CircularSurveyComplexItem::deltaAlphaName = "DeltaAlpha"; const char* CircularSurveyComplexItem::deltaAlphaName = "DeltaAlpha";
const char* CircularSurveyComplexItem::transectMinLengthName = "TransectMinLength"; const char* CircularSurveyComplexItem::transectMinLengthName = "TransectMinLength";
const char* CircularSurveyComplexItem::isSnakePathName = "IsSnakePath"; const char* CircularSurveyComplexItem::fixedDirectionName = "FixedDirection";
const char* CircularSurveyComplexItem::reverseName = "Reverse"; const char* CircularSurveyComplexItem::reverseName = "Reverse";
const char* CircularSurveyComplexItem::maxWaypointsName = "MaxWaypoints"; const char* CircularSurveyComplexItem::maxWaypointsName = "MaxWaypoints";
...@@ -17,7 +17,7 @@ const char* CircularSurveyComplexItem::jsonComplexItemTypeValue = "circula ...@@ -17,7 +17,7 @@ const char* CircularSurveyComplexItem::jsonComplexItemTypeValue = "circula
const char* CircularSurveyComplexItem::jsonDeltaRKey = "deltaR"; const char* CircularSurveyComplexItem::jsonDeltaRKey = "deltaR";
const char* CircularSurveyComplexItem::jsonDeltaAlphaKey = "deltaAlpha"; const char* CircularSurveyComplexItem::jsonDeltaAlphaKey = "deltaAlpha";
const char* CircularSurveyComplexItem::jsonTransectMinLengthKey = "transectMinLength"; const char* CircularSurveyComplexItem::jsonTransectMinLengthKey = "transectMinLength";
const char* CircularSurveyComplexItem::jsonIsSnakePathKey = "isSnakePath"; const char* CircularSurveyComplexItem::jsonfixedDirectionKey = "fixedDirection";
const char* CircularSurveyComplexItem::jsonReverseKey = "reverse"; const char* CircularSurveyComplexItem::jsonReverseKey = "reverse";
const char* CircularSurveyComplexItem::jsonReferencePointLatKey = "referencePointLat"; const char* CircularSurveyComplexItem::jsonReferencePointLatKey = "referencePointLat";
const char* CircularSurveyComplexItem::jsonReferencePointLongKey = "referencePointLong"; const char* CircularSurveyComplexItem::jsonReferencePointLongKey = "referencePointLong";
...@@ -30,7 +30,7 @@ CircularSurveyComplexItem::CircularSurveyComplexItem(Vehicle *vehicle, bool flyV ...@@ -30,7 +30,7 @@ CircularSurveyComplexItem::CircularSurveyComplexItem(Vehicle *vehicle, bool flyV
, _deltaR (settingsGroup, _metaDataMap[deltaRName]) , _deltaR (settingsGroup, _metaDataMap[deltaRName])
, _deltaAlpha (settingsGroup, _metaDataMap[deltaAlphaName]) , _deltaAlpha (settingsGroup, _metaDataMap[deltaAlphaName])
, _transectMinLength (settingsGroup, _metaDataMap[transectMinLengthName]) , _transectMinLength (settingsGroup, _metaDataMap[transectMinLengthName])
, _isSnakePath (settingsGroup, _metaDataMap[isSnakePathName]) , _fixedDirection (settingsGroup, _metaDataMap[fixedDirectionName])
, _reverse (settingsGroup, _metaDataMap[reverseName]) , _reverse (settingsGroup, _metaDataMap[reverseName])
, _maxWaypoints (settingsGroup, _metaDataMap[maxWaypointsName]) , _maxWaypoints (settingsGroup, _metaDataMap[maxWaypointsName])
, _isInitialized (false) , _isInitialized (false)
...@@ -42,7 +42,7 @@ CircularSurveyComplexItem::CircularSurveyComplexItem(Vehicle *vehicle, bool flyV ...@@ -42,7 +42,7 @@ CircularSurveyComplexItem::CircularSurveyComplexItem(Vehicle *vehicle, bool flyV
connect(&_deltaR, &Fact::valueChanged, this, &CircularSurveyComplexItem::_triggerSlowRecalc); connect(&_deltaR, &Fact::valueChanged, this, &CircularSurveyComplexItem::_triggerSlowRecalc);
connect(&_deltaAlpha, &Fact::valueChanged, this, &CircularSurveyComplexItem::_triggerSlowRecalc); connect(&_deltaAlpha, &Fact::valueChanged, this, &CircularSurveyComplexItem::_triggerSlowRecalc);
connect(&_transectMinLength, &Fact::valueChanged, this, &CircularSurveyComplexItem::_triggerSlowRecalc); connect(&_transectMinLength, &Fact::valueChanged, this, &CircularSurveyComplexItem::_triggerSlowRecalc);
connect(&_isSnakePath, &Fact::valueChanged, this, &CircularSurveyComplexItem::_triggerSlowRecalc); connect(&_fixedDirection, &Fact::valueChanged, this, &CircularSurveyComplexItem::_triggerSlowRecalc);
connect(&_maxWaypoints, &Fact::valueChanged, this, &CircularSurveyComplexItem::_triggerSlowRecalc); connect(&_maxWaypoints, &Fact::valueChanged, this, &CircularSurveyComplexItem::_triggerSlowRecalc);
connect(&_reverse, &Fact::valueChanged, this, &CircularSurveyComplexItem::_reverseTransects); connect(&_reverse, &Fact::valueChanged, this, &CircularSurveyComplexItem::_reverseTransects);
connect(this, &CircularSurveyComplexItem::refPointChanged, this, &CircularSurveyComplexItem::_triggerSlowRecalc); connect(this, &CircularSurveyComplexItem::refPointChanged, this, &CircularSurveyComplexItem::_triggerSlowRecalc);
...@@ -120,7 +120,7 @@ bool CircularSurveyComplexItem::load(const QJsonObject &complexObject, int seque ...@@ -120,7 +120,7 @@ bool CircularSurveyComplexItem::load(const QJsonObject &complexObject, int seque
{ jsonDeltaRKey, QJsonValue::Double, true }, { jsonDeltaRKey, QJsonValue::Double, true },
{ jsonDeltaAlphaKey, QJsonValue::Double, true }, { jsonDeltaAlphaKey, QJsonValue::Double, true },
{ jsonTransectMinLengthKey, QJsonValue::Double, true }, { jsonTransectMinLengthKey, QJsonValue::Double, true },
{ jsonIsSnakePathKey, QJsonValue::Bool, true }, { jsonfixedDirectionKey, QJsonValue::Bool, true },
{ jsonReverseKey, QJsonValue::Bool, true }, { jsonReverseKey, QJsonValue::Bool, true },
{ jsonReferencePointLatKey, QJsonValue::Double, true }, { jsonReferencePointLatKey, QJsonValue::Double, true },
{ jsonReferencePointLongKey, QJsonValue::Double, true }, { jsonReferencePointLongKey, QJsonValue::Double, true },
...@@ -158,7 +158,7 @@ bool CircularSurveyComplexItem::load(const QJsonObject &complexObject, int seque ...@@ -158,7 +158,7 @@ bool CircularSurveyComplexItem::load(const QJsonObject &complexObject, int seque
_referencePoint.setLongitude (complexObject[jsonReferencePointLongKey].toDouble()); _referencePoint.setLongitude (complexObject[jsonReferencePointLongKey].toDouble());
_referencePoint.setLatitude (complexObject[jsonReferencePointLatKey].toDouble()); _referencePoint.setLatitude (complexObject[jsonReferencePointLatKey].toDouble());
_referencePoint.setAltitude (complexObject[jsonReferencePointAltKey].toDouble()); _referencePoint.setAltitude (complexObject[jsonReferencePointAltKey].toDouble());
_isSnakePath.setRawValue (complexObject[jsonIsSnakePathKey].toBool()); _fixedDirection.setRawValue (complexObject[jsonfixedDirectionKey].toBool());
_reverse.setRawValue (complexObject[jsonReverseKey].toBool()); _reverse.setRawValue (complexObject[jsonReverseKey].toBool());
setIsInitialized(true); setIsInitialized(true);
...@@ -186,7 +186,7 @@ void CircularSurveyComplexItem::save(QJsonArray &planItems) ...@@ -186,7 +186,7 @@ void CircularSurveyComplexItem::save(QJsonArray &planItems)
saveObject[jsonDeltaRKey] = _deltaR.rawValue().toDouble(); saveObject[jsonDeltaRKey] = _deltaR.rawValue().toDouble();
saveObject[jsonDeltaAlphaKey] = _deltaAlpha.rawValue().toDouble(); saveObject[jsonDeltaAlphaKey] = _deltaAlpha.rawValue().toDouble();
saveObject[jsonTransectMinLengthKey] = _transectMinLength.rawValue().toDouble(); saveObject[jsonTransectMinLengthKey] = _transectMinLength.rawValue().toDouble();
saveObject[jsonIsSnakePathKey] = _isSnakePath.rawValue().toBool(); saveObject[jsonfixedDirectionKey] = _fixedDirection.rawValue().toBool();
saveObject[jsonReverseKey] = _reverse.rawValue().toBool(); saveObject[jsonReverseKey] = _reverse.rawValue().toBool();
saveObject[jsonReferencePointLongKey] = _referencePoint.longitude(); saveObject[jsonReferencePointLongKey] = _referencePoint.longitude();
saveObject[jsonReferencePointLatKey] = _referencePoint.latitude(); saveObject[jsonReferencePointLatKey] = _referencePoint.latitude();
...@@ -317,7 +317,7 @@ void CircularSurveyComplexItem::_rebuildTransectsFast() ...@@ -317,7 +317,7 @@ void CircularSurveyComplexItem::_rebuildTransectsFast()
return; return;
/// optimize path to snake or zig-zag pattern /// optimize path to snake or zig-zag pattern
bool isSnakePattern = _isSnakePath.rawValue().toBool(); bool fixedDirectionBool = _fixedDirection.rawValue().toBool();
QVector<QPointF> currentSection = transectPath.takeFirst(); QVector<QPointF> currentSection = transectPath.takeFirst();
if ( currentSection.isEmpty() ) if ( currentSection.isEmpty() )
return; return;
...@@ -347,7 +347,7 @@ void CircularSurveyComplexItem::_rebuildTransectsFast() ...@@ -347,7 +347,7 @@ void CircularSurveyComplexItem::_rebuildTransectsFast()
} }
} }
currentSection = transectPath.takeAt(index); currentSection = transectPath.takeAt(index);
if (reversePath && isSnakePattern) { if (reversePath && !fixedDirectionBool) {
PolygonCalculus::reversePath(currentSection); PolygonCalculus::reversePath(currentSection);
} }
} }
...@@ -406,7 +406,7 @@ void CircularSurveyComplexItem::_rebuildTransectsSlow() ...@@ -406,7 +406,7 @@ void CircularSurveyComplexItem::_rebuildTransectsSlow()
return; return;
// optimize path to snake or zig-zag pattern // optimize path to snake or zig-zag pattern
const bool isSnakePathBool = _isSnakePath.rawValue().toBool(); const bool fixedDirectionBool = _fixedDirection.rawValue().toBool();
QVector<QPointF> currentSection = transectPath.takeFirst(); if ( currentSection.isEmpty() ) return; QVector<QPointF> currentSection = transectPath.takeFirst(); if ( currentSection.isEmpty() ) return;
QVector<QPointF> optimizedPath(currentSection); QVector<QPointF> optimizedPath(currentSection);
bool reversePath = true; // controlls if currentSection gets reversed, has nothing todo with _reverseOnly bool reversePath = true; // controlls if currentSection gets reversed, has nothing todo with _reverseOnly
...@@ -422,7 +422,7 @@ void CircularSurveyComplexItem::_rebuildTransectsSlow() ...@@ -422,7 +422,7 @@ void CircularSurveyComplexItem::_rebuildTransectsSlow()
QVector<QPointF> tempConnectorPath; QVector<QPointF> tempConnectorPath;
bool retVal; bool retVal;
if (reversePath && isSnakePathBool) { if (reversePath && !fixedDirectionBool) {
retVal = PolygonCalculus::shortestPath(surveyPolygon, endVertex, iteratorPath.last(), tempConnectorPath); retVal = PolygonCalculus::shortestPath(surveyPolygon, endVertex, iteratorPath.last(), tempConnectorPath);
} else { } else {
retVal = PolygonCalculus::shortestPath(surveyPolygon, endVertex, iteratorPath.first(), tempConnectorPath); retVal = PolygonCalculus::shortestPath(surveyPolygon, endVertex, iteratorPath.first(), tempConnectorPath);
...@@ -442,7 +442,7 @@ void CircularSurveyComplexItem::_rebuildTransectsSlow() ...@@ -442,7 +442,7 @@ void CircularSurveyComplexItem::_rebuildTransectsSlow()
} }
} }
currentSection = transectPath.takeAt(index); currentSection = transectPath.takeAt(index);
if (reversePath && isSnakePathBool) { if (reversePath && !fixedDirectionBool) {
PolygonCalculus::reversePath(currentSection); PolygonCalculus::reversePath(currentSection);
} }
...@@ -700,9 +700,9 @@ Fact *CircularSurveyComplexItem::transectMinLength() ...@@ -700,9 +700,9 @@ Fact *CircularSurveyComplexItem::transectMinLength()
return &_transectMinLength; return &_transectMinLength;
} }
Fact *CircularSurveyComplexItem::isSnakePath() Fact *CircularSurveyComplexItem::fixedDirection()
{ {
return &_isSnakePath; return &_fixedDirection;
} }
Fact *CircularSurveyComplexItem::reverse() Fact *CircularSurveyComplexItem::reverse()
......
...@@ -22,7 +22,7 @@ public: ...@@ -22,7 +22,7 @@ public:
Q_PROPERTY(Fact* deltaR READ deltaR CONSTANT) Q_PROPERTY(Fact* deltaR READ deltaR CONSTANT)
Q_PROPERTY(Fact* deltaAlpha READ deltaAlpha CONSTANT) Q_PROPERTY(Fact* deltaAlpha READ deltaAlpha CONSTANT)
Q_PROPERTY(Fact* transectMinLength READ transectMinLength CONSTANT) Q_PROPERTY(Fact* transectMinLength READ transectMinLength CONSTANT)
Q_PROPERTY(Fact* isSnakePath READ isSnakePath CONSTANT) Q_PROPERTY(Fact* fixedDirection READ fixedDirection CONSTANT)
Q_PROPERTY(Fact* reverse READ reverse CONSTANT) Q_PROPERTY(Fact* reverse READ reverse CONSTANT)
Q_PROPERTY(Fact* maxWaypoints READ maxWaypoints CONSTANT) Q_PROPERTY(Fact* maxWaypoints READ maxWaypoints CONSTANT)
Q_PROPERTY(bool isInitialized READ isInitialized WRITE setIsInitialized NOTIFY isInitializedChanged) Q_PROPERTY(bool isInitialized READ isInitialized WRITE setIsInitialized NOTIFY isInitializedChanged)
...@@ -40,7 +40,7 @@ public: ...@@ -40,7 +40,7 @@ public:
Fact *deltaR(); Fact *deltaR();
Fact *deltaAlpha(); Fact *deltaAlpha();
Fact *transectMinLength(); Fact *transectMinLength();
Fact *isSnakePath(); Fact *fixedDirection();
Fact *reverse(); Fact *reverse();
Fact *maxWaypoints(); Fact *maxWaypoints();
// Is true if survey was automatically generated, prevents initialisation from gui. // Is true if survey was automatically generated, prevents initialisation from gui.
...@@ -69,7 +69,7 @@ public: ...@@ -69,7 +69,7 @@ public:
static const char* deltaRName; static const char* deltaRName;
static const char* deltaAlphaName; static const char* deltaAlphaName;
static const char* transectMinLengthName; static const char* transectMinLengthName;
static const char* isSnakePathName; static const char* fixedDirectionName;
static const char* reverseName; static const char* reverseName;
static const char* maxWaypointsName; static const char* maxWaypointsName;
...@@ -77,7 +77,7 @@ public: ...@@ -77,7 +77,7 @@ public:
static const char* jsonDeltaRKey; static const char* jsonDeltaRKey;
static const char* jsonDeltaAlphaKey; static const char* jsonDeltaAlphaKey;
static const char* jsonTransectMinLengthKey; static const char* jsonTransectMinLengthKey;
static const char* jsonIsSnakePathKey; static const char* jsonfixedDirectionKey;
static const char* jsonReverseKey; static const char* jsonReverseKey;
static const char* jsonReferencePointLongKey; static const char* jsonReferencePointLongKey;
static const char* jsonReferencePointLatKey; static const char* jsonReferencePointLatKey;
...@@ -120,7 +120,7 @@ private: ...@@ -120,7 +120,7 @@ private:
SettingsFact _deltaR; // distance between two neighbour circles SettingsFact _deltaR; // distance between two neighbour circles
SettingsFact _deltaAlpha; // angle discretisation of the circles SettingsFact _deltaAlpha; // angle discretisation of the circles
SettingsFact _transectMinLength; // minimal transect lenght, transects are rejected if they are shorter than this value SettingsFact _transectMinLength; // minimal transect lenght, transects are rejected if they are shorter than this value
SettingsFact _isSnakePath; // bool value, determining if transects are connected in a snake like or zig zag like manner SettingsFact _fixedDirection; // bool value, determining if transects have fixed direction or not
SettingsFact _reverse; // reverses the _transects path SettingsFact _reverse; // reverses the _transects path
SettingsFact _maxWaypoints; // the maximum number of waypoints _transects (TransectStyleComplexItem) can contain (to avoid performance hits) SettingsFact _maxWaypoints; // the maximum number of waypoints _transects (TransectStyleComplexItem) can contain (to avoid performance hits)
......
...@@ -1206,13 +1206,12 @@ QGCView { ...@@ -1206,13 +1206,12 @@ QGCView {
QGCLabel { QGCLabel {
width: sendSaveGrid.width width: sendSaveGrid.width
wrapMode: Text.WordWrap wrapMode: Text.WordWrap
text: "unsaved changes not yet implemented" text: masterController.dirty ?
/*masterController.dirty ?
(_activeVehicle ? (_activeVehicle ?
qsTr("You have unsaved changes. You should upload to your vehicle, or save to a file:") : qsTr("You have unsaved changes. You should upload to your vehicle, or save to a file:") :
qsTr("You have unsaved changes.") qsTr("You have unsaved changes.")
) : ) :
qsTr("Plan File:")*/ qsTr("File:")
} }
GridLayout { GridLayout {
......
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