CARLA
RoadInfoLaneMaterial.h
Go to the documentation of this file.
1 // Copyright (c) 2017 Computer Vision Center (CVC) at the Universitat Autonoma
2 // de Barcelona (UAB).
3 //
4 // This work is licensed under the terms of the MIT license.
5 // For a copy, see <https://opensource.org/licenses/MIT>.
6 
7 #pragma once
8 
10 #include <string>
11 
12 namespace carla {
13 namespace road {
14 namespace element {
15 
16  class RoadInfoLaneMaterial final : public RoadInfo {
17  public:
18 
20  double s, // start position relative to the position of the preceding
21  // lane section
22  std::string surface,
23  double friction,
24  double roughness)
25  : RoadInfo(s),
26  _surface(std::move(surface)),
27  _friction(friction),
28  _roughness(roughness) {}
29 
30  void AcceptVisitor(RoadInfoVisitor &v) override final {
31  v.Visit(*this);
32  }
33 
34  const std::string &GetSurface() const {
35  return _surface;
36  }
37 
38  double GetFriction() const {
39  return _friction;
40  }
41 
42  double GetRoughness() const {
43  return _roughness;
44  }
45 
46  private:
47 
48  const std::string _surface;
49 
50  const double _friction;
51 
52  const double _roughness;
53  };
54 
55 } // namespace element
56 } // namespace road
57 } // namespace carla
void AcceptVisitor(RoadInfoVisitor &v) override final
This file contains definitions of common data structures used in traffic manager. ...
Definition: Carla.cpp:133
RoadInfoLaneMaterial(double s, std::string surface, double friction, double roughness)