Public Member Functions | Static Public Attributes | Private Attributes | List of all members
tuw::GridMap< T > Class Template Reference

#include <grid_map.h>

Inheritance diagram for tuw::GridMap< T >:
Inheritance graph
[legend]

Public Member Functions

void circle (const Point2D &p, double radius, int8_t value, int thickness=1, int lineType=CV_AA)
 
int cols () const
 
void erode (double distance, const GridMap &src=GridMap())
 
T & get (const Point2D &_world_coordinates)
 
const T & get (const Point2D &_world_coordinates) const
 
const T & getThresholdFree ()
 
const T & getThresholdOccupied ()
 
const T & getThresholdUnknown ()
 
T & grid (int row, int col)
 
const T & grid (int row, int col) const
 
 GridMap ()
 
 GridMap (const GridMap &)=default
 
 GridMap (GridMap &&)=default
 
template<typename MapMetaData , class ARRAY >
void init (const MapMetaData &metadata, ARRAY *data)
 
template<typename MapMetaData , class ARRAY >
void init (MapMetaData &metadata, ARRAY &data)
 
template<typename MapMetaData >
void init (const MapMetaData &metadata, const T &data, bool copy=false)
 
bool isFree (const Point2D &_world_coordinates) const
 
bool isOccupyied (const Point2D &_world_coordinates) const
 
const cv::Mat_< T > & mat () const
 
T & operator() (double x, double y)
 
const T & operator() (double x, double y) const
 
T & operator() (const Point2D &_world_coordinates)
 
const T & operator() (const Point2D &_world_coordinates) const
 
GridMapoperator= (const GridMap &)=default
 
GridMapoperator= (GridMap &&)=default
 
int rows () const
 
void setThresholdFree (const T &threshold)
 
void setThresholdOccupied (const T &threshold)
 
void setThresholdUnknown (const T &threshold)
 
virtual ~GridMap ()=default
 
- Public Member Functions inherited from tuw::WorldScopedMaps
template<typename T >
void circle (T &map, const Point2D &p, int radius, const cv::Scalar &color, int thickness=1, int lineType=CV_AA) const
 
template<typename T >
cv::Scalar_< T > get (cv::Mat_< T > &map, const Point2D &p) const
 
int height () const
 
std::string infoHeader () const
 
void init (int width_pixel, int height_pixel, double min_y, double max_y, double min_x, double max_x, double rotation=0)
 
template<typename T >
void init (const T &metadata)
 
bool initialized ()
 
template<typename T >
void line (T &map, const Point2D &p0, const Point2D &p1, const cv::Scalar &color, int thickness=1, int lineType=CV_AA) const
 
Point2D m2w (const Point2D &src) const
 
Point2D m2w (double x, double y) const
 
Point2Dm2w (const Point2D &src, Point2D &des) const
 
double max_x () const
 
double max_y () const
 
double min_x () const
 
double min_y () const
 
const cv::Matx33d & Mm2w () const
 
const cv::Matx33d & Mw2m () const
 
WorldScopedMapsoperator= (const WorldScopedMaps &)=default
 
WorldScopedMapsoperator= (WorldScopedMaps &&)=default
 
double scale_w2m (double v) const
 
double scale_x () const
 
double scale_y () const
 
Point2D w2m (const Point2D &src) const
 
Point2D w2m (double x, double y) const
 
Point2Dw2m (const Point2D &src, Point2D &des) const
 
int width () const
 
 WorldScopedMaps ()
 
 WorldScopedMaps (const WorldScopedMaps &)=default
 
 WorldScopedMaps (WorldScopedMaps &&)=default
 
virtual ~WorldScopedMaps ()=default
 

Static Public Attributes

static const int8_t SPACE_FREE = 0
 
static const int8_t SPACE_NA = -1
 
static const int8_t SPACE_OCCUPIED = 100
 

Private Attributes

cv::Mat_< T > data_
 
bool read_only_
 
threshold_free_
 
threshold_occupyied_
 
threshold_unknown_
 

Detailed Description

template<class T>
class tuw::GridMap< T >

Definition at line 44 of file grid_map.h.

Constructor & Destructor Documentation

template<class T >
tuw::GridMap< T >::GridMap ( )
inline

Definition at line 52 of file grid_map.h.

template<class T >
virtual tuw::GridMap< T >::~GridMap ( )
virtualdefault
template<class T >
tuw::GridMap< T >::GridMap ( const GridMap< T > &  )
default
template<class T >
tuw::GridMap< T >::GridMap ( GridMap< T > &&  )
default

Member Function Documentation

template<class T >
void tuw::GridMap< T >::circle ( const Point2D p,
double  radius,
int8_t  value,
int  thickness = 1,
int  lineType = CV_AA 
)
inline

draws a circle given in the visualization space (meter, ....) into a pixel map

Parameters
mapopencv matrix
plocation [m]
radiusradius [m].
value
thicknessline thickness –>
See also
opencv. Negative thickness means that a filled circle is to be drawn.
Parameters
lineTypeline type –>
See also
opencv

