cleanup + unused arguments

This commit is contained in:
Konstantin Käfer
2014-04-16 10:55:06 -04:00
parent 74cb7edb5b
commit 797f590cfb
11 changed files with 22 additions and 30 deletions

View File

@@ -347,12 +347,9 @@ bool Map::render() {
// Then, render each source's tiles. TODO: handle more than one
// vector source.
is_baselayer = true;
for (auto &pair : sources) {
Source &source = *pair.second;
source.render(animationTime, is_baselayer);
is_baselayer = source.enabled ? false : (true && is_baselayer);
source.render(animationTime);
}
painter.renderMatte();

View File

@@ -47,7 +47,7 @@ void Source::prepare_render(bool is_baselayer) {
}
}
void Source::render(double animationTime, bool is_baselayer) {
void Source::render(double animationTime) {
if (!enabled) return;
for (const Tile& tile : tiles) {

View File

@@ -9,11 +9,9 @@
using namespace llmr;
const double MAXEXTENT = 20037508.34;
const double D2R = M_PI / 180.0;
const double R2D = 180.0 / M_PI;
const double M2PI = 2 * M_PI;
const double A = 6378137;
Transform::Transform() {

View File

@@ -288,7 +288,7 @@ void FilteredVectorTileLayer::iterator::operator++() {
// tags are packed varints. They should have an even length.
pbf tags_pbf = feature_pbf.message();
while (tags_pbf) {
uint32_t tag_key = tags_pbf.varint();
int32_t tag_key = tags_pbf.varint();
if (tags_pbf) {
uint32_t tag_val = tags_pbf.varint();
// Now check if the tag_key/tag_val pair is included