serialization.h
Go to the documentation of this file.
00001 /*
00002  * Copyright 2018 The Cartographer Authors
00003  *
00004  * Licensed under the Apache License, Version 2.0 (the "License");
00005  * you may not use this file except in compliance with the License.
00006  * You may obtain a copy of the License at
00007  *
00008  *      http://www.apache.org/licenses/LICENSE-2.0
00009  *
00010  * Unless required by applicable law or agreed to in writing, software
00011  * distributed under the License is distributed on an "AS IS" BASIS,
00012  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013  * See the License for the specific language governing permissions and
00014  * limitations under the License.
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 }  // namespace cloud
00073 }  // namespace cartographer
00074 
00075 #endif  // CARTOGRAPHER_CLOUD_INTERNAL_SENSOR_SERIALIZATION_H


cartographer
Author(s): The Cartographer Authors
autogenerated on Thu May 9 2019 02:27:36