Skip to content

Commit

Permalink
add parent and child in urdf joint (RobotWebTools#262)
Browse files Browse the repository at this point in the history
  • Loading branch information
jihoonl authored Sep 20, 2017
1 parent e0d67d1 commit b47beb5
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 5 deletions.
14 changes: 12 additions & 2 deletions build/roslib.js
Original file line number Diff line number Diff line change
Expand Up @@ -3138,7 +3138,7 @@ function UrdfCylinder(options) {
module.exports = UrdfCylinder;
},{"./UrdfTypes":36}],30:[function(require,module,exports){
/**
* @fileOverview
* @fileOverview
* @author David V. Lu!! [email protected]
*/

Expand All @@ -3152,7 +3152,17 @@ module.exports = UrdfCylinder;
function UrdfJoint(options) {
this.name = options.xml.getAttribute('name');
this.type = options.xml.getAttribute('type');


var parents = options.xml.getElementsByTagName('parent');
if(parents.length > 0) {
this.parent = parents[0].getAttribute('link');
}

var children = options.xml.getElementsByTagName('child');
if(children.length > 0) {
this.child = children[0].getAttribute('link');
}

var limits = options.xml.getElementsByTagName('limit');
if (limits.length > 0) {
this.minval = parseFloat( limits[0].getAttribute('lower') );
Expand Down
Loading

0 comments on commit b47beb5

Please sign in to comment.