Commit Graph

91 Commits

Author SHA1 Message Date
John Firebaugh
f3d4107d19 [core] Add a method for statically evaluating font stacks used by a style 2016-02-10 15:40:20 -08:00
John Firebaugh
52689796df [core] Normalize only raster source tile URLs 2016-02-01 20:25:55 -08:00
John Firebaugh
04cc019f54 [core] Refactor TileJSON parsing for offline 2016-02-01 15:33:37 -08:00
John Firebaugh
4dc7ec0202 [core] Camel-case member names 2016-01-29 14:49:25 -08:00
John Firebaugh
d90d374203 [core] Move rapidjson document creation into StyleParser 2016-01-28 17:37:23 -08:00
John Firebaugh
4328e6fd0d [core] tileSize is a source property, not a TileJSON property 2016-01-15 11:48:47 -08:00
Minh Nguyễn
4f08ef150d [core] Fixed build error in Xcode 7.3
Removed std::move() call per Xcode fix-it suggestion.
2016-01-14 10:52:13 +01:00
Konstantin Käfer
e8705d535d [core] move SourceInfo parsing to StyleParser 2016-01-13 13:04:59 -08:00
Konstantin Käfer
cef05b9017 [core] move invariant Source ID from SourceInfo to Source 2016-01-13 13:04:59 -08:00
Konstantin Käfer
f00a6a997b [core] move invariant SourceType from SourceInfo to Source 2016-01-13 13:04:59 -08:00
John Firebaugh
d238e00d9b [core] Remove RapidJSON and GeoJSONVT dependencies from SourceInfo
It's going to be exposed in the public core API as part of #3374.
2015-12-23 14:48:41 -08:00
Konstantin Käfer
95cef66e22 [core] change RapidJSON usage to use CrtAllocator and bump GeoJSON VT 2015-12-14 16:43:35 -08:00
Konstantin Käfer
8d711e9c80 [test] update test suite to include more comprehensive GeoJSON tests 2015-12-11 16:23:43 -08:00
Konstantin Käfer
c4a01d51ea [core] don't fail on invalid inline GeoJSON data 2015-12-11 16:23:43 -08:00
Konstantin Käfer
0f9922cff5 [core] create GeoJSON tiles from inline GeoJSON in sources 2015-12-11 16:23:42 -08:00
Konstantin Käfer
2f973d0a7e [core] parse GeoJSON source type 2015-12-11 16:23:42 -08:00
Konstantin Käfer
132b68e4fc [core] split Source parsing into separate functions 2015-12-11 15:25:12 -08:00
John Firebaugh
e04c5f6506 [core] Replace StyleLayerType with RTTI 2015-12-07 18:22:33 -08:00
Konstantin Käfer
d5fb535058 [core] add namespace comment to closing brace 2015-12-03 15:38:36 +01:00
John Firebaugh
bafbf6c04b [core] Don't share util::ptr<StyleLayer> across threads 2015-12-01 11:16:57 -08:00
John Firebaugh
f27c28b6c4 Partially revert "[core] Source should receive a ref to MapData just once"
This partially reverts commit d55aa7929c.
2015-12-01 09:07:03 -08:00
Bruno de Oliveira Abinader
d55aa7929c [core] Source should receive a ref to MapData just once 2015-11-27 17:47:02 +02:00
John Firebaugh
f9ebe54a63 [core] Merge Sprite into SpriteStore 2015-11-12 13:03:14 -08:00
John Firebaugh
728a9858ea [core] Push layouts and paints to subclasses 2015-11-10 11:33:17 -08:00
John Firebaugh
540c6eca15 [core] Eliminate StyleBucket 2015-10-30 11:19:28 -07:00
John Firebaugh
7821dccae5 [core] Polymorphic layout and paint parsing 2015-10-29 16:46:49 -07:00
John Firebaugh
bb6241844a [core] Extract PaintPropertiesMap 2015-10-26 12:00:11 -07:00
John Firebaugh
8d79c25765 [core] Remove MapData dependency from StyleParser
MapData was needed for two things: getting the default transition and
fade durations, and detecting still rendering vs. continuous.

