add style object
This commit is contained in:
@@ -14,6 +14,7 @@ Map::Map(Settings& settings)
|
||||
: settings(settings),
|
||||
transform(),
|
||||
painter(transform, settings),
|
||||
style(),
|
||||
min_zoom(0),
|
||||
max_zoom(14) {
|
||||
}
|
||||
@@ -25,6 +26,11 @@ void Map::setup() {
|
||||
painter.setup();
|
||||
}
|
||||
|
||||
void Map::loadStyle(const uint8_t *data, uint32_t bytes) {
|
||||
style.load(pbf(data, bytes));
|
||||
update();
|
||||
}
|
||||
|
||||
void Map::loadSettings() {
|
||||
transform.setAngle(settings.angle);
|
||||
transform.setScale(settings.scale);
|
||||
|
||||
Reference in New Issue
Block a user