John Firebaugh
625c2ea527
[core] When a layer is added, reload its source's tiles
2017-05-11 08:47:32 -07:00
John Firebaugh
c130d470a1
[core] Remove StyleSourcedAnnotation support
...
The functionality this provided has been subsumed by the runtime styling API.
2017-05-10 14:22:01 -07:00
John Firebaugh
baaae99a03
[core, android] Factor JSON string conversions
...
This adds a `convertJSON` template, to be used like:
Error error
optional<Foo> foo = convertJSON<Foo>(string, error);
Internally, it parses the string with RapidJSON and then calls `convert<Foo>(parsed, error)`.
While here, rationalize GeoJSON converters and fix error handling for Tileset conversion in OfflineDownload.
2017-05-08 13:48:57 -07:00
Ivo van Dongen
6fd40867d6
[core] delegate light changes to render light
2017-05-08 19:39:55 +03:00
Ivo van Dongen
feae5e22ee
[core] generated accessor methods on light
2017-05-08 19:39:55 +03:00
Ivo van Dongen
20810f988a
[core] render light
2017-05-08 19:39:55 +03:00
Lauren Budorick
1c9af3226f
[core] Reuse fill-extrusion textures between frames ( #8896 )
2017-05-08 09:06:07 -07:00
John Firebaugh
dd353a60d1
[core] Reset observers of removed Sources and Layers
...
This ensures that the observer is not an invalid reference if the removed Source/Layer is retained, but the Style is deallocated.
2017-05-05 09:23:01 -07:00
John Firebaugh
7ca8fd07e0
[core] Remove unused declaration
2017-05-05 08:57:30 -07:00
John Firebaugh
66da759426
[core] Reduce use of RecalculateStyle
...
* Don't use it to track zoom changes. Instead, Style::update can use the zoom history to check for a change in zoom from the previous frame.
* Don't use it to track active property transitions. Style already knows which layers/light have an active transition, and can re-evaluate only those that do.
This leaves layer property changes as the only use of RecalculateStyle.
2017-05-05 08:56:36 -07:00
Konstantin Käfer
fd104dd3c2
[core] Throw exceptions by value
2017-05-05 14:42:47 +02:00
John Firebaugh
e7d2796762
[core] Omnibus Style::update method
...
Combine Style::cascade, recalculate, relayout, and updateTiles into a single method. This allows multiple loops over sources and layers to be consolidated and prepares for additional Style-Map decoupling: rather than tracking pending updates via a set of Update flags held by the Map and passed to the Style, the Style can use its own data to determine what to update.
2017-05-04 09:59:56 -07:00
John Firebaugh
89f1ffc6d2
[core] UpdateParameters ⇢ TileParameters
2017-05-04 07:29:08 -07:00
John Firebaugh
3790caafa3
[core] Factor timePoint initialization
2017-05-03 11:20:01 -07:00
John Firebaugh
88093bd708
[core] Calculate hasPendingTransitions functionally rather than statefully
2017-05-03 10:41:04 -07:00
John Firebaugh
d5f4d0f05f
[core] Move render-related sources out of style directory/namespace
...
Moves the following to the renderer directory and out of the style namespace:
* CascadeParameters
* PropertyEvaluationParameters
* UpdateParameters
* PropertyEvaluator
* DataDrivenPropertyEvaluator
* CrossFadedPropertyEvaluator
* PaintPropertyBinder
* PaintProperyStatistics
* PossiblyEvaluatedPropertyValue
* TransitioningLight
* EvaluatedLight
2017-05-03 08:30:17 -07:00
John Firebaugh
6c7730ee7c
[core] No need to Update::Classes after removing a layer
2017-05-03 08:30:02 -07:00
John Firebaugh
b8b9978b69
[core] No need to manually set Update::Classes flag after annotation update
...
Since the advent of the runtime styling APIs, the APIs used by AnnotationManager::updateStyle will automatically set this flag as needed.
2017-05-03 08:30:02 -07:00
John Firebaugh
1e26d99e1e
[core] Remove forced style cascade
...
This should happen automatically during rendering. After removing, I can no longer replicate the original issue (#1889 ).
2017-05-03 08:29:46 -07:00
John Firebaugh
e9872b4ed0
Revert "[node] Temporary: exit(0) on exception in Painter::render"
...
This reverts commit f0d4411871 .
2017-05-02 16:13:21 -07:00
Asheem Mamoowala
5c52401d55
[core] Make Map.addImage tests pass ( #8843 )
...
Fix Node tests suite implementation to parse pixelRatio from style json
Premultiply images in the node binding before sending to mbgl core
2017-05-02 09:54:06 -07:00
John Firebaugh
3f0c89d633
[core] Refactor Source::*Impls into RenderSources and TilePyramid
2017-05-02 08:45:09 -07:00
John Firebaugh
197751bace
[core] Load source TileJSON immediately
...
This reverses #3095 . Rationale:
* We're now exposing source attributes as a public API. Making those attributes unavailable at certain times complicates that API.
* We're preparing to split RenderSource out of Source. Removing this removes a point of coupling between the two.
2017-05-02 08:45:09 -07:00
John Firebaugh
c2b00378b7
[all] Push querySourceFeatures back out to Map
...
Once Source and RendererSource are split, Source will no longer have access to tiles.
2017-05-02 08:45:09 -07:00
Thiago Marcos P. Santos
bc868b8433
[core] Suppress "stencil mask overflow" warning
...
When it starts, we get a log warning for every frame, which is
expensive. Now we get only one warning.
2017-05-02 12:25:38 +03:00
Lauren Budorick
f6e79d7073
[core] Render fill-extrusion layers ( #8431 )
2017-04-27 15:56:55 -07:00
John Firebaugh
1c42daa152
[core] Tweak handling of annotation special case SpriteAtlas
...
* Simplify SymbolLayout; it never needs to care about more than one SpriteAtlas.
* Move the reference from SymbolLayer::Impl to SymbolBucket. This is a prerequisite for making layer Impls immutable.
2017-04-26 16:29:44 -07:00
Ivo van Dongen
3c175adf30
[core] split off render layers
2017-04-25 17:23:54 -07:00
John Firebaugh
5dd98df50b
[all] Rationalize style::Image
...
A style has a collection of images, just as it has collections of sources and layers.
* Name things appropriately
* Use std::unique_ptr
2017-04-24 15:52:28 -07:00
Vladimir Agafonkin
0079d6173b
[core] fix an issue with lines that have duplicate points ( #8808 )
...
An equivalent of https://github.com/mapbox/mapbox-gl-js/pull/4634 .
2017-04-24 18:53:20 +03:00
Konstantin Käfer
59055cf403
[core] Move Sprite parsing to thread pool
2017-04-24 10:42:47 +02:00
John Firebaugh
3c23faf65a
[core] More complete fix for composite function interpolation edge case
...
b5b4549 / #8613 handled the edge case for layout properties, but not paint properties. Move the check for a degenerate range to interpolationFactor in order to handle both correctly.
2017-04-20 16:11:57 -07:00
Konstantin Käfer
97f2a44859
[core] remove unused leftover files
2017-04-20 20:04:33 +02:00
Konstantin Käfer
9a9408e811
[core] Render parent raster tiles when ideal tile can't be loaded
2017-04-20 09:38:18 +02:00
Ivo van Dongen
7ddca3b611
[core] account for property functions in query rendered features
2017-04-19 17:21:28 -07:00
Ivo van Dongen
d752235ec7
[core] make Tile::getBucket const
2017-04-19 17:21:28 -07:00
Ivo van Dongen
935cf531e4
[core] property function statistics collection
2017-04-19 17:21:28 -07:00
John Firebaugh
efa6c01956
[core] Remove unnecessary Source::Impl::enabled assignment
...
This flag will get set automatically by Style::recalculate.
2017-04-18 08:49:57 -07:00
John Firebaugh
092da9c956
[core] Remove non-Map-dependent projection methods from Map
2017-04-18 14:43:31 +03:00
John Firebaugh
fcf5d1b8af
[core] Combine two GlyphID-keyed maps in GlyphAtlas::Entry
2017-04-14 15:39:31 -07:00
John Firebaugh
a50d7a331b
[core] Replace GlyphRangeSet in onGlyphsAvailable with optionals in the map
...
GlyphRangeSet isn't keyed by FontStack, so using it to indicate that a particular range was loaded could have produced false positives.
2017-04-14 15:39:31 -07:00
Bruno de Oliveira Abinader
09a2271576
[core] Ignore shortest path in Map::pixelForLatLng
2017-04-14 12:52:20 -07:00
Bruno de Oliveira Abinader
98e2e59e5e
[core] Safeguard PositionedIcon usage via optional
2017-04-14 12:33:13 -07:00
Bruno de Oliveira Abinader
2f4d162deb
[core] Tighten geo.hpp ctors
2017-04-14 12:33:13 -07:00
Bruno de Oliveira Abinader
8877452ec3
[core] TransitionOptions s/operator bool/isDefined/
2017-04-14 12:33:13 -07:00
John Firebaugh
f1c06f8d83
[all] Remove redundant scale-related camera methods
...
We don't need to have two different measurement systems for map zoom.
2017-04-13 10:28:44 -07:00
John Firebaugh
a2670336d4
[tests] Rewrite GlyphAtlas tests to use public API
2017-04-13 10:10:56 -07:00
John Firebaugh
0810192163
[core] Inline GlyphSet into GlyphAtlas
2017-04-12 16:57:52 -07:00
Fabian Guerra
12b6fdbe3b
Merge branch 'release-ios-v3.5.0-android-v5.0.0' into boundsj-merge-release-branch
...
# Conflicts:
# cmake/core-files.cmake
# mapbox-gl-js
# platform/android/CHANGELOG.md
# platform/ios/CHANGELOG.md
# platform/macos/CHANGELOG.md
# platform/qt/bitrise-qt5.yml
# src/mbgl/gl/attribute.hpp
# src/mbgl/gl/context.cpp
# src/mbgl/gl/program.hpp
# src/mbgl/map/map.cpp
# src/mbgl/programs/program.hpp
# src/mbgl/renderer/painter.cpp
2017-04-11 21:46:23 -04:00
John Firebaugh
62576e24a0
[core] Revert use of optional<EdgeInsets>, because EdgeInsets has a natural "empty" state
2017-04-11 14:50:22 -07:00