Struct Path
Defined in File Path.h
Struct Documentation
-
struct Path
Public Functions
-
void addState(const Point &p, double ang, double len, PathDirection dir = PathDirection::FORWARD, PathSectionType type = PathSectionType::SWATH, double vel = 1.0)
-
double getTaskTime() const
-
size_t size() const
-
double getDimMinX() const
-
double getDimMinY() const
-
double getDimMaxX() const
-
double getDimMaxY() const
-
void mirrorX()
-
void mirrorY()
-
void setBackwardDir()
-
void setBackwardDir(int i)
-
void setForwardDir()
-
void setForwardDir(int i)
-
void setSwathType()
-
void setSwathType(int i)
-
void setTurnType()
-
void setTurnType(int i)
-
double length(void) const
-
void appendSwath(const Swath &swath, double cruise_speed, PathSectionType type)
-
void appendStraight(const Point &start, const Point &end, double cruise_speed, PathSectionType type)
Append a straight leg from one point to another as a single state.
Legs shorter than 1e-6 are skipped, as they carry no direction.
-
double maxDistanceTo(const LineString &line) const
Furthest any state of this path lies from the given line.
-
LineString toLineString() const
-
std::string serializePath(size_t digit_precision = 6) const
-
void saveToFile(const std::string &file, size_t precision = 6) const
-
void loadFile(const std::string &file)
-
void addState(const Point &p, double ang, double len, PathDirection dir = PathDirection::FORWARD, PathSectionType type = PathSectionType::SWATH, double vel = 1.0)