Skip to content

Commit

Permalink
Drop duplicate edge checks from karto::Mapper
Browse files Browse the repository at this point in the history
Signed-off-by: Michel Hidalgo <[email protected]>
  • Loading branch information
hidmic committed Mar 25, 2022
1 parent aa9ffa6 commit c119840
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions slam_toolbox/lib/karto_sdk/src/Mapper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1682,18 +1682,6 @@ namespace karto
return false;
}

// see if edge already exists
for (Edge<LocalizedRangeScan> * pOtherEdge : GetEdges()) {
if (pEdge->GetSource() == pOtherEdge->GetSource() &&
pEdge->GetTarget() == pOtherEdge->GetTarget()) {
return false;
}
if (pEdge->GetTarget() == pOtherEdge->GetSource() &&
pEdge->GetSource() == pOtherEdge->GetTarget()) {
return false;
}
}

Graph<LocalizedRangeScan>::AddEdge(pEdge);
return true;
}
Expand Down

0 comments on commit c119840

Please sign in to comment.