summaryrefslogtreecommitdiff
path: root/include/mbgl/style/sources
diff options
context:
space:
mode:
Diffstat (limited to 'include/mbgl/style/sources')
-rw-r--r--include/mbgl/style/sources/raster_dem_source.hpp25
-rw-r--r--include/mbgl/style/sources/raster_source.hpp4
2 files changed, 27 insertions, 2 deletions
diff --git a/include/mbgl/style/sources/raster_dem_source.hpp b/include/mbgl/style/sources/raster_dem_source.hpp
new file mode 100644
index 0000000000..82588613bc
--- /dev/null
+++ b/include/mbgl/style/sources/raster_dem_source.hpp
@@ -0,0 +1,25 @@
+#pragma once
+
+#include <mbgl/style/sources/raster_source.hpp>
+#include <mbgl/util/tileset.hpp>
+#include <mbgl/util/variant.hpp>
+
+namespace mbgl {
+
+class AsyncRequest;
+
+namespace style {
+
+class RasterDEMSource : public RasterSource {
+public:
+ RasterDEMSource(std::string id, variant<std::string, Tileset> urlOrTileset, uint16_t tileSize);
+
+};
+
+template <>
+inline bool Source::is<RasterDEMSource>() const {
+ return getType() == SourceType::RasterDEM;
+}
+
+} // namespace style
+} // namespace mbgl
diff --git a/include/mbgl/style/sources/raster_source.hpp b/include/mbgl/style/sources/raster_source.hpp
index 7f23a7ca4b..5aa81aa979 100644
--- a/include/mbgl/style/sources/raster_source.hpp
+++ b/include/mbgl/style/sources/raster_source.hpp
@@ -12,8 +12,8 @@ namespace style {
class RasterSource : public Source {
public:
- RasterSource(std::string id, variant<std::string, Tileset> urlOrTileset, uint16_t tileSize);
- ~RasterSource() final;
+ RasterSource(std::string id, variant<std::string, Tileset> urlOrTileset, uint16_t tileSize, SourceType sourceType = SourceType::Raster);
+ ~RasterSource() override;
const variant<std::string, Tileset>& getURLOrTileset() const;
optional<std::string> getURL() const;