diff options
author | Mikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com> | 2019-05-10 22:42:48 +0300 |
---|---|---|
committer | Mikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com> | 2019-05-14 11:29:24 +0300 |
commit | 953ee5e81bee613680468438e3efe4f7c3ff68f6 (patch) | |
tree | 453d9145093448a0222c4b54edce4cf2dac4e81f /src/mbgl/tile | |
parent | 81823e35a68eb87d9433457fe9983d06793a77bf (diff) | |
download | qtlocation-mapboxgl-953ee5e81bee613680468438e3efe4f7c3ff68f6.tar.gz |
[core] Create glyph manager at renderer construction time
Avoid unnecessary glyph manager presence check in `Renderer::Impl::()`.
Diffstat (limited to 'src/mbgl/tile')
-rw-r--r-- | src/mbgl/tile/geometry_tile.cpp | 3 | ||||
-rw-r--r-- | src/mbgl/tile/geometry_tile.hpp | 1 |
2 files changed, 3 insertions, 1 deletions
diff --git a/src/mbgl/tile/geometry_tile.cpp b/src/mbgl/tile/geometry_tile.cpp index d110b2f826..3057712176 100644 --- a/src/mbgl/tile/geometry_tile.cpp +++ b/src/mbgl/tile/geometry_tile.cpp @@ -54,6 +54,7 @@ GeometryTile::GeometryTile(const OverscaledTileID& id_, parameters.mode, parameters.pixelRatio, parameters.debugOptions & MapDebugOptions::Collision), + fileSource(parameters.fileSource), glyphManager(parameters.glyphManager), imageManager(parameters.imageManager), mode(parameters.mode), @@ -156,7 +157,7 @@ void GeometryTile::onGlyphsAvailable(GlyphMap glyphs) { } void GeometryTile::getGlyphs(GlyphDependencies glyphDependencies) { - glyphManager.getGlyphs(*this, std::move(glyphDependencies)); + glyphManager.getGlyphs(*this, std::move(glyphDependencies), fileSource); } void GeometryTile::onImagesAvailable(ImageMap images, ImageMap patterns, ImageVersionMap versionMap, uint64_t imageCorrelationID) { diff --git a/src/mbgl/tile/geometry_tile.hpp b/src/mbgl/tile/geometry_tile.hpp index 975c7aab0e..fadc0aab41 100644 --- a/src/mbgl/tile/geometry_tile.hpp +++ b/src/mbgl/tile/geometry_tile.hpp @@ -108,6 +108,7 @@ private: std::shared_ptr<Mailbox> mailbox; Actor<GeometryTileWorker> worker; + FileSource& fileSource; GlyphManager& glyphManager; ImageManager& imageManager; |