- Make `cost` function part of RRTBase.
- Make `nn` procedure part of RRTBase.
- Make `nv` procedure part of RRTBase.
+- Make `steer` procedure part of RRTBase.
## 0.3.0 - 2018-12-03
### Added
IF(TMAX)
ADD_DEFINITIONS(-DTMAX=${TMAX})
ENDIF(TMAX)
-IF(ST)
- ADD_DEFINITIONS(-DST=${ST})
-ENDIF(ST)
find_package(OpenMP)
if (OPENMP_FOUND)
- `Kuwata2008` - RRT with changing cost and steering to goal.
- `Karaman2011` - RRT* framework.
- `TMAX` - Specify the upper time bound in seconds.
-- `ST`
- - `st1` - Steer directly to goal.
- - `st2` - Steer with maximum turning radius and direction in mind.
- - `st3` - Reeds and Shepp steer procedure.
- - `st4` - Very basic closed-loop simulator.
+
+Implemented Steering procedures:
+- `st1` - Steer directly to goal.
+- `st2` - Steer with maximum turning radius and direction in mind.
+- `st3` - Reeds and Shepp steer procedure.
+- `st4` - Very basic closed-loop simulator.
To disable *OpenMP*, add `-DCMAKE_DISABLE_FIND_PACKAGE_OpenMP=TRUE` to `cmake`
command or to `build.sh` script.
}
return nvs;
}
+
+std::vector<RRTNode *> RRTBase::steer(RRTNode *init, RRTNode *goal)
+{
+ return st3(init, goal);
+}
#define KUWATA2008_DCOST CO
LaValle1998::LaValle1998(RRTNode *init, RRTNode *goal):
- RRTBase(init, goal),
- steer(ST)
+ RRTBase(init, goal)
{
srand(static_cast<unsigned>(time(0)));
}
}
Kuwata2008::Kuwata2008(RRTNode *init, RRTNode *goal):
- RRTBase(init, goal),
- steer(ST)
+ RRTBase(init, goal)
{
srand(static_cast<unsigned>(time(0)));
}
}
Karaman2011::Karaman2011(RRTNode *init, RRTNode *goal):
- RRTBase(init, goal),
- steer(ST)
+ RRTBase(init, goal)
{
srand(static_cast<unsigned>(time(0)));
}
}
T1::T1(RRTNode *init, RRTNode *goal):
- RRTBase(init, goal),
- steer(ST)
+ RRTBase(init, goal)
{
srand(static_cast<unsigned>(time(0)));
}
Klemm2015::Klemm2015(RRTNode *init, RRTNode *goal):
Karaman2011(init, goal),
- steer(ST),
orig_root_(init),
orig_goal_(goal)
{
#define TMAX 10
#endif
-#ifndef ST
-#define ST st1
-#endif
-
#endif
float cost(RRTNode *init, RRTNode *goal);
RRTNode *nn(RRTNode *rs);
std::vector<RRTNode *> nv(RRTNode *node, float dist);
+ std::vector<RRTNode *> steer(RRTNode *init, RRTNode *goal);
// virtuals - implemented by child classes
virtual bool next() = 0;
public:
//using RRTBase::RRTBase;
LaValle1998(RRTNode *init, RRTNode *goal);
-
- // RRT framework
- std::vector<RRTNode *> (*steer)(
- RRTNode *init,
- RRTNode *goal);
bool next();
};
class Kuwata2008: public RRTBase {
public:
Kuwata2008(RRTNode *init, RRTNode *goal);
-
- // RRT framework
- std::vector<RRTNode *> (*steer)(
- RRTNode *init,
- RRTNode *goal);
bool next();
};
bool rewire(std::vector<RRTNode *> nvs, RRTNode *ns);
public:
Karaman2011(RRTNode *init, RRTNode *goal);
-
- // RRT framework
- std::vector<RRTNode *> (*steer)(
- RRTNode *init,
- RRTNode *goal);
bool next();
};
class T1: public RRTBase {
public:
T1(RRTNode *init, RRTNode *goal);
-
- // RRT framework
- std::vector<RRTNode *> (*steer)(
- RRTNode *init,
- RRTNode *goal);
bool next();
};
class T2: public Karaman2011 {
public:
using Karaman2011::Karaman2011;
-
bool next();
float goal_cost();
};
void swap();
public:
Klemm2015(RRTNode *init, RRTNode *goal);
-
- // RRT framework
- std::vector<RRTNode *> (*steer)(
- RRTNode *init,
- RRTNode *goal);
bool next();
};