Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef CARTOGRAPHER_CLOUD_INTERNAL_SENSOR_SERIALIZATION_H
00018 #define CARTOGRAPHER_CLOUD_INTERNAL_SENSOR_SERIALIZATION_H
00019
00020 #include "cartographer/cloud/proto/map_builder_service.pb.h"
00021 #include "cartographer/mapping/local_slam_result_data.h"
00022 #include "cartographer/mapping/trajectory_builder_interface.h"
00023 #include "cartographer/sensor/fixed_frame_pose_data.h"
00024 #include "cartographer/sensor/imu_data.h"
00025 #include "cartographer/sensor/landmark_data.h"
00026 #include "cartographer/sensor/odometry_data.h"
00027 #include "cartographer/sensor/timed_point_cloud_data.h"
00028
00029 namespace cartographer {
00030 namespace cloud {
00031
00032 void CreateSensorMetadata(const std::string& sensor_id, int trajectory_id,
00033 const std::string& client_id,
00034 proto::SensorMetadata* proto);
00035
00036 void CreateAddFixedFramePoseDataRequest(
00037 const std::string& sensor_id, int trajectory_id,
00038 const std::string& client_id,
00039 const sensor::proto::FixedFramePoseData& fixed_frame_pose_data,
00040 proto::AddFixedFramePoseDataRequest* proto);
00041 void CreateAddImuDataRequest(const std::string& sensor_id, int trajectory_id,
00042 const std::string& client_id,
00043 const sensor::proto::ImuData& imu_data,
00044 proto::AddImuDataRequest* proto);
00045 void CreateAddOdometryDataRequest(
00046 const std::string& sensor_id, int trajectory_id,
00047 const std::string& client_id,
00048 const sensor::proto::OdometryData& odometry_data,
00049 proto::AddOdometryDataRequest* proto);
00050 void CreateAddRangeFinderDataRequest(
00051 const std::string& sensor_id, int trajectory_id,
00052 const std::string& client_id,
00053 const sensor::proto::TimedPointCloudData& timed_point_cloud_data,
00054 proto::AddRangefinderDataRequest* proto);
00055 void CreateAddLandmarkDataRequest(
00056 const std::string& sensor_id, int trajectory_id,
00057 const std::string& client_id,
00058 const sensor::proto::LandmarkData& landmark_data,
00059 proto::AddLandmarkDataRequest* proto);
00060 void CreateSensorDataForLocalSlamResult(
00061 const std::string& sensor_id, int trajectory_id,
00062 const std::string& client_id, common::Time time, int starting_submap_index,
00063 const mapping::TrajectoryBuilderInterface::InsertionResult&
00064 insertion_result,
00065 proto::SensorData* proto);
00066
00067 proto::SensorId ToProto(
00068 const mapping::TrajectoryBuilderInterface::SensorId& sensor_id);
00069 mapping::TrajectoryBuilderInterface::SensorId FromProto(
00070 const proto::SensorId& proto);
00071
00072 }
00073 }
00074
00075 #endif // CARTOGRAPHER_CLOUD_INTERNAL_SENSOR_SERIALIZATION_H