diff --git a/include/core/processor/processor_base.h b/include/core/processor/processor_base.h index 5a46681d09c4feb03ebc98aa0f0cbd6368a325db..8e15ff0ff9ddb659d3391f12b4d63d4b9146eca0 100644 --- a/include/core/processor/processor_base.h +++ b/include/core/processor/processor_base.h @@ -602,8 +602,10 @@ inline void Buffer<T>::removeUpToLower(const TimeStamp& _time_stamp) } template <typename T> -inline bool Buffer<T>::doubleCheckTimeTolerance(const TimeStamp& _time_stamp1, const double& _time_tolerance1, - const TimeStamp& _time_stamp2, const double& _time_tolerance2) +inline bool Buffer<T>::doubleCheckTimeTolerance(const TimeStamp& _time_stamp1, + const double& _time_tolerance1, + const TimeStamp& _time_stamp2, + const double& _time_tolerance2) { double time_diff = std::fabs(_time_stamp1 - _time_stamp2); double time_tol = std::min(_time_tolerance1, _time_tolerance2); @@ -612,8 +614,9 @@ inline bool Buffer<T>::doubleCheckTimeTolerance(const TimeStamp& _time_stamp1, c } template <typename T> -inline bool Buffer<T>::simpleCheckTimeTolerance(const TimeStamp& _time_stamp1, const TimeStamp& _time_stamp2, - const double& _time_tolerance) +inline bool Buffer<T>::simpleCheckTimeTolerance(const TimeStamp& _time_stamp1, + const TimeStamp& _time_stamp2, + const double& _time_tolerance) { double time_diff = std::fabs(_time_stamp1 - _time_stamp2); bool pass = time_diff <= _time_tolerance; diff --git a/src/processor/processor_motion.cpp b/src/processor/processor_motion.cpp index 9445a30ba5feaeb0a4c930c805ae9b3c00a2627a..a236a9022530d6bae0cbcfdb4c53e753de664ff7 100644 --- a/src/processor/processor_motion.cpp +++ b/src/processor/processor_motion.cpp @@ -931,7 +931,10 @@ FrameBasePtr ProcessorMotion::computeProcessingStep() if (keyframe_from_callback) { - if (buffer_frame_.doubleCheckTimeTolerance(keyframe_from_callback->getTimeStamp(), keyframe_from_callback->getTimeTolerance(), incoming_ptr_->getTimeStamp(), params_motion_->time_tolerance)) + if (buffer_frame_.doubleCheckTimeTolerance(keyframe_from_callback->getTimeStamp(), + keyframe_from_callback->getTimeTolerance(), + incoming_ptr_->getTimeStamp(), + params_motion_->time_tolerance)) { WOLF_DEBUG("First time with a KF compatible.") processing_step_ = FIRST_TIME_WITH_KF_ON_INCOMING; @@ -965,7 +968,10 @@ FrameBasePtr ProcessorMotion::computeProcessingStep() if (keyframe_from_callback) { - if (buffer_frame_.doubleCheckTimeTolerance(keyframe_from_callback->getTimeStamp(), keyframe_from_callback->getTimeTolerance(), origin_ptr_->getTimeStamp(), params_motion_->time_tolerance)) + if (buffer_frame_.doubleCheckTimeTolerance(keyframe_from_callback->getTimeStamp(), + keyframe_from_callback->getTimeTolerance(), + origin_ptr_->getTimeStamp(), + params_motion_->time_tolerance)) processing_step_ = RUNNING_WITH_KF_ON_ORIGIN;