Skip to content

Commit

Permalink
Fix EPT reader polygon/bounds interaction to require both to pass, ma…
Browse files Browse the repository at this point in the history
…tching 2.2 behavior.
  • Loading branch information
connormanning committed Jul 17, 2021
1 parent ec1bb5c commit 41f196e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions io/EptReader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -580,7 +580,7 @@ bool EptReader::passesSpatialFilter(const BOX3D& tileBounds) const
// at the same time, it seems to get corrupted. There may be other instances
// that need to be locked.
std::lock_guard<std::mutex> lock(m_p->mutex);
return boxOverlaps() || polysOverlap();
return boxOverlaps() && polysOverlap();
}


Expand Down Expand Up @@ -701,7 +701,7 @@ bool EptReader::processPoint(PointRef& dst, const TileContents& tile)

// If there is a spatial filter, make sure it passes.
if (hasSpatialFilter())
if (!passesBoundsFilter(x, y, z) && !passesPolyFilter(x, y, z))
if (!passesBoundsFilter(x, y, z) || !passesPolyFilter(x, y, z))
return false;

for (auto& el : m_p->info->dims())
Expand Down

0 comments on commit 41f196e

Please sign in to comment.