summaryrefslogtreecommitdiff
path: root/src/location/maps/qgeotilefetcher_p.h
diff options
context:
space:
mode:
authorAlex Wilson <alex.wilson@nokia.com>2012-03-13 17:15:21 +1000
committerQt by Nokia <qt-info@nokia.com>2012-03-14 07:55:50 +0100
commite071be7ff80373b3f4fb523393c9875a8c00e0af (patch)
treec0a9aaaa202077e1a0510424044c3ce4576be15e /src/location/maps/qgeotilefetcher_p.h
parentea2962c23255424e02a446efcea078711f1bcd6a (diff)
downloadqtlocation-e071be7ff80373b3f4fb523393c9875a8c00e0af.tar.gz
New 3Q cache for map tiles, cleanup texture/tile resource management
Replaces the old use of QCache in QGeoTileCache with a new QCache3Q, which is more optimal for many tile workloads. Resource management for textures and tile data is now enforced and managed correctly across threads. Textures are passed around as QSharedPointers to guarantee that cache eviction policy will not interfere with the correctness of rendering. Change-Id: I93eb49ea3ad009d85f394f92c59a4b22962b88a7 Reviewed-by: Alex Wilson <alex.wilson@nokia.com>
Diffstat (limited to 'src/location/maps/qgeotilefetcher_p.h')
-rw-r--r--src/location/maps/qgeotilefetcher_p.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/location/maps/qgeotilefetcher_p.h b/src/location/maps/qgeotilefetcher_p.h
index 659cc817..b18efadc 100644
--- a/src/location/maps/qgeotilefetcher_p.h
+++ b/src/location/maps/qgeotilefetcher_p.h
@@ -58,6 +58,8 @@
#include <QMap>
#include <QLocale>
#include <QTimer>
+#include <QMutex>
+#include <QMutexLocker>
#include <QHash>
#include "qgeomaptype.h"
@@ -80,6 +82,7 @@ public:
bool stopped_;
bool initialized_;
QTimer *timer_;
+ QMutex queueMutex_;
QList<QGeoTileSpec> queue_;
QHash<QGeoTileSpec, QGeoTiledMapReply*> invmap_;