mirror of
https://github.com/introlab/rtabmap_ros.git
synced 2026-10-03 16:27:46 +08:00
Using local radius instead of goal radius to trigger the latest pose to reach
This commit is contained in:
+2
-3
@@ -1513,8 +1513,7 @@ void CoreWrapper::process(
|
||||
if(rtabmap_.getPathCurrentGoalId() == rtabmap_.getPath().back().first && rtabmap_.getLocalOptimizedPoses().size())
|
||||
{
|
||||
if(latestNodeWasReached_ ||
|
||||
rtabmap_.getLastLocalizationPose().getDistance(currentMetricGoal_) < rtabmap_.getGoalReachedRadius() ||
|
||||
rtabmap_.getPathTransformToGoal().getNorm() < rtabmap_.getGoalReachedRadius())
|
||||
rtabmap_.getLastLocalizationPose().getDistance(currentMetricGoal_) < rtabmap_.getLocalRadius())
|
||||
{
|
||||
latestNodeWasReached_ = true;
|
||||
currentMetricGoal_ *= rtabmap_.getPathTransformToGoal();
|
||||
@@ -1634,7 +1633,7 @@ void CoreWrapper::goalCommonCallback(
|
||||
// Adjust the target pose relative to last node
|
||||
if(rtabmap_.getPathCurrentGoalId() == rtabmap_.getPath().back().first && rtabmap_.getLocalOptimizedPoses().size())
|
||||
{
|
||||
if(rtabmap_.getLastLocalizationPose().getDistance(currentMetricGoal_) < rtabmap_.getGoalReachedRadius())
|
||||
if(rtabmap_.getLastLocalizationPose().getDistance(currentMetricGoal_) < rtabmap_.getLocalRadius())
|
||||
{
|
||||
latestNodeWasReached_ = true;
|
||||
currentMetricGoal_ *= rtabmap_.getPathTransformToGoal();
|
||||
|
||||
Reference in New Issue
Block a user