Skip to content
Snippets Groups Projects
Commit 5bc356d8 authored by Joaquim Casals Buñuel's avatar Joaquim Casals Buñuel
Browse files

Added default implementations for loopclosure & tracker

parent e97d7298
No related branches found
No related tags found
No related merge requests found
......@@ -81,6 +81,18 @@ protected:
*/
virtual bool triggerInKeyFrame(FrameBasePtr _keyframe_ptr, const Scalar& _time_tol_other) const override;
/** \brief store key frame
*
* Returns true if the key frame should be stored
*/
virtual bool storeKeyFrame(FrameBasePtr) override;
/** \brief store capture
*
* Returns true if the capture should be stored
*/
virtual bool storeCapture(CaptureBasePtr) override;
/** \brief Called by process(). Tells if computeFeatures() will be called
*/
virtual bool voteComputeFeatures() = 0;
......
......@@ -147,6 +147,18 @@ class ProcessorTracker : public ProcessorBase
*/
virtual bool triggerInKeyFrame(FrameBasePtr _keyframe_ptr, const Scalar& _time_tolerance) const override {return false;}
/** \brief store key frame
*
* Returns true if the key frame should be stored
*/
virtual bool storeKeyFrame(FrameBasePtr) override;
/** \brief store capture
*
* Returns true if the capture should be stored
*/
virtual bool storeCapture(CaptureBasePtr) override;
/** Pre-process incoming Capture
*
* This is called by process() just after assigning incoming_ptr_ to a valid Capture.
......
......@@ -75,6 +75,14 @@ bool ProcessorLoopClosure::triggerInKeyFrame(FrameBasePtr _keyframe_ptr, const S
{
return true;
}
bool ProcessorLoopClosure::storeKeyFrame(FrameBasePtr _frame_ptr)
{
return true;
}
bool ProcessorLoopClosure::storeCapture(CaptureBasePtr _cap_ptr)
{
return true;
}
/**
* In the default implementation, we select the KF with the most recent TimeStamp
......
......@@ -302,10 +302,18 @@ void ProcessorTracker::computeProcessingStep()
}
}
bool ProcessorTracker::triggerInCapture(CaptureBasePtr) const
bool ProcessorTracker::triggerInCapture(CaptureBasePtr _cap_ptr) const
{
return true;
}
bool ProcessorTracker::storeKeyFrame(FrameBasePtr _frame_ptr)
{
return true;
}
bool ProcessorTracker::storeCapture(CaptureBasePtr _cap_ptr)
{
return false;
}
} // namespace wolf
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment