Thiago Marcos P. Santos
7cdc39bee9
[Qt] Fix race when locking a FileSource
...
We were returning the FileSource, it could have expired
already. We _need_ to check if the lock() on the weak
pointer worked before returning.
2019-03-08 20:56:45 +02:00
Sudarsana Babu Nagineni
5e2b6bf636
[core] Add MapOptions to define properties of Map
...
To simplify the Map constructor, introduce MapOptions
interface to define the properties that can be set on
a Map.
2019-03-08 18:20:55 +02:00
Thiago Marcos P. Santos
7b7ad9d39b
[qt] Also use the base API URL as key for sharing the cache.
...
Otherwise we will have a URL pointing to different servers and
potentially different data.
2019-03-04 19:33:45 +02:00
Bruno de Oliveira Abinader
586b22c0df
[core] Remove map coordinate setters/getters
2019-03-04 14:45:32 +02:00
Bruno de Oliveira Abinader
ba7427b4ac
[core] Transform{State}: s/angle/bearing/
2019-03-04 14:45:32 +02:00
Bruno de Oliveira Abinader
73ac3c784f
[core] Remove map bearing setters/getters
2019-03-04 14:45:32 +02:00
Bruno de Oliveira Abinader
21a39306da
[core] Remove map pitch setters/getters
2019-03-04 14:45:32 +02:00
Bruno de Oliveira Abinader
f5f10ec119
[core] Remove map zoom setters/getters
2019-03-04 14:45:32 +02:00
Bruno de Oliveira Abinader
491fce6879
[core] Added Map::pitchBy()
2019-03-04 14:45:32 +02:00
Bruno de Oliveira Abinader
02f2b9c75c
[core] Added Map::scaleBy()
2019-03-04 14:45:32 +02:00
Bruno de Oliveira Abinader
362231e2d0
[qt] Cleanup QMapboxGL::coordinateZoomForBounds()
2019-03-04 14:45:32 +02:00
Thiago Marcos P. Santos
edc6a5dd8b
[qt] Share the same file source only if using the same access token
...
If access tokens are different, we cannot share the file source,
because it will override the previously set access token.
2019-02-27 13:31:21 +02:00
xylosper
0c66ce9a95
[qt] fix missing alpha channel for QColor
...
`QColor::name()` produces `#rrggbb` format where alpha is missing.
Use `rgba(...)` string instead when convert `QColor` to mapbox style.
Note: `QColor::name(QColor::HexArgb)` produces `#aarrggbb` format string,
but mapbox does not support this format apparently.
2019-02-20 16:16:34 +02:00
Thiago Marcos P. Santos
056073a904
[build] Use the correct define on Windows
...
https://blog.kowalczyk.info/article/j/guide-to-predefined-macros-in-c-compilers-gcc-clang-msvc-etc..html
2019-02-19 16:20:56 +02:00
Thiago Marcos P. Santos
65cec8be34
[android,darwin,ios,qt] Remove unused code
...
These files are no longer needed after the new GL abstraction.
2019-02-12 19:42:08 +02:00
Thiago Marcos P. Santos
690833ef92
[core] Switch to the new OpenGL abstraction
...
This patch will make Mapbox GL Core never use OpenGL
directly. We should consider locking into OpenGL ES 2.0
to simplify the code path and remove #ifdefs.
2019-02-12 19:42:08 +02:00
Thiago Marcos P. Santos
470b01847d
[android,linux,darwin,qt] Load OpenGL for the platform
...
These loaders will provide pointers to the platform implementation
of OpenGL. On Android, Linux and Darwin, we simply link with the
OpenGL implementation that is expected to exist on the platform.
Qt has its own GL loader, so we just connect the dots.
2019-02-12 19:42:08 +02:00
xylosper
fbbc83aa0e
[qt] fix missing Q_MAPBOXGL_EXPORTs
...
New projection-related functions in QMapbox namespace
are missing Q_MAPBOXGL_EXPORTs.
2019-02-12 11:08:26 +02:00
xylosper
26af7265c3
[qt] add global projection functions
...
There are 3 methods in QMapboxGL which can be static method.
QMapboxGL::metersPerPixelAtLatitude
QMapboxGL::projectedMetersForCoordinate
QMapboxGL::coordinateForProjectedMeters
Add these functions into QMapbox namespace as global functions.
The methods in QMapboxGL are kept for backward compatibility.
2019-02-12 11:08:26 +02:00
xylosper
b1ee903dc4
[qt] Add example of feature collection data for GeoJSON source
...
The example shows that both of QList<QMapbox::Feature> and
QVector<QMapbox::Feature> can be used as feature collection data
for GeoJSON layer.
2019-02-01 16:34:35 +02:00
xylosper
6b2f17191b
[qt] Support feature collection for GeoJSON source data
...
This commit adds support of `QVector<QMapbox::Feature>`
and `QList<QMapbox::Feature>` for data in GeoJSON source.
2019-02-01 16:34:35 +02:00
Thiago Marcos P. Santos
2a535a8f5e
[qt] Use QVector instead of QList
...
For our use case `QVector` is more efficient and will
do less memory allocations.
Fixes : #13830
2019-01-30 16:22:13 +02:00
Bruno de Oliveira Abinader
963dd5e567
[Qt] Support local font family in QMapboxGLSettings
2019-01-04 17:27:41 -04:00
Bruno de Oliveira Abinader
513b50eee8
[Qt] Implement LocalGlyphRasterizer
2019-01-04 17:27:41 -04:00
Konstantin Käfer
1d8235f5b8
[build] rework platform/default directory and add -files.txt for vendored libs
2018-12-14 11:03:03 +01:00
Huyen Chau Nguyen
9a606caf0b
[core] define number of concurrent downloads in online file source variable
2018-11-15 12:19:48 -08:00
Thiago Marcos P. Santos
253ba55f1f
[qt] Fix crash on Qt filesource
...
When opening many maps and sharing the same filesource:
- Say we open around 30 maps and they all have the same style.
- They will all request the same sprite.json, but Qt filesource will
restrict simultaneous request to 20.
- Mapbox GL will send some sprite.json to the filesource and queue
some internally along with other requests.
- When the first sprite.json arrives and the Qt filesource calls the
callback, Mapbox GL will synchronously push queued requests to the
Qt filesource when a request is handled.
- We are walking a QVector dispatching sprite.json requests, but more
requests get added to this QVector while we are walking it using an
iterator.
- That corrupts the iterator and we get a crash.
The fix is simple, just pop items from the QVector until it is empty
instead of using iterators.
2018-11-13 23:26:34 +02:00
Thiago Marcos P. Santos
cd92a231b3
[qt] Deprecate Qt4 and old versions of Qt5
...
Not enough adoption to keep the platform alive.
2018-11-13 22:55:26 +02:00
Mikhail Pozdnyakov
ffdeef3a26
Refer corresponding LayerFactory instance from the Layer::Impl
2018-11-07 16:34:20 +02:00
Thiago Marcos P. Santos
69960afb8d
[build] Add build system for submodules
...
Vendorize the submodules and a simple CMake build
system for all them. The dependencies will inherit
compilation options for core.
The goal is to make Mapbox GL Core completely self
contained with a simple offline build.
2018-10-31 18:19:28 +02:00
Mikhail Pozdnyakov
7a9461a8d4
Consolidate style::Layer properties API
...
The `style::Layer` class now exposes all the properties contained at `style::LayerImpl`.
This allowed to drop `style::Layer::accept()` method usage, avoid the repeated generated code
and thus save some binary size.
This patch is a part of the layers modularization effort.
2018-10-25 22:42:43 +03:00
Konstantin Käfer
282c71e8e9
[core] unify UTF-8/16 conversion to <boost/locale/encoding_utf.hpp>
2018-10-23 12:23:40 +02:00
Bruno de Oliveira Abinader
98c36fc06e
[core] CameraOptions receives and outputs angle and pitch as degrees, not radians
2018-10-19 12:05:16 +02:00
Chris Loer
bc71825774
[core] Bidi support for styled text.
...
Remove use of QString from non-ICU Qt stub bidi implementation since we weren't making use of it.
2018-10-15 13:15:46 -07:00
Bruno de Oliveira Abinader
6c4cb063c2
[Qt] UpdateParameters should always be available when rendering
2018-10-01 23:51:33 +03:00
Konstantin Käfer
071129bf61
[linux,qt] Remove remainder of WebP support
2018-09-13 13:27:44 +02:00
Konstantin Käfer
e51eb0fc23
[build] use vendored version of ICU
2018-09-05 12:26:15 +02:00
Molly Lloyd
2cdbe934c2
[windows, qt] fix windows compiler errors, remove tao + tuple polyfill
2018-08-31 13:08:47 -07:00
Asheem Mamoowala
bc806d4354
Use QSqlError::databaseText for reporting errors from SQLite wrapper to match SQLite3 error messages
2018-08-28 07:14:54 -07:00
Konstantin Käfer
112bbc7ab2
[core] make style/conversion.hpp implementation private
2018-08-19 13:09:16 +02:00
Konstantin Käfer
fa7b70945f
[core] harden OfflineDatabase
2018-08-14 17:03:46 -07:00
John Firebaugh
b2f60a4bf2
[core] Eliminate setProperty & co.
2018-08-13 12:39:44 -07:00
Paolo Angelelli
8ae5ea953e
[qt] Use FollowRedirectsAttribute in network requests
2018-08-10 14:08:21 +03:00
Sudarsana Babu Nagineni
dfb9325057
[Qt] Add CMake toolchain for QNX platform
...
This adds CMake toolchain for QNX platform. By using this
toolchain, we can compile Mapbox GL Plugin for Qt on QNX
platform.
2018-08-07 15:50:14 +03:00
Bruno de Oliveira Abinader
66f5be3864
[Qt] Check if property value is a valid JSON string
2018-08-06 18:08:02 +03:00
Bruno de Oliveira Abinader
58d8b771a1
[Qt] QMapboxGL::set{Paint,Layout}Property should return bool
2018-08-01 13:36:11 +03:00
Sudarsana Babu Nagineni
377a6e42d6
[Qt] Fix link to Qt public API headers in README.md
2018-07-30 15:21:18 +03:00
John Firebaugh
f149951f0f
[build] Remove obsolete bitrise.yml files
2018-07-24 14:28:29 -07:00
Asheem Mamoowala
7c585244ab
Use Filter::serialize() in QMapboxGL::getFilter()
2018-07-23 09:12:26 -07:00
John Firebaugh
ca9ba9cb43
[build] Move all mason_use statements to a single file
...
So its checksum can be used in a CI cache key name.
2018-07-13 11:50:39 -07:00