pass Tile::ID by const ref
This commit is contained in:
@@ -16,7 +16,7 @@ class RasterTileData : public TileData {
|
||||
friend class TileParser;
|
||||
|
||||
public:
|
||||
RasterTileData(Tile::ID id, Map &map, const util::ptr<SourceInfo> &source);
|
||||
RasterTileData(Tile::ID const& id, Map &map, const util::ptr<SourceInfo> &source);
|
||||
~RasterTileData();
|
||||
|
||||
virtual void parse();
|
||||
|
||||
@@ -40,7 +40,7 @@ public:
|
||||
};
|
||||
|
||||
public:
|
||||
TileData(Tile::ID id, Map &map, const util::ptr<SourceInfo> &source);
|
||||
TileData(Tile::ID const& id, Map &map, const util::ptr<SourceInfo> &source);
|
||||
~TileData();
|
||||
|
||||
void request();
|
||||
|
||||
@@ -26,7 +26,7 @@ class VectorTileData : public TileData {
|
||||
friend class TileParser;
|
||||
|
||||
public:
|
||||
VectorTileData(Tile::ID id, Map &map, const util::ptr<SourceInfo> &source);
|
||||
VectorTileData(Tile::ID const& id, Map &map, const util::ptr<SourceInfo> &source);
|
||||
~VectorTileData();
|
||||
virtual void parse();
|
||||
virtual void render(Painter &painter, util::ptr<StyleLayer> layer_desc, const mat4 &matrix);
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
using namespace mbgl;
|
||||
|
||||
|
||||
RasterTileData::RasterTileData(Tile::ID id_, Map &map_, const util::ptr<SourceInfo> &source_)
|
||||
RasterTileData::RasterTileData(Tile::ID const& id_, Map &map_, const util::ptr<SourceInfo> &source_)
|
||||
: TileData(id_, map_, source_),
|
||||
bucket(map.getTexturepool(), properties) {
|
||||
}
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
using namespace mbgl;
|
||||
|
||||
TileData::TileData(Tile::ID id_, Map &map_, const util::ptr<SourceInfo> &source_)
|
||||
TileData::TileData(Tile::ID const& id_, Map &map_, const util::ptr<SourceInfo> &source_)
|
||||
: id(id_),
|
||||
state(State::initial),
|
||||
map(map_),
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
|
||||
using namespace mbgl;
|
||||
|
||||
VectorTileData::VectorTileData(Tile::ID id_, Map &map_, const util::ptr<SourceInfo> &source_)
|
||||
VectorTileData::VectorTileData(Tile::ID const& id_, Map &map_, const util::ptr<SourceInfo> &source_)
|
||||
: TileData(id_, map_, source_),
|
||||
depth(id.z >= source->max_zoom ? map.getMaxZoom() - id.z : 1) {
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user