summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorJohn Firebaugh <john.firebaugh@gmail.com>2015-08-24 10:47:30 -0700
committerJohn Firebaugh <john.firebaugh@gmail.com>2015-08-24 10:47:30 -0700
commit0451aca37e866c3380072b114e2d49353888e4b5 (patch)
tree899dcf40ef2ea0f51e25640556548d63cad60a21 /include
parente42e3ea3a00fd7d74ff73b955ebcb8d202362088 (diff)
parente97662972fef0e56132a03f2c2510c0da8537aad (diff)
downloadqtlocation-mapboxgl-0451aca37e866c3380072b114e2d49353888e4b5.tar.gz
Merge branch 'v8'
Diffstat (limited to 'include')
-rw-r--r--include/mbgl/storage/resource.hpp4
-rw-r--r--include/mbgl/style/style_properties.hpp15
-rw-r--r--include/mbgl/style/types.hpp2
3 files changed, 19 insertions, 2 deletions
diff --git a/include/mbgl/storage/resource.hpp b/include/mbgl/storage/resource.hpp
index 2fcb3b1b78..0c2a27e9d1 100644
--- a/include/mbgl/storage/resource.hpp
+++ b/include/mbgl/storage/resource.hpp
@@ -13,8 +13,8 @@ struct Resource {
Source,
Tile,
Glyphs,
- JSON,
- Image
+ SpriteImage,
+ SpriteJSON
};
const Kind kind;
diff --git a/include/mbgl/style/style_properties.hpp b/include/mbgl/style/style_properties.hpp
index 9ab528586f..23354b1a24 100644
--- a/include/mbgl/style/style_properties.hpp
+++ b/include/mbgl/style/style_properties.hpp
@@ -45,6 +45,20 @@ struct LineProperties {
}
};
+struct CircleProperties {
+ inline CircleProperties() {}
+ float radius = 5.0f;
+ Color color = {{ 0, 0, 0, 1 }};
+ float opacity = 1.0f;
+ std::array<float, 2> translate = {{ 0, 0 }};
+ TranslateAnchorType translateAnchor = TranslateAnchorType::Map;
+ float blur = 0;
+
+ inline bool isVisible() const {
+ return radius > 0 && color[3] > 0 && opacity > 0;
+ }
+};
+
struct SymbolProperties {
inline SymbolProperties() {}
@@ -100,6 +114,7 @@ struct BackgroundProperties {
typedef mapbox::util::variant<
FillProperties,
LineProperties,
+ CircleProperties,
SymbolProperties,
RasterProperties,
BackgroundProperties,
diff --git a/include/mbgl/style/types.hpp b/include/mbgl/style/types.hpp
index e46ece6f4a..adc13b386c 100644
--- a/include/mbgl/style/types.hpp
+++ b/include/mbgl/style/types.hpp
@@ -27,6 +27,7 @@ enum class StyleLayerType : uint8_t {
Unknown,
Fill,
Line,
+ Circle,
Symbol,
Raster,
Background
@@ -36,6 +37,7 @@ MBGL_DEFINE_ENUM_CLASS(StyleLayerTypeClass, StyleLayerType, {
{ StyleLayerType::Unknown, "unknown" },
{ StyleLayerType::Fill, "fill" },
{ StyleLayerType::Line, "line" },
+ { StyleLayerType::Circle, "circle" },
{ StyleLayerType::Symbol, "symbol" },
{ StyleLayerType::Raster, "raster" },
{ StyleLayerType::Background, "background" },