Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use CBOR by default for OccupancyGrid #247

Merged
merged 4 commits into from
Feb 2, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion src/navigation/OccupancyGridClient.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
* * topic (optional) - the map topic to listen to
* * continuous (optional) - if the map should be continuously loaded (e.g., for SLAM)
* * tfClient (optional) - the TF client handle to use for a scene node
* * compression (optional) - message compression (default: 'cbor')
* * rootObject (optional) - the root object to add this marker to
* * offsetPose (optional) - offset pose of the grid visualization, e.g. for z-offset (ROSLIB.Pose type)
* * color (optional) - color of the visualized grid
Expand All @@ -26,6 +27,7 @@ ROS3D.OccupancyGridClient = function(options) {
options = options || {};
this.ros = options.ros;
this.topicName = options.topic || '/map';
this.compression = options.compression || 'cbor';
this.continuous = options.continuous;
this.tfClient = options.tfClient;
this.rootObject = options.rootObject || new THREE.Object3D();
Expand Down Expand Up @@ -56,7 +58,7 @@ ROS3D.OccupancyGridClient.prototype.subscribe = function(){
ros : this.ros,
name : this.topicName,
messageType : 'nav_msgs/OccupancyGrid',
compression : 'png'
compression : this.compression
});
this.rosTopic.subscribe(this.processMessage.bind(this));
};
Expand Down