Avoid implicit casts and make code more portable (#716)

This commit is contained in:
tdcosta100
2023-01-23 07:32:53 -03:00
committed by GitHub
parent e47efe3761
commit d5acff3c74
18 changed files with 63 additions and 61 deletions

View File

@@ -78,9 +78,9 @@ int main(int argc, char *argv[]) {
util::RunLoop loop;
HeadlessFrontend frontend({ width, height }, pixelRatio);
HeadlessFrontend frontend({ width, height }, static_cast<float>(pixelRatio));
Map map(frontend, MapObserver::nullObserver(),
MapOptions().withMapMode(MapMode::Static).withSize(frontend.getSize()).withPixelRatio(pixelRatio),
MapOptions().withMapMode(MapMode::Static).withSize(frontend.getSize()).withPixelRatio(static_cast<float>(pixelRatio)),
ResourceOptions().withCachePath(cache_file).withAssetPath(asset_root).withApiKey(apikey).withTileServerOptions(mapTilerConfiguration));
if (style.find("://") == std::string::npos) {