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
83c609b8
Commit
83c609b8
authored
Jun 13, 2016
by
Don Gagne
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Crazy tile counts now handled on Qml side
parent
727c55fe
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
18 deletions
+8
-18
QGCMapEngineManager.cc
src/QtLocationPlugin/QMLControl/QGCMapEngineManager.cc
+8
-14
QGCMapEngineManager.h
src/QtLocationPlugin/QMLControl/QGCMapEngineManager.h
+0
-4
No files found.
src/QtLocationPlugin/QMLControl/QGCMapEngineManager.cc
View file @
83c609b8
...
...
@@ -74,20 +74,14 @@ QGCMapEngineManager::updateForCurrentView(double lon0, double lat0, double lon1,
QGCTileSet
set
=
QGCMapEngine
::
getTileCount
(
z
,
lon0
,
lat0
,
lon1
,
lat1
,
mapType
);
_totalSet
+=
set
;
}
//-- Beyond 100,000,000 tiles is just nuts
if
(
_totalSet
.
tileCount
>
100
*
1000
*
1000
)
{
_crazySize
=
true
;
emit
crazySizeChanged
();
}
else
{
_crazySize
=
false
;
emit
crazySizeChanged
();
emit
tileX0Changed
();
emit
tileX1Changed
();
emit
tileY0Changed
();
emit
tileY1Changed
();
emit
tileCountChanged
();
emit
tileSizeChanged
();
}
emit
tileX0Changed
();
emit
tileX1Changed
();
emit
tileY0Changed
();
emit
tileY1Changed
();
emit
tileCountChanged
();
emit
tileSizeChanged
();
qCDebug
(
QGCMapEngineManagerLog
)
<<
"updateForCurrentView"
<<
lat0
<<
lon0
<<
lat1
<<
lon1
<<
minZoom
<<
maxZoom
;
}
//-----------------------------------------------------------------------------
...
...
src/QtLocationPlugin/QMLControl/QGCMapEngineManager.h
View file @
83c609b8
...
...
@@ -37,7 +37,6 @@ public:
Q_PROPERTY
(
QString
tileCountStr
READ
tileCountStr
NOTIFY
tileCountChanged
)
Q_PROPERTY
(
quint64
tileSize
READ
tileSize
NOTIFY
tileSizeChanged
)
Q_PROPERTY
(
QString
tileSizeStr
READ
tileSizeStr
NOTIFY
tileSizeChanged
)
Q_PROPERTY
(
bool
crazySize
READ
crazySize
NOTIFY
crazySizeChanged
)
Q_PROPERTY
(
QmlObjectListModel
*
tileSets
READ
tileSets
NOTIFY
tileSetsChanged
)
Q_PROPERTY
(
QStringList
mapList
READ
mapList
CONSTANT
)
Q_PROPERTY
(
QString
mapboxToken
READ
mapboxToken
WRITE
setMapboxToken
NOTIFY
mapboxTokenChanged
)
...
...
@@ -65,7 +64,6 @@ public:
QString
tileCountStr
();
quint64
tileSize
()
{
return
_totalSet
.
tileSize
;
}
QString
tileSizeStr
();
bool
crazySize
()
{
return
_crazySize
;
}
QStringList
mapList
();
QString
mapboxToken
();
QmlObjectListModel
*
tileSets
()
{
return
&
_tileSets
;
}
...
...
@@ -91,7 +89,6 @@ signals:
void
tileY1Changed
();
void
tileCountChanged
();
void
tileSizeChanged
();
void
crazySizeChanged
();
void
mapboxTokenChanged
();
void
tileSetsChanged
();
void
maxMemCacheChanged
();
...
...
@@ -114,7 +111,6 @@ private:
private:
QGCTileSet
_totalSet
;
bool
_crazySize
;
double
_topleftLat
;
double
_topleftLon
;
double
_bottomRightLat
;
...
...
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