Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qgroundcontrol
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Valentin Platzgummer
qgroundcontrol
Commits
a33541b9
Commit
a33541b9
authored
Jan 04, 2011
by
lm
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improved performance of 2D map, trails need further debugging
parent
2c92489b
Changes
7
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
138 additions
and
117 deletions
+138
-117
GAudioOutput.cc
src/GAudioOutput.cc
+3
-3
HUD.cc
src/ui/HUD.cc
+3
-0
MainWindow.cc
src/ui/MainWindow.cc
+1
-1
MapWidget.cc
src/ui/MapWidget.cc
+112
-87
MapWidget.h
src/ui/MapWidget.h
+6
-5
QGCDataPlot2D.cc
src/ui/QGCDataPlot2D.cc
+2
-18
WaypointList.cc
src/ui/WaypointList.cc
+11
-3
No files found.
src/GAudioOutput.cc
View file @
a33541b9
...
...
@@ -144,9 +144,6 @@ muted(false)
GAudioOutput
::~
GAudioOutput
()
{
QSettings
settings
;
settings
.
setValue
(
QGC_GAUDIOOUTPUT_KEY
+
"muted"
,
muted
);
settings
.
sync
();
#ifdef _MSC_VER2
::
CoUninitialize
();
#endif
...
...
@@ -155,6 +152,9 @@ GAudioOutput::~GAudioOutput()
void
GAudioOutput
::
mute
(
bool
mute
)
{
this
->
muted
=
mute
;
QSettings
settings
;
settings
.
setValue
(
QGC_GAUDIOOUTPUT_KEY
+
"muted"
,
muted
);
settings
.
sync
();
}
bool
GAudioOutput
::
isMuted
()
...
...
src/ui/HUD.cc
View file @
a33541b9
...
...
@@ -117,6 +117,9 @@ HUD::HUD(int width, int height, QWidget* parent)
// Set auto fill to false
setAutoFillBackground
(
false
);
// Set minimum size
setMinimumSize
(
80
,
60
);
// Fill with black background
QImage
fill
=
QImage
(
width
,
height
,
QImage
::
Format_Indexed8
);
fill
.
setNumColors
(
3
);
...
...
src/ui/MainWindow.cc
View file @
a33541b9
...
...
@@ -703,7 +703,7 @@ void MainWindow::connectCommonWidgets()
if
(
mapWidget
&&
waypointsDockWidget
->
widget
())
{
// clear path create on the map
connect
(
waypointsDockWidget
->
widget
(),
SIGNAL
(
clearPathclicked
()),
mapWidget
,
SLOT
(
clear
Path
()));
connect
(
waypointsDockWidget
->
widget
(),
SIGNAL
(
clearPathclicked
()),
mapWidget
,
SLOT
(
clear
Waypoints
()));
// add Waypoint widget in the WaypointList widget when mouse clicked
connect
(
mapWidget
,
SIGNAL
(
captureMapCoordinateClick
(
QPointF
)),
waypointsDockWidget
->
widget
(),
SLOT
(
addWaypointMouse
(
QPointF
)));
...
...
src/ui/MapWidget.cc
View file @
a33541b9
This diff is collapsed.
Click to expand it.
src/ui/MapWidget.h
View file @
a33541b9
...
...
@@ -71,7 +71,9 @@ public slots:
void
updateCameraPosition
(
double
distance
,
double
bearing
,
QString
dir
);
QPointF
getPointxBearing_Range
(
double
lat1
,
double
lon1
,
double
bearing
,
double
distance
);
//ROCA
/** @brief Clear the waypoints overlay layer */
void
clearWaypoints
();
/** @brief Clear the UAV tracks on the map */
void
clearPath
();
void
changeGlobalWaypointPositionBySpinBox
(
int
index
,
float
lat
,
float
lon
);
void
drawBorderCamAtMap
(
bool
status
);
...
...
@@ -96,6 +98,7 @@ protected:
QPushButton
*
followgps
;
QPushButton
*
createPath
;
QPushButton
*
clearTracking
;
QLabel
*
gpsposition
;
QMenu
*
mapMenu
;
QPushButton
*
mapButton
;
...
...
@@ -104,6 +107,7 @@ protected:
qmapcontrol
::
MapAdapter
*
mapadapter
;
///< Adapter to load the map data
qmapcontrol
::
Layer
*
l
;
///< Current map layer (background)
qmapcontrol
::
Layer
*
overlay
;
///< Street overlay (foreground)
qmapcontrol
::
Layer
*
tracks
;
///< Layer for UAV tracks
qmapcontrol
::
GeometryLayer
*
geomLayer
;
///< Layer for waypoints
//only for experiment
...
...
@@ -132,9 +136,6 @@ protected:
void
createWaypointGraphAtMap
(
const
QPointF
coordinate
);
void
mapproviderSelected
(
QAction
*
action
);
signals:
//void movePoint(QPointF newCoord);
void
captureMapCoordinateClick
(
const
QPointF
coordinate
);
//ROCA
...
...
@@ -145,8 +146,8 @@ protected:
private:
Ui
::
MapWidget
*
m_ui
;
QList
<
qmapcontrol
::
Point
*>
wps
;
qmapcontrol
::
LineString
*
waypointPath
;
QHash
<
QString
,
qmapcontrol
::
Point
*>
wpIndex
;
qmapcontrol
::
LineString
*
path
;
QPen
*
pointPen
;
int
wpExists
(
const
QPointF
coordinate
);
bool
waypointIsDrag
;
...
...
src/ui/QGCDataPlot2D.cc
View file @
a33541b9
...
...
@@ -307,7 +307,8 @@ void QGCDataPlot2D::selectFile()
void
QGCDataPlot2D
::
loadRawLog
(
QString
file
,
QString
xAxisName
,
QString
yAxisFilter
)
{
qDebug
()
<<
"LOADING RAW LOG!"
;
Q_UNUSED
(
xAxisName
);
Q_UNUSED
(
yAxisFilter
);
if
(
logFile
!=
NULL
)
{
...
...
@@ -320,23 +321,6 @@ void QGCDataPlot2D::loadRawLog(QString file, QString xAxisName, QString yAxisFil
connect
(
compressor
,
SIGNAL
(
logProcessingStatusChanged
(
QString
)),
MainWindow
::
instance
(),
SLOT
(
showStatusMessage
(
QString
)));
connect
(
compressor
,
SIGNAL
(
finishedFile
(
QString
)),
this
,
SLOT
(
loadFile
(
QString
)));
compressor
->
startCompression
();
// // Block UI
// QProgressDialog progress("Transforming RAW log file to CSV", "Abort Transformation", 0, 1, this);
// progress.setWindowModality(Qt::WindowModal);
// while (!compressor->isFinished())
// {
// MG::SLEEP::usleep(100000);
//// progress.setMaximum(compressor->getDataLines());
//// progress.setValue(compressor->getCurrentLine());
// }
// // Enforce end
// progress.setMaximum(compressor->getDataLines());
// progress.setValue(compressor->getDataLines());
// Done with preprocessing - now load csv log
//loadFile(logFile->fileName());
}
/**
...
...
src/ui/WaypointList.cc
View file @
a33541b9
...
...
@@ -197,20 +197,28 @@ void WaypointList::add()
{
const
QVector
<
Waypoint
*>
&
waypoints
=
uas
->
getWaypointManager
().
getWaypointList
();
Waypoint
*
wp
;
if
(
waypoints
.
size
()
>
0
)
{
// Create waypoint with last frame
Waypoint
*
last
=
waypoints
.
at
(
waypoints
.
size
()
-
1
);
Waypoint
*
wp
=
new
Waypoint
(
0
,
last
->
getX
(),
last
->
getY
(),
last
->
getZ
(),
last
->
getYaw
(),
last
->
getAutoContinue
(),
false
,
last
->
getOrbit
(),
wp
=
new
Waypoint
(
0
,
last
->
getX
(),
last
->
getY
(),
last
->
getZ
(),
last
->
getYaw
(),
last
->
getAutoContinue
(),
false
,
last
->
getOrbit
(),
last
->
getHoldTime
(),
last
->
getFrame
(),
last
->
getAction
());
uas
->
getWaypointManager
().
addWaypoint
(
wp
);
}
else
{
//
isLocalWP = true;
Waypoint
*
wp
=
new
Waypoint
(
0
,
uas
->
getLongitude
(),
uas
->
getLatitude
(),
uas
->
getAltitude
(),
//
Create global frame waypoint per default
wp
=
new
Waypoint
(
0
,
uas
->
getLongitude
(),
uas
->
getLatitude
(),
uas
->
getAltitude
(),
0.0
,
true
,
true
,
0.15
,
2000
);
uas
->
getWaypointManager
().
addWaypoint
(
wp
);
}
if
(
wp
->
getFrame
()
==
MAV_FRAME_GLOBAL
)
{
emit
createWaypointAtMap
(
QPointF
(
wp
->
getX
(),
wp
->
getY
()));
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment