Gazebo Sensors

API Reference

8.2.1
EnvironmentalData.hh
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2022 Open Source Robotics Foundation
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 #ifndef GZ_SENSORS_ENVIRONMENTAL_DATA_HH_
18 #define GZ_SENSORS_ENVIRONMENTAL_DATA_HH_
19 
20 #include <memory>
21 #include <string>
22 
23 #include <gz/common/DataFrame.hh>
24 #include <gz/math/SphericalCoordinates.hh>
25 #include <gz/math/TimeVaryingVolumetricGrid.hh>
26 
27 #include <gz/sensors/config.hh>
28 #include <gz/sensors/Export.hh>
29 
30 namespace gz
31 {
32  namespace sensors
33  {
34  // Inline bracket to help doxygen filtering.
35  inline namespace GZ_SENSORS_VERSION_NAMESPACE
36  {
40  struct GZ_SENSORS_VISIBLE EnvironmentalData
41  {
42  using T = math::InMemoryTimeVaryingVolumetricGrid<double>;
43  using FrameT = common::DataFrame<std::string, T>;
44  using ReferenceT = math::SphericalCoordinates::CoordinateType;
45 
47  enum class ReferenceUnits {
48  RADIANS = 0,
49  DEGREES
50  };
51 
59  MakeShared(FrameT _frame, ReferenceT _reference,
60  ReferenceUnits _units = ReferenceUnits::RADIANS,
61  bool _ignoreTimeStep = false);
62 
65 
68 
71 
73  bool staticTime;
74  };
75  } // namespace GZ_SENSORS_VERSION_NAMESPACE
76  } // namespace sensors
77 } // namespace gz
78 
79 #endif