Main MRPT website > C++ reference for MRPT 1.9.9
List of all members | Public Member Functions | Public Attributes | Static Public Attributes
mrpt::nav::TWaypoint Struct Reference

Detailed Description

A single waypoint within TWaypointSequence.

Definition at line 23 of file TWaypoint.h.

#include <mrpt/nav/reactive/TWaypoint.h>

Inheritance diagram for mrpt::nav::TWaypoint:
Inheritance graph

Public Member Functions

bool isValid () const
 Check whether all the minimum mandatory fields have been filled by the user. More...
 
 TWaypoint ()
 Ctor with default values. More...
 
 TWaypoint (double target_x, double target_y, double allowed_distance, bool allow_skip=true, double target_heading_=INVALID_NUM)
 
std::string getAsText () const
 get in human-readable format More...
 

Public Attributes

mrpt::math::TPoint2D target
 [Must be set by the user] Coordinates of desired target location (world/global coordinates). More...
 
double target_heading
 [Default=any heading] Optionally, set to the desired orientation [radians] of the robot at this waypoint. More...
 
std::string target_frame_id
 (Default="map") Frame ID in which target is given. More...
 
double allowed_distance
 [Must be set by the user] How close should the robot get to this waypoint for it to be considered reached. More...
 
bool allow_skip
 [Default=true] Whether it is allowed to the navigator to proceed to a more advanced waypoint in the sequence if it determines that it is easier to skip this one (e.g. More...
 

Static Public Attributes

static const int INVALID_NUM { -100000 }
 The default value of fields (used to detect non-set values) More...
 

Constructor & Destructor Documentation

◆ TWaypoint() [1/2]

TWaypoint::TWaypoint ( )

Ctor with default values.

Definition at line 22 of file TWaypoint.cpp.

◆ TWaypoint() [2/2]

TWaypoint::TWaypoint ( double  target_x,
double  target_y,
double  allowed_distance,
bool  allow_skip = true,
double  target_heading_ = INVALID_NUM 
)

Definition at line 31 of file TWaypoint.cpp.

Member Function Documentation

◆ getAsText()

std::string TWaypoint::getAsText ( ) const

get in human-readable format

Definition at line 48 of file TWaypoint.cpp.

References allow_skip, allowed_distance, mrpt::mrpt::format(), INVALID_NUM, mrpt::mrpt::utils::RAD2DEG(), target, target_heading, mrpt::math::TPoint2D::x, and mrpt::math::TPoint2D::y.

Referenced by mrpt::nav::TWaypointStatus::getAsText().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ isValid()

bool TWaypoint::isValid ( ) const

Check whether all the minimum mandatory fields have been filled by the user.

Definition at line 42 of file TWaypoint.cpp.

References allowed_distance, INVALID_NUM, target, mrpt::math::TPoint2D::x, and mrpt::math::TPoint2D::y.

Member Data Documentation

◆ allow_skip

bool mrpt::nav::TWaypoint::allow_skip

[Default=true] Whether it is allowed to the navigator to proceed to a more advanced waypoint in the sequence if it determines that it is easier to skip this one (e.g.

it seems blocked by dynamic obstacles). This value is ignored for the last waypoint in a sequence, since it is always considered to be the ultimate goal and hence not subject to be skipped.

Definition at line 52 of file TWaypoint.h.

Referenced by getAsText().

◆ allowed_distance

double mrpt::nav::TWaypoint::allowed_distance

[Must be set by the user] How close should the robot get to this waypoint for it to be considered reached.

Definition at line 42 of file TWaypoint.h.

Referenced by getAsText(), isValid(), and mrpt::nav::CWaypointsNavigator::waypoints_navigationStep().

◆ INVALID_NUM

const int mrpt::nav::TWaypoint::INVALID_NUM { -100000 }
static

◆ target

mrpt::math::TPoint2D mrpt::nav::TWaypoint::target

[Must be set by the user] Coordinates of desired target location (world/global coordinates).

See also
target_heading

Definition at line 28 of file TWaypoint.h.

Referenced by getAsText(), isValid(), and mrpt::nav::CWaypointsNavigator::waypoints_navigationStep().

◆ target_frame_id

std::string mrpt::nav::TWaypoint::target_frame_id

(Default="map") Frame ID in which target is given.

Optional, use only for submapping applications.

Definition at line 38 of file TWaypoint.h.

Referenced by mrpt::nav::CWaypointsNavigator::waypoints_navigationStep().

◆ target_heading

double mrpt::nav::TWaypoint::target_heading

[Default=any heading] Optionally, set to the desired orientation [radians] of the robot at this waypoint.

Some navigator implementations may ignore this preferred heading anyway, read the docs of each implementation to find it out.

Definition at line 34 of file TWaypoint.h.

Referenced by getAsText(), and mrpt::nav::CWaypointsNavigator::waypoints_navigationStep().




Page generated by Doxygen 1.8.14 for MRPT 1.9.9 Git: ae4571287 Thu Nov 23 00:06:53 2017 +0100 at dom oct 27 23:51:55 CET 2019