Fix compile warnings and add a clarifying comment. (#105)
parent
be7ce01463
commit
9ac88abcfc
|
@ -333,7 +333,6 @@ bool Node::HandleSubmapQuery(
|
||||||
response.height = response_proto.height();
|
response.height = response_proto.height();
|
||||||
response.resolution = response_proto.resolution();
|
response.resolution = response_proto.resolution();
|
||||||
|
|
||||||
auto pose = carto::transform::ToRigid3(response_proto.slice_pose());
|
|
||||||
response.slice_pose.position.x =
|
response.slice_pose.position.x =
|
||||||
response_proto.slice_pose().translation().x();
|
response_proto.slice_pose().translation().x();
|
||||||
response.slice_pose.position.y =
|
response.slice_pose.position.y =
|
||||||
|
|
|
@ -91,7 +91,7 @@ void SubmapsDisplay::reset() {
|
||||||
void SubmapsDisplay::processMessage(
|
void SubmapsDisplay::processMessage(
|
||||||
const ::cartographer_ros_msgs::SubmapList::ConstPtr& msg) {
|
const ::cartographer_ros_msgs::SubmapList::ConstPtr& msg) {
|
||||||
::cartographer::common::MutexLocker locker(&mutex_);
|
::cartographer::common::MutexLocker locker(&mutex_);
|
||||||
for (int trajectory_id = 0; trajectory_id < msg->trajectory.size();
|
for (size_t trajectory_id = 0; trajectory_id < msg->trajectory.size();
|
||||||
++trajectory_id) {
|
++trajectory_id) {
|
||||||
if (trajectory_id >= trajectories_.size()) {
|
if (trajectory_id >= trajectories_.size()) {
|
||||||
trajectories_.emplace_back();
|
trajectories_.emplace_back();
|
||||||
|
@ -99,7 +99,7 @@ void SubmapsDisplay::processMessage(
|
||||||
auto& trajectory = trajectories_[trajectory_id];
|
auto& trajectory = trajectories_[trajectory_id];
|
||||||
const std::vector<::cartographer_ros_msgs::SubmapEntry>& submap_entries =
|
const std::vector<::cartographer_ros_msgs::SubmapEntry>& submap_entries =
|
||||||
msg->trajectory[trajectory_id].submap;
|
msg->trajectory[trajectory_id].submap;
|
||||||
for (int submap_id = 0; submap_id < submap_entries.size(); ++submap_id) {
|
for (size_t submap_id = 0; submap_id < submap_entries.size(); ++submap_id) {
|
||||||
if (submap_id >= trajectory.size()) {
|
if (submap_id >= trajectory.size()) {
|
||||||
trajectory.push_back(
|
trajectory.push_back(
|
||||||
::cartographer::common::make_unique<DrawableSubmap>(
|
::cartographer::common::make_unique<DrawableSubmap>(
|
||||||
|
|
|
@ -53,6 +53,7 @@ class SubmapsDisplay
|
||||||
private:
|
private:
|
||||||
void CreateClient();
|
void CreateClient();
|
||||||
|
|
||||||
|
// These are called by RViz and therefore do not adhere to the style guide.
|
||||||
void onInitialize() override;
|
void onInitialize() override;
|
||||||
void reset() override;
|
void reset() override;
|
||||||
void processMessage(
|
void processMessage(
|
||||||
|
|
Loading…
Reference in New Issue