diff options
Diffstat (limited to 'include/mbgl/map')
-rw-r--r-- | include/mbgl/map/map.hpp | 1 | ||||
-rw-r--r-- | include/mbgl/map/map_options.hpp | 15 |
2 files changed, 15 insertions, 1 deletions
diff --git a/include/mbgl/map/map.hpp b/include/mbgl/map/map.hpp index 822c400ddf..2fdd72dcb8 100644 --- a/include/mbgl/map/map.hpp +++ b/include/mbgl/map/map.hpp @@ -34,7 +34,6 @@ class Map : private util::noncopyable { public: explicit Map(RendererFrontend&, MapObserver&, - float pixelRatio, Scheduler&, const MapOptions&, const ResourceOptions&); diff --git a/include/mbgl/map/map_options.hpp b/include/mbgl/map/map_options.hpp index 508d569ea5..fcb8c8f32f 100644 --- a/include/mbgl/map/map_options.hpp +++ b/include/mbgl/map/map_options.hpp @@ -119,6 +119,21 @@ public: */ Size size() const; + /** + * @brief Sets the custom pixel ratio. By default, it is set to 1. + * + * @param ratio Pixel ratio value. + * @return reference to MapOptions for chaining options together. + */ + MapOptions& withPixelRatio(float ratio); + + /** + * @brief Gets the previously set (or default) pixel ratio value. + * + * @return pixel ratio value. + */ + float pixelRatio() const; + private: class Impl; std::unique_ptr<Impl> impl_; |