cartographer_ros
offline_node_main.cc
Go to the documentation of this file.
1
/*
2
* Copyright 2017 The Cartographer Authors
3
*
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
* you may not use this file except in compliance with the License.
6
* You may obtain a copy of the License at
7
*
8
* http://www.apache.org/licenses/LICENSE-2.0
9
*
10
* Unless required by applicable law or agreed to in writing, software
11
* distributed under the License is distributed on an "AS IS" BASIS,
12
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
* See the License for the specific language governing permissions and
14
* limitations under the License.
15
*/
16
17
#include "
cartographer/mapping/map_builder.h
"
18
#include "
cartographer_ros/offline_node.h
"
19
#include "
cartographer_ros/ros_log_sink.h
"
20
#include "gflags/gflags.h"
21
#include "
ros/ros.h
"
22
23
int
main
(
int
argc,
char
** argv) {
24
google::InitGoogleLogging(argv[0]);
25
google::ParseCommandLineFlags(&argc, &argv,
true
);
26
27
::ros::init(argc, argv,
"cartographer_offline_node"
);
28
::ros::start();
29
30
cartographer_ros::ScopedRosLogSink
ros_log_sink;
31
32
const
cartographer_ros::MapBuilderFactory
map_builder_factory =
33
[](const ::cartographer::mapping::proto::MapBuilderOptions&
34
map_builder_options) {
35
return ::cartographer::common::make_unique<
36
::cartographer::mapping::MapBuilder
>(map_builder_options);
37
};
38
39
cartographer_ros::RunOfflineNode
(map_builder_factory);
40
41
::ros::shutdown();
42
}
offline_node.h
cartographer_ros::RunOfflineNode
void RunOfflineNode(const MapBuilderFactory &map_builder_factory)
Definition:
offline_node.cc:79
cartographer_ros::MapBuilderFactory
std::function< std::unique_ptr<::cartographer::mapping::MapBuilderInterface >(const ::cartographer::mapping::proto::MapBuilderOptions &)> MapBuilderFactory
Definition:
offline_node.h:32
map_builder.h
ros_log_sink.h
main
int main(int argc, char **argv)
Definition:
offline_node_main.cc:23
cartographer_ros::ScopedRosLogSink
Definition:
ros_log_sink.h:28
ros.h
cartographer::mapping::MapBuilder
cartographer_ros
Author(s): The Cartographer Authors
autogenerated on Mon Feb 28 2022 22:06:05