From dc1acdd81c84c981355b8617bae2e2dd4ab20c0e Mon Sep 17 00:00:00 2001 From: Joan Sola <jsola@iri.upc.edu> Date: Thu, 22 Feb 2018 17:22:46 +0100 Subject: [PATCH] Fix warnings and error msgs --- src/processor_tracker_feature.cpp | 18 ++++-------------- src/processor_tracker_feature.h | 6 ++---- 2 files changed, 6 insertions(+), 18 deletions(-) diff --git a/src/processor_tracker_feature.cpp b/src/processor_tracker_feature.cpp index 88084407f..21782ed12 100644 --- a/src/processor_tracker_feature.cpp +++ b/src/processor_tracker_feature.cpp @@ -112,31 +112,21 @@ void ProcessorTrackerFeature::reset() unsigned int ProcessorTrackerFeature::processNew(const unsigned int& _max_new_features) { - // std::cout << "ProcessorTrackerFeature::processNew()" << std::endl; - /* Rationale: A keyFrame will be created using the last Capture. - * First, we create the constraints from the existing Features in last, - * because the ones that we want to detect later on will not be constrained by anyone yet. - * Then, we work on this last Capture to detect new Features, + * First, we work on the last Capture to detect new Features, * When done, we need to track these new Features to the incoming Capture. * At the end, all new Features are appended to the lists of known Features in * the last and incoming Captures. */ - // Populate the last Capture with new Features. The result is in new_features_last_. unsigned int n = detectNewFeatures(_max_new_features); - // std::cout << "detected " << n << " new features!" << std::endl; - // Track new features from last to incoming. This will append new correspondences to matches_last_incoming - if (incoming_ptr_ != last_ptr_ && incoming_ptr_ != nullptr) // we do not do it the first time. - { - trackFeatures(new_features_last_, new_features_incoming_, matches_last_from_incoming_); + trackFeatures(new_features_last_, new_features_incoming_, matches_last_from_incoming_); - // Append all new Features to the incoming Captures' list of Features - incoming_ptr_->addFeatureList(new_features_incoming_); - } + // Append all new Features to the incoming Captures' list of Features + incoming_ptr_->addFeatureList(new_features_incoming_); // Append all new Features to the last Captures' list of Features last_ptr_->addFeatureList(new_features_last_); diff --git a/src/processor_tracker_feature.h b/src/processor_tracker_feature.h index 7e1d625a5..27f03ee7f 100644 --- a/src/processor_tracker_feature.h +++ b/src/processor_tracker_feature.h @@ -137,14 +137,12 @@ class ProcessorTrackerFeature : public ProcessorTracker virtual unsigned int processNew(const unsigned int& _max_features); /** \brief Detect new Features - * \param _capture_ptr Capture for feature detection. Defaults to incoming_ptr_. - * \param _new_features_list The list of detected Features. Defaults to member new_features_list_. + * \param _max_features maximum number of features detected * \return The number of detected Features. * * This function detects Features that do not correspond to known Features/Landmarks in the system. * - * The function sets the member new_features_list_, the list of newly detected features, - * to be used for landmark initialization. + * The function sets the member new_features_last_, the list of newly detected features. */ virtual unsigned int detectNewFeatures(const unsigned int& _max_features) = 0; -- GitLab