The first is avoided by making transition durations optional, and
supplying the default fallback value at evaluation time. The second did
not fix the still rendering issue, and will be followed up with a
different approach in a later commit.
2015-10-23 13:56:55 -07:00
John Firebaugh
3afc8b4a29 [core] Introduce StyleLayer subclasses 2015-10-22 09:34:40 -07:00
Bruno de Oliveira Abinader
9a97333e85 [core] Set fade/transition duration to 0 if map mode is still 2015-10-14 11:49:18 -07:00
John Firebaugh
2066295e35 Install RapidJSON from mason 2015-10-01 11:40:47 -07:00
John Firebaugh
af392b9434 Rewrite annotation invalidation strategy
First, move style mutation code out of StyleParser and into AnnotationManager,
coalescing it with the mutation code for shape layers.

Second, allow AnnotationManager to keep track of stale tiles entirely
internally. There's no reason to pass sets of TileIDs around.

Third, correct the logic for invalidating the shape source. Since
AnnotationManager does not track shape invalidations on a tile-by-tile basis,
don't try to invalidate the shape source tile-by-tile.

Fixes #1675
Fixes #2322
Fixes #2095
2015-09-28 14:10:23 -07:00
John Firebaugh
0c4c7ed901 map/annotation.* ⇢ annotation/annotation_manager.* 2015-09-28 14:10:01 -07:00
Ansis Brammanis
60e9712916 remove text-max-size and icon-max-size
port https://github.com/mapbox/mapbox-gl-js/pull/1419
2015-08-20 11:59:08 -07:00
John Firebaugh
3598b166bd Remove constants
Fixes #2046
2015-08-20 11:59:07 -07:00
Bruno de Oliveira Abinader
98534631e0 Add circle render type
As specified in:
https://github.com/mapbox/mapbox-gl-style-spec/blob/v8-circle/reference/v8.json

Part of #1740.
2015-08-20 11:59:07 -07:00
Tom MacWright
d1100f34de Rename some style properties
symbol-min-distance ⇢ symbol-spacing
background-image ⇢ background-pattern
line-image ⇢ line-pattern
fill-image ⇢ fill-pattern
2015-08-20 11:58:57 -07:00
Tom MacWright
6df50dba45 Font stacks as arrays 2015-08-20 11:58:57 -07:00
Lauren Budorick
58d6b84b2b Check for v8 2015-08-20 11:58:57 -07:00
Bruno de Oliveira Abinader
0ea8a37cb0 Unify default transition values in MapData
Relevant changes:
 - Added 'defaultFadeDuration' and 'defaultTransitionDelay' to MapData;
 - Painter & StyleParser now receives a reference to MapData;
 - As previously seen on the code: 300ms is the default fade duration
   and 0ms is the default transition duration;
 - We no longer pass the current time point to Style, since it now uses
   MapData.animationTime, which gets updated in MapContext::update().
 - Updated StyleParser check to use a mock MapData;
2015-07-14 16:58:32 +03:00
John Firebaugh
c357ce540a Use unique_ptr for Source objects (fixes #904) 2015-07-02 12:55:53 -07:00
Bruno de Oliveira Abinader
3396bcaaac Cleaned up remaining bool function return values 2015-06-23 19:59:22 +03:00
Bruno de Oliveira Abinader
71ed184bc4 Improve readibility for style parser results
Introduces StyleParser::Result being a std::tuple<Status, T>, where
StyleParser::Status is a boolean enumerator which improves readibility.
2015-06-23 19:58:14 +03:00
Bruno de Oliveira Abinader
7bfae2a1a5 Fix result value from parseProperty when T = std::array<float, 2> 2015-06-22 22:46:37 +03:00
John Firebaugh
0cce08b67b Change StyleBucket::source to indirect reference
This eliminates a reference loop: VectorTileData holds StyleLayers which
hold StyleBuckets which held Sources which hold VectorTileDatas. This
breaks the StyleBucket -> Source link in favor of manually resolving the
reference where necessary.
2015-06-18 13:39:18 +03:00
Justin R. Miller
bd0bf294bf squash of #1655: shape annotations support for core & iOS 2015-06-15 18:30:39 -07:00
Konstantin Käfer
f4707f72e0 Replace mbgl::util::make_unique<> with std::make_unique<> 2015-05-26 17:57:38 +02:00
Dane Springmeyer
74604af9c5 fix compile with clang-3.6 2015-05-01 11:00:01 -07:00
Konstantin Käfer
2b633cc51c build on Travis' sudo: false infrastructure 2015-04-28 10:43:13 +02:00
Ansis Brammanis
65306490dd icon-rotate is not a paint property
issue #1173
2015-04-24 15:34:53 -07:00