7 #include "dynamicvoronoi.h"
12 namespace HybridAStar {
38 double tracePath(
const Node3D* node,
int i = 0, std::vector<Node3D>
path = std::vector<Node3D>(),
double length = 0);
57 if (vec.getX() >= 0 && vec.getX() <
width &&
58 vec.getY() >= 0 && vec.getY() <
height) {
int height
height of the map
Definition: smoother.h:86
DynamicVoronoi voronoi
voronoi diagram describing the topology of the map
Definition: smoother.h:82
A three dimensional node class that is at the heart of the algorithm.
Definition: node3d.h:14
int width
width of the map
Definition: smoother.h:84
This is a collection of constants that are used throughout the project.
float wVoronoi
weight for the voronoi term
Definition: smoother.h:76
Vector2D obstacleTerm(Vector2D xi)
obstacleCost - pushes the path away from obstacles
Definition: smoother.cpp:102
void smoothPath(DynamicVoronoi &voronoi)
This function takes a path consisting of nodes and attempts to iteratively smooth the same using grad...
Definition: smoother.cpp:20
float wCurvature
weight for the curvature term
Definition: smoother.h:78
This class takes a path object and smoothes the nodes of the path.
Definition: smoother.h:18
float wObstacle
weight for the obstacle term
Definition: smoother.h:74
float wSmoothness
weight for the smoothness term
Definition: smoother.h:80
float obsDMax
maximum distance to obstacles that is penalized
Definition: smoother.h:68
float kappaMax
maximum possible curvature of the non-holonomic vehicle
Definition: smoother.h:66
Vector2D smoothnessTerm(Vector2D xim2, Vector2D xim1, Vector2D xi, Vector2D xip1, Vector2D xip2)
smoothnessCost - attempts to spread nodes equidistantly and with the same orientation ...
Definition: smoother.cpp:225
Vector2D curvatureTerm(Vector2D xi0, Vector2D xi1, Vector2D xi2)
curvatureCost - forces a maximum curvature of 1/R along the path ensuring drivability ...
Definition: smoother.cpp:164
A class describing a simple 2D vector.
Definition: vector2d.h:10
std::vector< Node3D > getPath()
returns the path of the smoother object
Definition: smoother.h:41
Vector2D voronoiTerm()
voronoiCost - trade off between path length and closeness to obstaclesg
float vorObsDMax
maximum distance for obstacles to influence the voronoi field
Definition: smoother.h:70
float alpha
falloff rate for the voronoi field
Definition: smoother.h:72
A DynamicVoronoi object computes and updates a distance map and Voronoi diagram.
Definition: dynamicvoronoi.h:14
bool isOnGrid(Vector2D vec)
a boolean test, whether vector is on the grid or not
Definition: smoother.h:56
double tracePath(const Node3D *node, int i=0, std::vector< Node3D > path=std::vector< Node3D >(), double length=0)
Given a node pointer the path to the root node will be traced recursively.
Definition: smoother.cpp:85
std::vector< Node3D > path
path to be smoothed
Definition: smoother.h:88
This is a collection of helper functions that are used throughout the project.