fix a bug in rawtilereader causing less map layers to be read

This commit is contained in:
Micah
2020-08-06 16:58:40 -04:00
parent 17702c2129
commit 7ecf77dc38

View File

@@ -564,7 +564,7 @@ void RawTileDataReader::initialize() {
const int numOverviews = _dataset->GetRasterBand(1)->GetOverviewCount();
_maxChunkLevel = static_cast<int>(-tileLevelDifference);
if (numOverviews > 0) {
_maxChunkLevel += numOverviews - 1;
_maxChunkLevel += numOverviews;
}
_maxChunkLevel = std::max(_maxChunkLevel, 2);
}