Fix pbstream_map_publisher (follow #712) (#745)

Applies the proto deserialization changes that
were introduced in PR #712.
master
Michael Grupp 2018-02-28 16:36:50 +01:00 committed by Wally B. Feed
parent 24239beec8
commit 289e4314be
1 changed files with 4 additions and 1 deletions

View File

@ -27,7 +27,7 @@
#include "cartographer/mapping/proto/pose_graph.pb.h" #include "cartographer/mapping/proto/pose_graph.pb.h"
#include "cartographer/mapping/proto/serialization.pb.h" #include "cartographer/mapping/proto/serialization.pb.h"
#include "cartographer/mapping/proto/submap.pb.h" #include "cartographer/mapping/proto/submap.pb.h"
#include "cartographer/mapping/submaps.h" #include "cartographer/mapping/proto/trajectory_builder_options.pb.h"
#include "cartographer_ros/msg_conversion.h" #include "cartographer_ros/msg_conversion.h"
#include "cartographer_ros/node_constants.h" #include "cartographer_ros/node_constants.h"
#include "cartographer_ros/ros_log_sink.h" #include "cartographer_ros/ros_log_sink.h"
@ -53,6 +53,9 @@ void Run(const std::string& pbstream_filename, const std::string& map_topic,
::cartographer::mapping::proto::PoseGraph pose_graph; ::cartographer::mapping::proto::PoseGraph pose_graph;
CHECK(reader.ReadProto(&pose_graph)); CHECK(reader.ReadProto(&pose_graph));
::cartographer::mapping::proto::AllTrajectoryBuilderOptions
all_trajectory_builder_options;
CHECK(reader.ReadProto(&all_trajectory_builder_options));
LOG(INFO) << "Loading submap slices from serialized data."; LOG(INFO) << "Loading submap slices from serialized data.";
std::map<::cartographer::mapping::SubmapId, ::cartographer::io::SubmapSlice> std::map<::cartographer::mapping::SubmapId, ::cartographer::io::SubmapSlice>