WaypointList Class Reference
#include <WaypointList.h>
Detailed Description
Definition at line 43 of file WaypointList.h.
List of all members.
Public Member Functions |
| WaypointList () |
Static Public Attributes |
static const float | defaultTurnSpeed = float(M_PI/30) |
Adding Waypoints |
|
void | addEgocentricWaypoint (float forward, float left, float angle, bool angleIsRelative, float fwdSpeed, float turnSpeed=-1.f) |
| adds a waypoint to the end of the list, allows you to specify turtle-style instructions
|
void | addOffsetWaypoint (float x, float y, float angle, bool angleIsRelative, float fwdSpeed, float turnSpeed=-1.f) |
| adds a waypoint to the end of the list, allows you to set locations relative to the location of the previous waypoint (or starting position)
|
void | addAbsoluteWaypoint (float x, float y, float angle, bool angleIsRelative, float fwdSpeed, float turnSpeed=-1.f) |
| adds a waypoint to the end of the list, allows you to set locations relative to the world coordinate frame
|
void | addEgocentricArc (float forward, float left, float angle, bool angleIsRelative, float speed, float arc) |
| adds a waypoint to the end of the list, using an arcing path to get there, allows you to specify turtle-style instructions to specify the focus of the arc
|
void | addOffsetArc (float x, float y, float angle, bool angleIsRelative, float speed, float arc) |
| adds a waypoint to the end of the list, using an arcing path to get there, allows you to specify locations relative to previous waypoint to specify the focus of the arc
|
void | addAbsoluteArc (float x, float y, float angle, bool angleIsRelative, float speed, float arc) |
| adds a waypoint to the end of the list, using an arcing path to get there, allows you to specify absolute locations to specify the focus of the arc
|
Waypoint | calcAbsoluteCoords (const_iterator it) |
| assumes start at the origin, applies each waypoint through it and returns result as an absolute position (angle field stores heading)
|
void | fixArc (float arc) |
| assumes the last waypoint is actually center of circle, adjusts it to be the endpoint of following arc radians around that circle instead
|
Constructor & Destructor Documentation
WaypointList::WaypointList |
( |
|
) |
|
Member Function Documentation
adds a waypoint to the end of the list, using an arcing path to get there, allows you to specify absolute locations to specify the focus of the arc
If you would rather specify the ending point and then "bow" the path, try addAbsoluteWaypoint() followed by setting the Waypoint::arc field directly
- Parameters:
-
| x | position along x of the center of the circle of the arc |
| y | position along y of the center of the circle of the arc |
| angle | angle of attack to use on the path |
| angleIsRelative | controls interpretation of angle; true means angle specifies an offset from the bearing of the target waypoint, false means maintain an absolute heading |
| speed | is the speed to move at; millimeters per second |
| arc | is the number of radians the arc fills; arcs near 0 (or multiples of 360) may cause numeric instability |
Definition at line 120 of file WaypointList.h.
void WaypointList::addAbsoluteWaypoint |
( |
float |
x, |
|
|
float |
y, |
|
|
float |
angle, |
|
|
bool |
angleIsRelative, |
|
|
float |
fwdSpeed, |
|
|
float |
turnSpeed = -1.f | |
|
) |
| | |
adds a waypoint to the end of the list, allows you to set locations relative to the world coordinate frame
- Parameters:
-
| x | position along x axis of the waypoint |
| y | position along y axis of the waypoint |
| angle | angle of attack to use on the path |
| angleIsRelative | controls interpretation of angle; true means angle specifies an offset from the bearing of the target waypoint, false means maintain an absolute heading |
| fwdSpeed | is the speed to move at; millimeters per second |
| turnSpeed | is the speed to turn; radians per second |
Definition at line 81 of file WaypointList.h.
Referenced by addAbsoluteArc().
adds a waypoint to the end of the list, using an arcing path to get there, allows you to specify turtle-style instructions to specify the focus of the arc
If you would rather specify the ending point and then "bow" the path, try addEgocentricWaypoint() followed by setting the Waypoint::arc field directly
- Parameters:
-
| forward | distance in front of the center of the circle of the arc |
| left | distance to the left of the center of the circle of the arc |
| angle | angle of attack to use on the path |
| angleIsRelative | controls interpretation of angle; true means angle specifies an offset from the bearing of the target waypoint, false means maintain an absolute heading |
| speed | is the speed to move at; millimeters per second |
| arc | is the number of radians the arc fills; arcs near 0 (or multiples of 360) may cause numeric instability |
Definition at line 94 of file WaypointList.h.
void WaypointList::addEgocentricWaypoint |
( |
float |
forward, |
|
|
float |
left, |
|
|
float |
angle, |
|
|
bool |
angleIsRelative, |
|
|
float |
fwdSpeed, |
|
|
float |
turnSpeed = -1.f | |
|
) |
| | |
adds a waypoint to the end of the list, allows you to specify turtle-style instructions
- Parameters:
-
| forward | distance forward to move (negative to move backward of course) |
| left | distance to the left to move (negative to move right of course) |
| angle | angle of attack to use on the path |
| angleIsRelative | controls interpretation of angle; true means angle specifies an offset from the bearing of the target waypoint, false means maintain an absolute heading |
| speed | is the speed to move at; millimeters per second |
| turnSpeed | is the speed to turn; radians per second |
Definition at line 59 of file WaypointList.h.
Referenced by addEgocentricArc().
adds a waypoint to the end of the list, using an arcing path to get there, allows you to specify locations relative to previous waypoint to specify the focus of the arc
If you would rather specify the ending point and then "bow" the path, try addOffsetWaypoint() followed by setting the Waypoint::arc field directly
- Parameters:
-
| x | distance delta along x of the center of the circle of the arc |
| y | distance delta along y of the center of the circle of the arc |
| angle | angle of attack to use on the path |
| angleIsRelative | controls interpretation of angle; true means angle specifies an offset from the bearing of the target waypoint, false means maintain an absolute heading |
| speed | is the speed to move at; millimeters per second |
| arc | is the number of radians the arc fills; arcs near 0 (or multiples of 360) may cause numeric instability |
Definition at line 107 of file WaypointList.h.
void WaypointList::addOffsetWaypoint |
( |
float |
x, |
|
|
float |
y, |
|
|
float |
angle, |
|
|
bool |
angleIsRelative, |
|
|
float |
fwdSpeed, |
|
|
float |
turnSpeed = -1.f | |
|
) |
| | |
adds a waypoint to the end of the list, allows you to set locations relative to the location of the previous waypoint (or starting position)
- Parameters:
-
| x | distance delta along x axis of the waypoint |
| y | distance delta along y axis of the waypoint |
| angle | angle of attack to use on the path |
| angleIsRelative | controls interpretation of angle; true means angle specifies an offset from the bearing of the target waypoint, false means maintain an absolute heading |
| speed | is the speed to move at; millimeters per second |
| turnSpeed | is the speed to turn; radians per second |
Definition at line 70 of file WaypointList.h.
Referenced by addOffsetArc().
Waypoint WaypointList::calcAbsoluteCoords |
( |
const_iterator |
it |
) |
[protected] |
assumes start at the origin, applies each waypoint through it and returns result as an absolute position (angle field stores heading)
This is replicated from WaypointEngine, so any modifications here should be replicated there...
Definition at line 41 of file WaypointList.cc.
Referenced by fixArc().
void WaypointList::fixArc |
( |
float |
arc |
) |
[protected] |
Member Data Documentation
The documentation for this class was generated from the following files:
|