summaryrefslogtreecommitdiff
path: root/src/location
Commit message (Collapse)AuthorAgeFilesLines
* Add a way to skip showing tilesPaolo Angelelli2017-05-084-7/+28
| | | | | | | | | | | | | | | In certain cases servers provide tiles that can be fully transparent, provide no content or are bogus. Tile fetchers can be smart and detect some of these cases. This patch offers an extensible way to allow them to communicate (via a null QImage) tiles that should not be rendered, in addition to an extensible mechanism to identify such tiles on disk. The default way is by assuming that, once such tiles have been detected, the tile fetcher would simply write a file with "NoRetry" as content. Change-Id: I404bb4dcc38fdd33c412f7407601b47947e4ce8d Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Workaround for QGeoFileTileCache losing contentv5.9.0-beta4Paolo Angelelli2017-05-071-2/+4
| | | | | | | | | This patch disables the queue persistence, that causes the cache to fail indexing valid content present in the cache on disk Task-number: QTBUG-60581 Change-Id: Iec3ba6105fe59a6f466bfabf0db4bf4fc00267af Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Add pluginName to QGeoMapType and check against it in setActiveMapTypePaolo Angelelli2017-05-074-19/+43
| | | | | | | | | | | This patch adds a QByteArray member to QGeoMapType with the name of the plugin providing that map type. This value is then used to validate what is passed to QDeclarativeGeoMap::setActiveMapType to see if it's a map type for the currently set plugin. Change-Id: If15b67c32150f0c3c2815d28e26fc37138d4cf71 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Fix QDeclarativeGeoMap::visibleRegion when map is rotated/tiltedPaolo Angelelli2017-05-031-3/+6
| | | | | | | | This patch attempts to return something meaningful from that method also when the map is rotated/tilted, while waiting for QGeoPolygon. Change-Id: Id14853f2078ed399cf7f2c603ae7442489c07829 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Fix for MapGestureArea pinch and scroll wheel not honoring min zoomPaolo Angelelli2017-05-033-4/+23
| | | | | | | | | This patch fixes a regression introduced with e81ba34a98b259723e783e2d2df4321309992291, which made possible to zoom below the minimum valid zoom level for a viewport size. Change-Id: I4e71530b9bc5423ea24083146963c3bd0928f14a Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Evaluate the visible region lazily in QGeoProjectionWebMercatorPaolo Angelelli2017-05-032-6/+19
| | | | | | | | | | | | | | This change optimizes QGeoProjectionWebMercator::setupCamera, factoring out the code that calculates the visible region, and replacing it with a dirty flag. The computation is deferred to the first time visibleRegion() gets called. This is done because the visible region is currently only used to render some types of map items, meaning that in a multi layer setup, only few layers might need it. Change-Id: I5dd75969581513eb60e3cf5d6ba649349bf25378 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Move QGeoRectangle definition inside qgeorectangle.hPaolo Angelelli2017-05-031-1/+1
| | | | | | Change-Id: I7d0bb4eac89ca9a018f71faa9d73f62d97a24085 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Make error_messages.h privatePaolo Angelelli2017-05-0214-15/+25
| | | | | Change-Id: Iba33d12fad113b64cb071f0542a2c92034ff755d Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* Fix prefetching documentation for pluginsPaolo Angelelli2017-05-024-4/+8
| | | | | | | | | | Depending on the plugin, and the map type, the prefetching parameter might be overridden for specific reasons. This patch changes the description of prefetching stating that this parameter is a hint for the engine, that might get ignored. Change-Id: Iba68ed735f48ffaca19622b8f8933a44aa257c90 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Enable Mapbox GL plugin on MinGW buildsThiago Marcos P. Santos2017-04-281-0/+18
| | | | | | | | | | | | Qt CI is using MinGW 5.3.0 that should do the job compiling Mapbox GL. For now, only the ANGLE OpenGL backend is supported on Windows for this plugin. I.e. you need to set QT_OPENGL=angle or Qt::AA_UseOpenGLES. Task-number: QTBUG-60110 Change-Id: Iebd4d1569191f47a14b264c489b5d3fb23338d78 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io>
* Fix for nearest scaling still being used in overzoomPaolo Angelelli2017-04-281-0/+1
| | | | | | | | An assignment was missing to make the overzooming bool actually kick in. Change-Id: I5f6e52016026af050c734bca31e45f06fbbdb9b5 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Make QGeoTileFetcher::handleReply virtualPaolo Angelelli2017-04-281-1/+1
| | | | | | | | Tile fetchers may need to override this one to better analyze the reply content and possibly validate it. Change-Id: Ia3445017ad7b44d719a1ce28b811d9145373e397 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Fix build for -no-feature-wheeleventStephan Binner2017-04-194-0/+10
| | | | | Change-Id: I69246dcaeda841892b1efe182725629517031447 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* Fix build for -no-feature-cssparserStephan Binner2017-04-191-0/+2
| | | | | Change-Id: I06c0c1ad4744cd91a116906d7e7725f05cc35688 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* Fix build for -no-feature-texthtmlparserStephan Binner2017-04-191-0/+16
| | | | | Change-Id: I9ab2c7b494aff0059f871a2bedee414559272a73 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* Merge remote-tracking branch 'origin/5.8' into 5.9Liang Qi2017-04-182-3/+3
|\ | | | | | | Change-Id: I8ce0a0994d57fb077be4b6771f219bfc4134aa22
| * Doc: corrected link to Models and Views in Qt QuickNico Vertriest2017-03-141-2/+2
| | | | | | | | | | Change-Id: I8a6e6a34ea22b5ba96b46f05e970cdaa91dbc6b4 Reviewed-by: Topi Reiniƶ <topi.reinio@qt.io>
* | Clarify overzoomEnabled property of QGeoCameraCapabilitiesv5.9.0-beta2Paolo Angelelli2017-04-122-1/+11
| | | | | | | | | | Change-Id: If6f8fd446c562d6ccaf368e1d5afb5eee113fece Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Fix export in QGeoCameraCapabilitiesPaolo Angelelli2017-04-121-2/+2
| | | | | | | | | | Change-Id: I1fff4d22c11c540b955abbfeb0707c8622291bef Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Allow overzooming when setting zoomLevel directly in a MapPaolo Angelelli2017-04-124-8/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | This patch moves the lower/upper bound check on setZoom from QDeclarativeGeoMap to the gesture area, allowing to set higher zoom levels than the maximumZoomLevel when setting Map.zoomLevel directly, for the map types that support overzoom. This is now safe as the bound check is introduced in the tile fetcher, so no invalid tiles will be requested, and is beneficial when combining layers supporting different maximum zoom levels. Change-Id: I08ee9c282ee2ebc1dafa3c68a238b93ffbc1ba02 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Fix for copyright notice not showing before map type is changedPaolo Angelelli2017-04-121-1/+19
| | | | | | | | | | | | Task-number: QTBUG-58801 Change-Id: I2a980c6d218d0d7e44277f7b31fcdd7355e31698 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Bound check QGeoTileSpec against min/max ZL before requesting itPaolo Angelelli2017-04-123-6/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Until now we have not honored the min/max zoom levels specified in QGeoCameraCapabilities when requesting tiles. As a result we have often fired requests for non-existing tile layers. This change complements the added support for individual camera caps for each map type, and makes the tile fetcher honor the bounds defined in the camera capabilities. This also allows to set larger zoom levels in the renderer, overzooming existing tiles, without the fetcher firing requests for invalid resources Change-Id: Ic8a523a114147109f7ef8af3510a3ab78d06d714 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Replace QGeoMapType argument of cameraCapabilitiesPaolo Angelelli2017-04-123-5/+5
| | | | | | | | | | | | | | | | | | | | Since the only part of QGeoMapType used in the method is mapId, there's no need to pass the whole map type as argument. The benefit is that the camera caps can be requested solely based on the info in QGeoTileSpec. Change-Id: Iafd0e2a1d4d45fbf02b862efe56841001cbebd75 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Mark qtlocation as warning-freeThiago Macieira2017-04-121-0/+3
| | | | | | | | | | | | | | | | | | This will turn -Werror on for our tested compilers, to avoid introducing new warnings. Change-Id: I27b55fdf514247549455fffd14b17ae6dce9976f Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Remove QtGui dependency from QDoubleMatrix4x4Alex Blasche2017-04-111-0/+1
| | | | | | | | | | | | | | | | | | This fixes the -no-gui build. Task-number: QTBUG-60062 Change-Id: I71400dfddac8ddf6a74906be8ba1272bf4a86781 Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Prevent accessing invalid QGeoTileSpec from QHash look-upsPaolo Angelelli2017-04-111-9/+13
| | | | | | | | | | Change-Id: Ic169824201ed6aeaeb2a482b28da989f9312181d Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Prevent containers from detaching within for loops in QGeoTiledMapScenePaolo Angelelli2017-04-111-6/+6
| | | | | | | | | | Change-Id: I7f81f3dab3ef0243c45ec22bafa8687f756134f4 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Replace foreach with ranged for loops in QGeoTiledMapScenePaolo Angelelli2017-04-111-8/+8
| | | | | | | | | | Change-Id: I7a82c0d63f35d1cfd264801e58089408254757c8 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Prevent QList detaching in for loops in QDeclarativeGeoMapPaolo Angelelli2017-04-111-3/+3
| | | | | | | | | | | | | | Using qAsConst where possible to prevent QList from detaching. Change-Id: Ief03fb17761e350335f945b7134cf4a9266971d7 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Protect QGeoMap pointer with QPointerPaolo Angelelli2017-04-114-17/+18
| | | | | | | | | | | | | | | | | | | | | | | | m_map inside QDeclarativeGeoMap is created, but also destroyed, by the engine. In some cases (dynamic QML object creation/destruction) the engine may disappear before the Map. This patch introduces a QPointer to prevent a dangling pointer Change-Id: Ice3c57b4dbeb96ee8d7e4d401654b9085c105dec Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Doc: Complete parameter documentationNico Vertriest2017-04-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | qdeclarativegeomap.cpp: 1327: warning: Can't link to 'Component.onCompleted' qgeopath.cpp:117: warning: Undocumented parameter 'width' in QGeoPath::QGeoPath() qgeopath.cpp:117: warning: Undocumented parameter 'path' in QGeoPath::QGeoPath() qgeoshape.cpp:90: warning: Undocumented enum item 'PathType' in QGeoShape::ShapeType qgeoshape.cpp:231: warning: No such parameter 'QGeoRectangle' in QGeoShape::boundingGeoRectangle() Change-Id: Ie57dff2aabe82d61b8122362a396ac706939c3b3 Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io>
* | Rename libclipper namespaceThiago Marcos P. Santos2017-04-102-3/+3
| | | | | | | | | | | | | | | | | | | | | | So it won't clash with the libclipper used by the Mapbox GL plugin when linking Qt with -static. With -static, all the plugins are linked together instead of each one having its own shared library, thus, hiding private symbols. Change-Id: I33ee4afd4b83741c5f3fae32a88da7f4a7fee75f Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io>
* | Trigger manually map update after initializationKarol Polak2017-04-101-0/+6
| | | | | | | | | | | | | | | | If all of the tiles were loaded from cache and plugin for the map was set after creation of the declarative map, it can occur that item is not updated Task-number: QTBUG-60021 Change-Id: I260b6219b65ef16726aa767d3a83c6fc756642b5 Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io>
* | Use linear filterning whenever overzooming lo-res tilesPaolo Angelelli2017-04-071-7/+9
| | | | | | | | | | | | | | | | | | This patch fixes the incorrect behavior of using nearest filtering at integer zoom level, even if the texture is being overzoomed from a lower zoom level Change-Id: Ia3572399187a6f24829504116602685434ecfc5f Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Update location screenshotsThiago Marcos P. Santos2017-04-062-3/+3
| | | | | | | | | | | | | | | | Better rendering using Mapbox GL plugin. Change-Id: I3ef1862988e652c1caad62920c2f3b5775f18552 Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io> Reviewed-by: Bruno de Oliveira Abinader <brunoabinader@gmail.com>
* | Add MapParameters docs for Mapbox GL pluginThiago Marcos P. Santos2017-04-041-1/+114
| | | | | | | | | | | | | | Document the MapParameters supported by this plugin. Change-Id: Ib755460e2f326e9b9569da31aa4bff4015c1a90b Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io>
* | Improve flicking behavior of QQuickGeoMapGestureAreaPaolo Angelelli2017-04-032-51/+37
| | | | | | | | | | | | | | | | | | This patch replaces the two separate flick velocities and displacements for x and y with one vector , so that there will be no discrepancy between the flicking direction and where the map actually flicks Change-Id: I83164107003a423cb7332da5759d83ff689c1b31 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Fix for camera data not updated in changeActiveMapTypev5.9.0-beta1Paolo Angelelli2017-03-311-1/+2
| | | | | | | | | | | | | | | | This patch forces a camera data update upon changeActiveMapType, which may change the tile size. Change-Id: Ib371ea7f76267bc4ed8a30eed31ec3887b4a1415 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Fix for QGeoTiledMapPrivate::changeActiveMapType not setting tileSizePaolo Angelelli2017-03-283-5/+20
| | | | | | | | | | Change-Id: If3e920f4b4cb5bf6310914a258eb3f569de9a8ef Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Fix rotation gesture startPaolo Angelelli2017-03-271-2/+2
| | | | | | | | | | | | | | | | | | | | This patch makes the rotation gesture start more smoothly instead of abruptingly start with an initial rotation equal to starting angle threshold, once this threshold angle has been trespassed. Change-Id: I2be52fa53f50151b9b87244a1b53ca4105121a8b Reviewed-by: Bruno de Oliveira Abinader <brunoabinader@gmail.com> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Check for map in map item's geometryChangedPaolo Angelelli2017-03-274-4/+4
| | | | | | | | | | | | | | | | | | Add additional sanity checks to do the geometry changing only if the map() has been set already (that is, the item has been added to the map) Change-Id: Id5b5faa41c68c80c3ad322f408b7a8abe5d2f7ab Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Fix wrong parameter in nokia.qdocPaolo Angelelli2017-03-271-1/+1
| | | | | | | | | | Change-Id: I13bdd8cb9c9c92ea86144c004af06c66adb28bde Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Add parameter to control prefetching in tile-based geoservice pluginsPaolo Angelelli2017-03-276-0/+31
| | | | | | | | | | Change-Id: I18fc1788f7af0efe76f97257ffe739eb1a96e6cc Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Allow to disable prefetchingPaolo Angelelli2017-03-272-3/+6
| | | | | | | | | | | | | | | | | | | | Add a NoPrefetch PrefetchStyle to allow disabling the prefetching. A new parameter in the geoservice plugin is then needed to effectively disable it. Change-Id: I8b8a2343cbe4f59bd990d25c3381f4a11708860e Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* | Proactively convert tile formats to ARGB32_PremultipliedPaolo Angelelli2017-03-271-0/+4
| | | | | | | | | | | | | | | | | | | | This patch avoids each bind to do this conversion if the format of the tile isn't RGB or ARGB32_Premultiplied. This is the case of PNG with alpha channel, that usually comes as ARGB32. Change-Id: I8f1297dd82ab20b6c8ecac3e68bf5d82e03f2e70 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* | Consider keepTouchGrab when handing mouse events in QDeclarativeGeoMapPaolo Angelelli2017-03-241-2/+2
| | | | | | | | | | | | | | | | | | | | QDeclarativeGeoMap used to consider only keepMouseGrab. Some components only set keepTouchGrab. With this patch both are considered Task-number: QTBUG-59416 Change-Id: Ie551c9a207cdac144fd760b863fc5fafd4c21274 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | Enable overzooming tiles in qgeotiledmapscenePaolo Angelelli2017-03-234-14/+62
| | | | | | | | | | | | | | | | | | With this patch tiles from previous zoom levels can be temporarily used to fill the map until the actual tiles are fetched. Task-number: QTBUG-23659 Change-Id: I7db68c82217cb18a9bec2abdc3e679fc0bfb6b94 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* | Fix for projection mismatch when aspect ratio < 1.0Paolo Angelelli2017-03-223-29/+13
| | | | | | | | | | | | | | | | | | | | | | This patch fixes an incorrect computation of the projection matrices and thus a mismatch in projections between mbgl vs the other plugins when the window A/R is less than 1.0. Task-number: QTBUG-59417 Change-Id: Ib03eaa4c877a00c9281c335f859c854d6db632c0 Reviewed-by: Bruno de Oliveira Abinader <brunoabinader@gmail.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* | Remove pathPropertyChanged() from Polyline,PolygonPaolo Angelelli2017-03-222-2/+0
| | | | | | | | | | | | | | This private method is not even implemented. Change-Id: I30c0e559d0264f1b0eb6d394c9675879b23be44e Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* | Lower bound minimum/maximumZoomLevelAt256Paolo Angelelli2017-03-221-2/+2
| | | | | | | | | | | | | | | | | | Without this patch, using tiles of size 128 may cause these methods to return negative values Change-Id: I6476083350fd552756d1388fa9bc8fa36d8c4ee3 Reviewed-by: Alex Blasche <alexander.blasche@qt.io> Reviewed-by: Bruno de Oliveira Abinader <brunoabinader@gmail.com>