diff options
Diffstat (limited to 'bin')
-rw-r--r-- | bin/offline.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/bin/offline.cpp b/bin/offline.cpp index 398f8427ee..e5ce1f75fe 100644 --- a/bin/offline.cpp +++ b/bin/offline.cpp @@ -101,6 +101,7 @@ int main(int argc, char *argv[]) { args::ValueFlag<double> minZoomValue(argumentParser, "number", "Min zoom level", {"minZoom"}); args::ValueFlag<double> maxZoomValue(argumentParser, "number", "Max zoom level", {"maxZoom"}); args::ValueFlag<double> pixelRatioValue(argumentParser, "number", "Pixel ratio", {"pixelRatio"}); + args::ValueFlag<bool> includeIdeographsValue(argumentParser, "boolean", "Include CJK glyphs", {"includeIdeographs"}); try { argumentParser.ParseCLI(argc, argv); @@ -127,6 +128,7 @@ int main(int argc, char *argv[]) { const double minZoom = minZoomValue ? args::get(minZoomValue) : 0.0; const double maxZoom = maxZoomValue ? args::get(maxZoomValue) : 15.0; const double pixelRatio = pixelRatioValue ? args::get(pixelRatioValue) : 1.0; + const bool includeIdeographs = includeIdeographsValue ? args::get(includeIdeographsValue) : false; const std::string output = outputValue ? args::get(outputValue) : "offline.db"; using namespace mbgl; @@ -136,7 +138,7 @@ int main(int argc, char *argv[]) { try { std::string json = readFile(geometryValue.Get()); auto geometry = parseGeometry(json); - return OfflineRegionDefinition{ OfflineGeometryRegionDefinition(style, geometry, minZoom, maxZoom, pixelRatio) }; + return OfflineRegionDefinition{ OfflineGeometryRegionDefinition(style, geometry, minZoom, maxZoom, pixelRatio, includeIdeographs) }; } catch(const std::runtime_error& e) { std::cerr << "Could not parse geojson file " << geometryValue.Get() << ": " << e.what() << std::endl; exit(1); @@ -148,7 +150,7 @@ int main(int argc, char *argv[]) { const double south = southValue ? args::get(southValue) : 38.1; const double east = eastValue ? args::get(eastValue) : -121.7; LatLngBounds boundingBox = LatLngBounds::hull(LatLng(north, west), LatLng(south, east)); - return OfflineRegionDefinition{ OfflineTilePyramidRegionDefinition(style, boundingBox, minZoom, maxZoom, pixelRatio) }; + return OfflineRegionDefinition{ OfflineTilePyramidRegionDefinition(style, boundingBox, minZoom, maxZoom, pixelRatio, includeIdeographs) }; } }(); |