diff --git a/src/mbgl/style/style.cpp b/src/mbgl/style/style.cpp index 520cd12a7..035d14878 100644 --- a/src/mbgl/style/style.cpp +++ b/src/mbgl/style/style.cpp @@ -19,13 +19,12 @@ namespace mbgl { -Style::Style(const std::string& data, const std::string& base_, +Style::Style(const std::string& data, const std::string&, uv_loop_t* loop, Environment& env) : glyphStore(std::make_unique(loop, env)), glyphAtlas(std::make_unique(1024, 1024)), spriteAtlas(std::make_unique(512, 512)), lineAtlas(std::make_unique(512, 512)), - base(base_), mtx(std::make_unique()), workers(4) { @@ -42,9 +41,8 @@ Style::Style(const std::string& data, const std::string& base_, sources = parser.getSources(); layers = parser.getLayers(); - sprite_url = parser.getSprite(); - glyph_url = parser.getGlyphURL(); - glyphStore->setURL(glyph_url); + spriteURL = parser.getSprite(); + glyphStore->setURL(parser.getGlyphURL()); for (const auto& source : sources) { source->setObserver(this); @@ -71,7 +69,7 @@ void Style::update(MapData& data, TexturePool& texturePool) { const float pixelRatio = transform.getPixelRatio(); if (!sprite || !sprite->hasPixelRatio(pixelRatio)) { - sprite = std::make_unique(sprite_url, pixelRatio); + sprite = std::make_unique(spriteURL, pixelRatio); sprite->setObserver(this); spriteAtlas->resize(pixelRatio); diff --git a/src/mbgl/style/style.hpp b/src/mbgl/style/style.hpp index 1c70e352e..c70f019c4 100644 --- a/src/mbgl/style/style.hpp +++ b/src/mbgl/style/style.hpp @@ -90,9 +90,7 @@ private: Observer* observer = nullptr; - std::string base; - std::string sprite_url; - std::string glyph_url; + std::string spriteURL; PropertyTransition defaultTransition; std::unique_ptr mtx; ZoomHistory zoomHistory;