Main Page
Namespaces
Classes
Files
File List
File Members
include
tuw_multi_robot_route_to_path
RobotStateObserver.h
Go to the documentation of this file.
1
/* Copyright (c) 2017, TU Wien
2
All rights reserved.
3
4
Redistribution and use in source and binary forms, with or without
5
modification, are permitted provided that the following conditions are met:
6
* Redistributions of source code must retain the above copyright
7
notice, this list of conditions and the following disclaimer.
8
* Redistributions in binary form must reproduce the above copyright
9
notice, this list of conditions and the following disclaimer in the
10
documentation and/or other materials provided with the distribution.
11
* Neither the name of the <organization> nor the
12
names of its contributors may be used to endorse or promote products
13
derived from this software without specific prior written permission.
14
15
THIS SOFTWARE IS PROVIDED BY TU Wien ''AS IS'' AND ANY
16
EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
17
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
18
DISCLAIMED. IN NO EVENT SHALL TU Wien BE LIABLE FOR ANY
19
DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
20
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
21
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
22
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
24
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25
*/
26
27
#ifndef TUW_ROBOT_STATE_OBSERVER_H
28
#define TUW_ROBOT_STATE_OBSERVER_H
29
30
31
#include <memory>
32
#include <vector>
33
#include <eigen3/Eigen/Dense>
34
35
namespace
tuw_multi_robot_route_to_path
36
{
37
struct
PathSegment
38
{
39
Eigen::Vector2d
start
;
40
Eigen::Vector2d
goal
;
41
float
width
;
42
};
43
44
class
RobotStateObserver
45
{
46
//special class-member functions.
47
public
:
RobotStateObserver
();
48
public
:
int
init
(
const
std::vector<PathSegment> &_path);
49
public
:
int
getStep(
const
Eigen::Vector2d &_odom,
bool
&_changed);
50
51
private
:
float
distanceToSegment(
PathSegment
_s, Eigen::Vector2d _p);
52
53
private
: std::vector<PathSegment>
path_
;
54
private
:
int
currentStep
;
55
};
56
57
}
58
59
#endif
60
tuw_multi_robot_route_to_path::PathSegment::start
Eigen::Vector2d start
Definition:
RobotStateObserver.h:39
init
void init(const M_string &remappings)
tuw_multi_robot_route_to_path::PathSegment
Definition:
RobotStateObserver.h:37
tuw_multi_robot_route_to_path::RobotStateObserver
Definition:
RobotStateObserver.h:44
tuw_multi_robot_route_to_path
Definition:
MultiRobotRouteToPathNode.h:40
tuw_multi_robot_route_to_path::RobotStateObserver::path_
std::vector< PathSegment > path_
Definition:
RobotStateObserver.h:53
tuw_multi_robot_route_to_path::PathSegment::width
float width
Definition:
RobotStateObserver.h:41
tuw_multi_robot_route_to_path::PathSegment::goal
Eigen::Vector2d goal
Definition:
RobotStateObserver.h:40
tuw_multi_robot_route_to_path::RobotStateObserver::currentStep
int currentStep
Definition:
RobotStateObserver.h:54
tuw_multi_robot_route_to_path
Author(s): Benjamin Binder
autogenerated on Fri Jun 22 2018 03:07:12