diff options
Diffstat (limited to 'include/mbgl/style/layers')
-rw-r--r-- | include/mbgl/style/layers/circle_layer.hpp | 6 | ||||
-rw-r--r-- | include/mbgl/style/layers/custom_layer.hpp | 16 | ||||
-rw-r--r-- | include/mbgl/style/layers/line_layer.hpp | 6 | ||||
-rw-r--r-- | include/mbgl/style/layers/symbol_layer.hpp | 32 |
4 files changed, 45 insertions, 15 deletions
diff --git a/include/mbgl/style/layers/circle_layer.hpp b/include/mbgl/style/layers/circle_layer.hpp index 275a2e67a5..942dd67503 100644 --- a/include/mbgl/style/layers/circle_layer.hpp +++ b/include/mbgl/style/layers/circle_layer.hpp @@ -78,6 +78,12 @@ public: void setCirclePitchScaleTransition(const TransitionOptions&); TransitionOptions getCirclePitchScaleTransition() const; + static PropertyValue<AlignmentType> getDefaultCirclePitchAlignment(); + PropertyValue<AlignmentType> getCirclePitchAlignment() const; + void setCirclePitchAlignment(PropertyValue<AlignmentType>); + void setCirclePitchAlignmentTransition(const TransitionOptions&); + TransitionOptions getCirclePitchAlignmentTransition() const; + static DataDrivenPropertyValue<float> getDefaultCircleStrokeWidth(); DataDrivenPropertyValue<float> getCircleStrokeWidth() const; void setCircleStrokeWidth(DataDrivenPropertyValue<float>); diff --git a/include/mbgl/style/layers/custom_layer.hpp b/include/mbgl/style/layers/custom_layer.hpp index 79a353b047..bf3387f95b 100644 --- a/include/mbgl/style/layers/custom_layer.hpp +++ b/include/mbgl/style/layers/custom_layer.hpp @@ -39,6 +39,14 @@ struct CustomLayerRenderParameters { using CustomLayerRenderFunction = void (*)(void* context, const CustomLayerRenderParameters&); /** + * Called when the system has destroyed the underlying GL context. The + * `CustomLayerDeinitializeFunction` will not be called in this case, however + * `CustomLayerInitializeFunction` will be called instead to prepare for a new render. + * + */ +using CustomLayerContextLostFunction = void (*)(void* context); + +/** * Destroy any GL state needed by the custom layer, and deallocate context, if necessary. This * method is called once, from the main thread, at a point when the GL context is active. * @@ -51,8 +59,16 @@ public: CustomLayer(const std::string& id, CustomLayerInitializeFunction, CustomLayerRenderFunction, + CustomLayerContextLostFunction, CustomLayerDeinitializeFunction, void* context); + + CustomLayer(const std::string& id, + CustomLayerInitializeFunction, + CustomLayerRenderFunction, + CustomLayerDeinitializeFunction, + void* context); + ~CustomLayer() final; // Visibility diff --git a/include/mbgl/style/layers/line_layer.hpp b/include/mbgl/style/layers/line_layer.hpp index 0b49690fd8..4519296323 100644 --- a/include/mbgl/style/layers/line_layer.hpp +++ b/include/mbgl/style/layers/line_layer.hpp @@ -42,9 +42,9 @@ public: PropertyValue<LineCapType> getLineCap() const; void setLineCap(PropertyValue<LineCapType>); - static PropertyValue<LineJoinType> getDefaultLineJoin(); - PropertyValue<LineJoinType> getLineJoin() const; - void setLineJoin(PropertyValue<LineJoinType>); + static DataDrivenPropertyValue<LineJoinType> getDefaultLineJoin(); + DataDrivenPropertyValue<LineJoinType> getLineJoin() const; + void setLineJoin(DataDrivenPropertyValue<LineJoinType>); static PropertyValue<float> getDefaultLineMiterLimit(); PropertyValue<float> getLineMiterLimit() const; diff --git a/include/mbgl/style/layers/symbol_layer.hpp b/include/mbgl/style/layers/symbol_layer.hpp index 8158f267c9..a72baa0b4e 100644 --- a/include/mbgl/style/layers/symbol_layer.hpp +++ b/include/mbgl/style/layers/symbol_layer.hpp @@ -98,6 +98,14 @@ public: DataDrivenPropertyValue<std::array<float, 2>> getIconOffset() const; void setIconOffset(DataDrivenPropertyValue<std::array<float, 2>>); + static DataDrivenPropertyValue<SymbolAnchorType> getDefaultIconAnchor(); + DataDrivenPropertyValue<SymbolAnchorType> getIconAnchor() const; + void setIconAnchor(DataDrivenPropertyValue<SymbolAnchorType>); + + static PropertyValue<AlignmentType> getDefaultIconPitchAlignment(); + PropertyValue<AlignmentType> getIconPitchAlignment() const; + void setIconPitchAlignment(PropertyValue<AlignmentType>); + static PropertyValue<AlignmentType> getDefaultTextPitchAlignment(); PropertyValue<AlignmentType> getTextPitchAlignment() const; void setTextPitchAlignment(PropertyValue<AlignmentType>); @@ -118,25 +126,25 @@ public: DataDrivenPropertyValue<float> getTextSize() const; void setTextSize(DataDrivenPropertyValue<float>); - static PropertyValue<float> getDefaultTextMaxWidth(); - PropertyValue<float> getTextMaxWidth() const; - void setTextMaxWidth(PropertyValue<float>); + static DataDrivenPropertyValue<float> getDefaultTextMaxWidth(); + DataDrivenPropertyValue<float> getTextMaxWidth() const; + void setTextMaxWidth(DataDrivenPropertyValue<float>); static PropertyValue<float> getDefaultTextLineHeight(); PropertyValue<float> getTextLineHeight() const; void setTextLineHeight(PropertyValue<float>); - static PropertyValue<float> getDefaultTextLetterSpacing(); - PropertyValue<float> getTextLetterSpacing() const; - void setTextLetterSpacing(PropertyValue<float>); + static DataDrivenPropertyValue<float> getDefaultTextLetterSpacing(); + DataDrivenPropertyValue<float> getTextLetterSpacing() const; + void setTextLetterSpacing(DataDrivenPropertyValue<float>); - static PropertyValue<TextJustifyType> getDefaultTextJustify(); - PropertyValue<TextJustifyType> getTextJustify() const; - void setTextJustify(PropertyValue<TextJustifyType>); + static DataDrivenPropertyValue<TextJustifyType> getDefaultTextJustify(); + DataDrivenPropertyValue<TextJustifyType> getTextJustify() const; + void setTextJustify(DataDrivenPropertyValue<TextJustifyType>); - static PropertyValue<TextAnchorType> getDefaultTextAnchor(); - PropertyValue<TextAnchorType> getTextAnchor() const; - void setTextAnchor(PropertyValue<TextAnchorType>); + static DataDrivenPropertyValue<SymbolAnchorType> getDefaultTextAnchor(); + DataDrivenPropertyValue<SymbolAnchorType> getTextAnchor() const; + void setTextAnchor(DataDrivenPropertyValue<SymbolAnchorType>); static PropertyValue<float> getDefaultTextMaxAngle(); PropertyValue<float> getTextMaxAngle() const; |