File map2d.hpp
Core API objects - map 2D.
-
template<typename T>
struct TypeTraits<T, typename enable_if_is_base_of<Map2DInterface, T>::type> - #include <map2d.hpp>
Public Static Attributes
-
static constexpr ObjectType EnumType = ObjectType::Map2D
-
static constexpr ObjectType EnumType = ObjectType::Map2D
-
namespace slamcore
Helper conversion methods
slamcore::ImageFormat \(\leftrightarrow\) BytesPerChannel
Get information about the client library
-
class Map2DInterface : public MeasurementPoint<camera_clock>
- #include <map2d.hpp>
Interface to a 2D map.
Public Types
-
using Ptr = std::shared_ptr<Map2DInterface>
-
using CPtr = std::shared_ptr<const Map2DInterface>
-
using MeasurementPointT = MeasurementPoint<camera_clock>
Public Functions
-
virtual ~Map2DInterface() = default
-
virtual bool hasChannel(MapChannelType channel) const = 0
Return whether this map has a channel of the given type.
-
virtual bool hasChannel(MapChannelType channel, std::size_t group) const = 0
Return whether this map has a channel of the given type, of the given group.
-
virtual const MapChannel2DInterface &getChannel(MapChannelType channel) const = 0
Return the channel of the given type, of the group with the highest index.
Note
Throws std::out_of_range if the channel does not exist.
-
virtual const MapChannel2DInterface &getChannel(MapChannelType channel, std::size_t group) const = 0
Return the channel of the given type, of the given group.
Note
Throws std::out_of_range if the channel does not exist.
-
virtual std::size_t numGroups() const = 0
Returns the number of groups in the map.
-
virtual std::size_t numChannels() const = 0
Returns the number of channels in the map
-
virtual std::size_t numChannels(std::size_t group) const = 0
Returns the number of channels in the given group.
-
virtual ScalarT getCellSize() const = 0
Map cell size in metres.
-
virtual std::size_t getWidth() const = 0
Number of cells in the horizontal dimension.
-
virtual std::size_t getHeight() const = 0
Number of cells in the vertical dimension.
-
virtual const Vector<double, 2> &getBoundsMin() const = 0
Min 2D coordinates of the map bounds, in metres.
The map bounds in metres define the rectangular area of 2D space covered by the [0,0]x[w,h] rectangle of integer cell coordinates.
The max 2D coordinates of the map bounds in metres are unambiguously determined as: max_x = min_x + resolution * width max_y = min_y + resolution * height
-
virtual IDT getMapId() const = 0
Map identifier for sub-mapped or tiled implementations.
-
using Ptr = std::shared_ptr<Map2DInterface>
- template<typename T> type >
- #include <map2d.hpp>
Public Static Attributes
-
static constexpr ObjectType EnumType = ObjectType::Map2D
-
static constexpr ObjectType EnumType = ObjectType::Map2D
-
class Map2DInterface : public MeasurementPoint<camera_clock>