summaryrefslogtreecommitdiff
path: root/src/mbgl/style/layers/layer_properties.hpp.ejs
diff options
context:
space:
mode:
Diffstat (limited to 'src/mbgl/style/layers/layer_properties.hpp.ejs')
-rw-r--r--src/mbgl/style/layers/layer_properties.hpp.ejs10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/mbgl/style/layers/layer_properties.hpp.ejs b/src/mbgl/style/layers/layer_properties.hpp.ejs
index 89dffdcd42..de647fbc07 100644
--- a/src/mbgl/style/layers/layer_properties.hpp.ejs
+++ b/src/mbgl/style/layers/layer_properties.hpp.ejs
@@ -37,6 +37,13 @@ struct <%- camelize(property.name) %> : <%- paintPropertyType(property, type) %>
template<typename T> static bool hasOverride(const T& t) { return !!t.<%- camelizeWithLeadingLowercase(property.name) %>; };
<% } -%>
};
+<% if (property.name === 'line-width') { -%>
+
+struct LineFloorWidth : DataDrivenPaintProperty<float, attributes::floorwidth, uniforms::floorwidth> {
+ using EvaluatorType = DataDrivenPropertyEvaluator<float, true>;
+ static float defaultValue() { return 1.0f; }
+};
+<% } -%>
<% } -%>
<% } -%>
@@ -52,6 +59,9 @@ class <%- camelize(type) %>LayoutProperties : public Properties<
class <%- camelize(type) %>PaintProperties : public Properties<
<% for (const property of paintProperties.slice(0, -1)) { -%>
<%- camelize(property.name) %>,
+<% if (property.name === 'line-width') { -%>
+ LineFloorWidth,
+<% } -%>
<% } -%>
<%- camelize(paintProperties.slice(-1)[0].name) %>
> {};