John Firebaugh
39d5cb3250
[core] Use VAOs internally
2016-10-28 17:14:07 -07:00
John Firebaugh
0e57d10d77
[core] Modern C++ bindings for OpenGL
2016-10-28 17:14:01 -07:00
John Firebaugh
a4c82b8a3b
[core] operator bool() must always be explicit
...
Otherwise, it can participate in unexpected conversions. Case in point: GlyphSet::insert was comparing the result of GlyphMetrics::operator bool() where it wanted to use operator==.
2016-10-28 17:10:45 -07:00
John Firebaugh
ee3235708f
[core] Methods don't need to be Painter instance methods
2016-10-28 17:09:51 -07:00
Konstantin Käfer
62b56b799a
[core] change std::array<uint16_t, 2> to mbgl::Size
2016-10-27 18:30:58 -07:00
Konstantin Käfer
ef8017198c
[core] remove tiles for disabled sources
...
When no layer of a source is visible anymore, we are now evicting tiles that are still stored in that source and move them to the cache.
2016-10-27 18:14:53 -07:00
Konstantin Käfer
91272992f3
[core] don't load tiles from sources that aren't used
2016-10-27 16:15:36 -07:00
Konstantin Käfer
a4d259c33f
[core] move gl::Context to Backend and refactor View
2016-10-25 13:52:36 -07:00
Konstantin Käfer
5cc390d694
[core] separate Backend from View for headless rendering
2016-10-25 13:52:36 -07:00
Ivo van Dongen
b14e83ea40
[core] geojson source - cancel any pending request when setting geojson explicitly
2016-10-25 16:11:36 +02:00
Ivo van Dongen
6277dca898
[core] geojson source - clear cache when json content is set
2016-10-25 16:11:36 +02:00
Ivo van Dongen
068e78a2e7
[core] geojson source - reset req on setURL
2016-10-25 12:47:35 +02:00
Bruno de Oliveira Abinader
e55065e62a
[core] Reuse last placement data in CollisionTile::queryRenderedFeatures
...
To obtain precise results, we:
1. Round scale value to obtain same results from symbol shader.
2. Generate a boost geometry polygon to check if it intersects()
against all feature boxes.
3. Check if current scale is within each feature's minimum and maximum
placement scales.
4. De-scale feature boxes when intersecting to account for the
fractional zoom scaling.
2016-10-25 08:12:31 +03:00
Bruno de Oliveira Abinader
fc6344c546
[core] Added util::polygonIntersectsPolygon
2016-10-25 08:12:31 +03:00
Bruno de Oliveira Abinader
679bfbfb32
[core] Simplify CollisionTile::findPlacementScale
...
Improve findPlacementScale semantics by moving the check if the
placement scale result is bigger than minimum scale out of the function
scope.
2016-10-25 08:12:31 +03:00
Bruno de Oliveira Abinader
846e57de58
[core] Avoid duplicating edges for CollisionTile
...
Make 'edges' static to avoid every instance of CollisionTile having its
own copy of it.
2016-10-25 08:12:31 +03:00
Bruno de Oliveira Abinader
8743f11345
[core] Cleanup function signatures in CollisionTile
...
- Prefer pass-by-value for primitive types.
- Use floating point precision for yStretch to match receiving type.
2016-10-25 08:12:31 +03:00
Ivo van Dongen
e31a2c1c11
[core] fixup formatting
2016-10-21 10:05:00 -07:00
Mike Morris
7bbd49c72c
[core] extract weak_ptr mailbox->receive into Mailbox::maybeReceive
2016-10-20 14:39:11 -04:00
Mike Morris
817c26111a
[core] [node] pass thread pool impl to Map constructor
...
Updates mbgl::Map constructor usage everywhere
Adds NodeThreadPool implementation using AsyncQueue to call
Nan::AsyncQueueWorker from main thread
2016-10-20 14:37:36 -04:00
Ivo van Dongen
ab63a9494f
[core] reload geojson source on url change
2016-10-20 16:18:08 +03:00
Bruno de Oliveira Abinader
c50577d039
[core] Fix SymbolAnnotation coordinate system conversions
2016-10-19 08:11:41 +03:00
Bruno de Oliveira Abinader
ef62b78fce
[core] TileCoordinate::fromLatLng no longer depens on TransformState
2016-10-19 08:11:41 +03:00
Bruno de Oliveira Abinader
2188d68b6c
[core] Move TransformState::{un,}project() to Projection
2016-10-19 08:11:41 +03:00
Bruno de Oliveira Abinader
f01a829dc9
[core] Move TransformState::worldSize() to Projection
2016-10-19 08:11:41 +03:00
Bruno de Oliveira Abinader
3a12dd2d4f
[core] Skip redundant spherical mercator variable updates in {ease,fly}To
2016-10-19 08:11:41 +03:00
Bruno de Oliveira Abinader
19d3c5ca25
[core] Cleanup SymbolLayout
...
Reuse reverse rotation matrix from CollisionTile when populating the
collision boxes.
2016-10-13 07:39:25 +03:00
Bruno de Oliveira Abinader
a6d0e21472
[core] Disable stencil test when rendering collision boxes
2016-10-12 19:01:08 +03:00
Bruno de Oliveira Abinader
436a22efe9
[core] Skip duplicated IDs when querying point annotations
2016-10-12 18:58:22 +03:00
Bruno de Oliveira Abinader
36b3ba56b6
[core] Improve Source::Impl readability
2016-10-11 19:36:21 +03:00
Bruno de Oliveira Abinader
7b907b6d1c
[core] Use TilePoint in Source::Impl::queryRenderedFeatures
2016-10-11 19:36:21 +03:00
Bruno de Oliveira Abinader
623a124e01
[core] Use query geometry from FeatureIndex into CollisionTile::queryRenderedSymbols
2016-10-11 12:10:32 +03:00
John Firebaugh
38e78e25df
[core] No need for feature querying to support multipolygons
2016-10-11 10:54:58 +03:00
Bruno de Oliveira Abinader
efc1bff65f
[core] Ignore placement for symbol annotations
2016-10-11 09:55:32 +03:00
Bruno de Oliveira Abinader
22b7436acf
[core] Skip placement scale for features that ignore placement
2016-10-11 09:55:32 +03:00
John Firebaugh
5891c7028d
Update mapbox-gl-shaders to 98a56d
2016-10-10 12:46:52 -07:00
Bruno de Oliveira Abinader
3b8b68d028
[core] Fix Map::setLatLng behavior
...
We were erroneously assigning a value to optional<ScreenCoordinate>
(null island), causing it to be a valid anchor for Transform::easeTo.
2016-10-07 17:23:17 +03:00
John Firebaugh
21d7ee11e1
[core] Rationalize shader names
...
{layer type}{subtype}Shader
2016-10-06 14:47:58 -07:00
John Firebaugh
f438bb68b0
[core] Adhere to vertices/vertexBuffer naming convention
2016-10-05 10:52:19 -07:00
John Firebaugh
da4527cd3a
[core] TextureRectVertex ⇢ SymbolVertex
2016-10-05 10:52:19 -07:00
John Firebaugh
9cf57e7142
[core] Make ElementGroup safer
...
Template on shader types, rather than count. This allows the compiler to enforce using the correct VAO for the shader and PaintMode. This fixes OverdrawMode with circle layers.
While here, avoid using unique_ptrs for groups. Instead, ensure ElementGroup is movable.
2016-10-05 10:52:19 -07:00
John Firebaugh
e4310aa874
[core] Improve attribute binding API
2016-10-05 10:52:19 -07:00
John Firebaugh
b9b8657d43
[core] Put VertexArrayObject in gl namespace
2016-10-05 10:52:19 -07:00
John Firebaugh
73334ac8fa
[core] Move shader and uniform to gl directory
2016-10-05 10:52:19 -07:00
John Firebaugh
7a3bef091e
[core] Refactor Buffer
2016-10-05 10:52:19 -07:00
John Firebaugh
ac8a74ebcc
[core] Don't refer to geometry coordinates as "vertices"
2016-10-05 10:52:19 -07:00
John Firebaugh
31be5d3c3a
[core] Tiles that error on load are not renderable
2016-10-05 10:26:04 -07:00
Thiago Marcos P. Santos
dd604a7b36
[core] Pre-filter sources based on the layers they contain
2016-10-05 11:12:16 +03:00
Konstantin Käfer
07315711d6
[core] remove Raster object in favor of a more low-level Texture object
2016-10-04 14:00:30 -07:00
Sam Matthews
280fd8c28e
[core] Preserve non-access_token query parameters in canonicalizeTileURL
2016-10-03 10:08:17 -07:00