Definition at line 101 of file grid_map.h.

template<class T >
int tuw::GridMap< T >::cols ( ) const
inline

Definition at line 180 of file grid_map.h.

template<class T >
void tuw::GridMap< T >::erode ( double  distance,
const GridMap< T > &  src = GridMap< T >() 
)
inline

Definition at line 104 of file grid_map.h.

template<class T >
T& tuw::GridMap< T >::get ( const Point2D _world_coordinates)
inline

Definition at line 129 of file grid_map.h.

template<class T >
const T& tuw::GridMap< T >::get ( const Point2D _world_coordinates) const
inline

Definition at line 133 of file grid_map.h.

template<class T >
const T& tuw::GridMap< T >::getThresholdFree ( )
inline

Definition at line 165 of file grid_map.h.

template<class T >
const T& tuw::GridMap< T >::getThresholdOccupied ( )
inline

Definition at line 157 of file grid_map.h.

template<class T >
const T& tuw::GridMap< T >::getThresholdUnknown ( )
inline

Definition at line 173 of file grid_map.h.

template<class T >
T& tuw::GridMap< T >::grid ( int  row,
int  col 
)
inline

Definition at line 183 of file grid_map.h.

template<class T >
const T& tuw::GridMap< T >::grid ( int  row,
int  col 
) const
inline

Definition at line 187 of file grid_map.h.

template<class T >
template<typename MapMetaData , class ARRAY >
void tuw::GridMap< T >::init ( const MapMetaData &  metadata,
ARRAY *  data 
)
inline

Definition at line 66 of file grid_map.h.

template<class T >
template<typename MapMetaData , class ARRAY >
void tuw::GridMap< T >::init ( MapMetaData &  metadata,
ARRAY &  data 
)
inline

Definition at line 73 of file grid_map.h.

template<class T >
template<typename MapMetaData >
void tuw::GridMap< T >::init ( const MapMetaData &  metadata,
const T &  data,
bool  copy = false 
)
inline

Definition at line 80 of file grid_map.h.

template<class T >
bool tuw::GridMap< T >::isFree ( const Point2D _world_coordinates) const
inline

Definition at line 143 of file grid_map.h.

template<class T >
bool tuw::GridMap< T >::isOccupyied ( const Point2D _world_coordinates) const
inline

Definition at line 137 of file grid_map.h.

template<class T >
const cv::Mat_<T>& tuw::GridMap< T >::mat ( ) const
inline

Definition at line 149 of file grid_map.h.

template<class T >
T& tuw::GridMap< T >::operator() ( double  x,
double  y 
)
inline

Definition at line 113 of file grid_map.h.

template<class T >
const T& tuw::GridMap< T >::operator() ( double  x,
double  y 
) const
inline

Definition at line 117 of file grid_map.h.

template<class T >
T& tuw::GridMap< T >::operator() ( const Point2D _world_coordinates)
inline

Definition at line 121 of file grid_map.h.

template<class T >
const T& tuw::GridMap< T >::operator() ( const Point2D _world_coordinates) const
inline

Definition at line 125 of file grid_map.h.

template<class T >
GridMap& tuw::GridMap< T >::operator= ( const GridMap< T > &  )
default
template<class T >
GridMap& tuw::GridMap< T >::operator= ( GridMap< T > &&  )
default
template<class T >
int tuw::GridMap< T >::rows ( ) const
inline

Definition at line 177 of file grid_map.h.

template<class T >
void tuw::GridMap< T >::setThresholdFree ( const T &  threshold)
inline

Definition at line 161 of file grid_map.h.

template<class T >
void tuw::GridMap< T >::setThresholdOccupied ( const T &  threshold)
inline

Definition at line 153 of file grid_map.h.

template<class T >
void tuw::GridMap< T >::setThresholdUnknown ( const T &  threshold)
inline

Definition at line 169 of file grid_map.h.

Member Data Documentation

template<class T >
cv::Mat_<T> tuw::GridMap< T >::data_
private

Definition at line 193 of file grid_map.h.

template<class T >
bool tuw::GridMap< T >::read_only_
private

Definition at line 192 of file grid_map.h.

template<class T >
const int8_t tuw::GridMap< T >::SPACE_FREE = 0
static

Definition at line 49 of file grid_map.h.

template<class T >
const int8_t tuw::GridMap< T >::SPACE_NA = -1
static

Definition at line 48 of file grid_map.h.

template<class T >
const int8_t tuw::GridMap< T >::SPACE_OCCUPIED = 100
static

Definition at line 50 of file grid_map.h.

template<class T >
T tuw::GridMap< T >::threshold_free_
private

Definition at line 196 of file grid_map.h.

template<class T >
T tuw::GridMap< T >::threshold_occupyied_
private

Definition at line 194 of file grid_map.h.

template<class T >
T tuw::GridMap< T >::threshold_unknown_
private

Definition at line 195 of file grid_map.h.


The documentation for this class was generated from the following file:


tuw_geometry
Author(s): Markus Bader
autogenerated on Mon Jun 10 2019 15:33:09