本文整理汇总了C++中base::PlannerData::markGoalState方法的典型用法代码示例。如果您正苦于以下问题:C++ PlannerData::markGoalState方法的具体用法?C++ PlannerData::markGoalState怎么用?C++ PlannerData::markGoalState使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类base::PlannerData
的用法示例。
在下文中一共展示了PlannerData::markGoalState方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: pd
void ompl::geometric::CForest::getPlannerData(base::PlannerData &data) const
{
Planner::getPlannerData(data);
for (std::size_t i = 0; i < planners_.size(); ++i)
{
base::PlannerData pd(si_);
planners_[i]->getPlannerData(pd);
for (unsigned int j = 0; j < pd.numVertices(); ++j)
{
base::PlannerDataVertex &v = pd.getVertex(j);
v.setTag(i);
std::vector<unsigned int> edgeList;
unsigned int numEdges = pd.getIncomingEdges(j, edgeList);
for (unsigned int k = 0; k < numEdges; ++k)
{
base::Cost edgeWeight;
base::PlannerDataVertex &w = pd.getVertex(edgeList[k]);
w.setTag(i);
pd.getEdgeWeight(j, k, &edgeWeight);
data.addEdge(v, w, pd.getEdge(j, k), edgeWeight);
}
}
for (unsigned int j = 0; j < pd.numGoalVertices(); ++j)
data.markGoalState(pd.getGoalVertex(j).getState());
for (unsigned int j = 0; j < pd.numStartVertices(); ++j)
data.markStartState(pd.getStartVertex(j).getState());
}
}