MCPcopy Create free account
hub / github.com/OctoMap/octomap / exportDot

Method exportDot

octomap/src/ScanGraph.cpp:236–250  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

234
235
236 void ScanGraph::exportDot(std::string filename) {
237 std::ofstream outfile (filename.c_str());
238 outfile << "graph ScanGraph" << std::endl;
239 outfile << "{" << std::endl;
240 for (unsigned int i=0; i<edges.size(); i++) {
241 outfile << (edges[i]->first)->id
242 << " -- "
243 << (edges[i]->second)->id
244 << " [label="
245 << std::fixed << std::setprecision(2) << edges[i]->constraint.transLength()
246 << "]" << std::endl;
247 }
248 outfile << "}" << std::endl;
249 outfile.close();
250 }
251
252 ScanNode* ScanGraph::getNodeByID(unsigned int id) {
253 for (unsigned int i = 0; i < nodes.size(); i++) {

Callers

nothing calls this directly

Calls 2

transLengthMethod · 0.80
sizeMethod · 0.45

Tested by

no test coverage detected