Skip to content
Snippets Groups Projects

Resolve "ProcessorLoopClosureBase class"

Merged Joan Vallvé Navarro requested to merge 220-processor-loop-closure-base into devel
1 file
+ 10
2
Compare changes
  • Side-by-side
  • Inline
@@ -34,8 +34,16 @@ void ProcessorLoopClosureBase::process(CaptureBasePtr _incoming_ptr)
{
CaptureBasePtr capture_1 = pairKC.second;
CaptureBasePtr capture_2 = findLoopCandidate(capture_1);
if (capture_2==nullptr) return;
if (validateLoop(capture_1, capture_2)==false) return;
if (validateLoop(capture_1, capture_2)==false) return;
if (capture_2==nullptr) return;
if (capture_1->getFrame() == nullptr || capture_2->getFrame() == nullptr) {
WOLF_WARN("ProcessorLoopClosureBase : tried to close a loop with captures linked to no KF");
return;
};
if (capture_1->getFrame() == capture_2->getFrame()) {
WOLF_WARN("ProcessorLoopClosureBase : findLoopCandidate() returned two captures of the same frame");
return;
};
createFactors(capture_1, capture_2);
};
};
Loading