MCPcopy Create free account
hub / github.com/PlotJuggler/PlotJuggler / attrDouble

Function attrDouble

pj_scene3D/widgets/src/urdf_parser.cpp:42–49  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

40}
41
42double attrDouble(const QDomElement& el, const QString& name, double fallback) {
43 if (!el.hasAttribute(name)) {
44 return fallback;
45 }
46 bool ok = false;
47 const double v = el.attribute(name).toDouble(&ok);
48 return ok ? v : fallback;
49}
50
51// Read <origin xyz="..." rpy="..."/> into any target with origin_xyz/origin_rpy
52// (LinkGeom or RobotJoint). Missing attributes leave the target's defaults.

Callers 1

parseGeometryFunction · 0.85

Calls 1

toDoubleMethod · 0.80

Tested by

no test coverage detected