MRPT
2.0.4
|
This is a template class for storing a 3D (2D+heading) grid containing any kind of data.
Definition at line 22 of file CPose2DGridTemplate.h.
#include <mrpt/poses/CPose2DGridTemplate.h>
Public Member Functions | |
size_t | x2idx (double x) const |
Returns "indexes" from coordinates: More... | |
size_t | y2idx (double y) const |
Returns "indexes" from coordinates: More... | |
size_t | phi2idx (double phi) const |
Returns "indexes" from coordinates: More... | |
double | idx2x (size_t x) const |
Returns coordinates from "indexes": More... | |
double | idx2y (size_t y) const |
Returns coordinates from "indexes": More... | |
double | idx2phi (size_t phi) const |
Returns coordinates from "indexes": More... | |
CPose2DGridTemplate (double xMin=-1.0f, double xMax=1.0f, double yMin=-1.0f, double yMax=1.0f, double resolutionXY=0.5f, double resolutionPhi=mrpt::DEG2RAD(180.0), double phiMin=-M_PI, double phiMax=M_PI) | |
Default constructor: More... | |
virtual | ~CPose2DGridTemplate ()=default |
void | setSize (double xMin, double xMax, double yMin, double yMax, double resolutionXY, double resolutionPhi, double phiMin=-M_PI, double phiMax=M_PI) |
Changes the limits and size of the grid, erasing previous contents: More... | |
const T * | getByPos (double x, double y, double phi) const |
Reads the contents of a cell. More... | |
T * | getByPos (double x, double y, double phi) |
Reads the contents of a cell. More... | |
const T * | getByIndex (size_t x, size_t y, size_t phi) const |
Reads the contents of a cell. More... | |
T * | getByIndex (size_t x, size_t y, size_t phi) |
Reads the contents of a cell. More... | |
template<class MATRIXLIKE > | |
void | getAsMatrix (double phi, MATRIXLIKE &outMat) |
Returns the whole grid as a matrix, for a given constant "phi" and where each row contains values for a fixed "y". More... | |
double | getXMin () const |
Get info about the grid: More... | |
double | getXMax () const |
double | getYMin () const |
double | getYMax () const |
double | getPhiMin () const |
double | getPhiMax () const |
double | getResolutionXY () const |
double | getResolutionPhi () const |
size_t | getSizeX () const |
size_t | getSizeY () const |
size_t | getSizePhi () const |
Protected Attributes | |
double | m_xMin |
The limits and resolution of the grid: More... | |
double | m_xMax |
double | m_yMin |
double | m_yMax |
double | m_phiMin |
double | m_phiMax |
double | m_resolutionXY |
double | m_resolutionPhi |
size_t | m_sizeX |
The size of "m_data" is m_sizeX * m_sizeY * m_sizePhi. More... | |
size_t | m_sizeY |
size_t | m_sizePhi |
size_t | m_sizeXY |
int | m_idxLeftX |
The indexes of the "left" borders: More... | |
int | m_idxLeftY |
int | m_idxLeftPhi |
std::vector< T > | m_data |
The data: More... | |
|
inline |
Default constructor:
Definition at line 96 of file CPose2DGridTemplate.h.
|
virtualdefault |
|
inline |
Returns the whole grid as a matrix, for a given constant "phi" and where each row contains values for a fixed "y".
Definition at line 182 of file CPose2DGridTemplate.h.
|
inline |
Reads the contents of a cell.
Definition at line 164 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::getByPos().
|
inline |
Reads the contents of a cell.
Definition at line 172 of file CPose2DGridTemplate.h.
|
inline |
Reads the contents of a cell.
Definition at line 150 of file CPose2DGridTemplate.h.
Referenced by TEST().
|
inline |
Reads the contents of a cell.
Definition at line 157 of file CPose2DGridTemplate.h.
|
inline |
Definition at line 201 of file CPose2DGridTemplate.h.
Referenced by TEST().
|
inline |
Definition at line 200 of file CPose2DGridTemplate.h.
Referenced by TEST().
|
inline |
Definition at line 203 of file CPose2DGridTemplate.h.
|
inline |
Definition at line 202 of file CPose2DGridTemplate.h.
|
inline |
Definition at line 206 of file CPose2DGridTemplate.h.
|
inline |
Definition at line 204 of file CPose2DGridTemplate.h.
|
inline |
Definition at line 205 of file CPose2DGridTemplate.h.
|
inline |
Definition at line 197 of file CPose2DGridTemplate.h.
Referenced by TEST().
|
inline |
Get info about the grid:
Definition at line 196 of file CPose2DGridTemplate.h.
Referenced by TEST().
|
inline |
Definition at line 199 of file CPose2DGridTemplate.h.
Referenced by TEST().
|
inline |
Definition at line 198 of file CPose2DGridTemplate.h.
Referenced by TEST().
|
inline |
Returns coordinates from "indexes":
Definition at line 88 of file CPose2DGridTemplate.h.
|
inline |
Returns coordinates from "indexes":
Definition at line 72 of file CPose2DGridTemplate.h.
|
inline |
Returns coordinates from "indexes":
Definition at line 80 of file CPose2DGridTemplate.h.
|
inline |
Returns "indexes" from coordinates:
Definition at line 63 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::getAsMatrix(), and mrpt::poses::CPose2DGridTemplate< double >::getByPos().
|
inline |
Changes the limits and size of the grid, erasing previous contents:
Definition at line 111 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::CPose2DGridTemplate(), and TEST().
|
inline |
Returns "indexes" from coordinates:
Definition at line 45 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::getByPos().
|
inline |
Returns "indexes" from coordinates:
Definition at line 54 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::getByPos().
|
protected |
The data:
Definition at line 40 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::getAsMatrix(), mrpt::poses::CPose2DGridTemplate< double >::getByIndex(), and mrpt::poses::CPose2DGridTemplate< double >::setSize().
|
protected |
Definition at line 36 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::setSize().
|
protected |
The indexes of the "left" borders:
Definition at line 36 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::setSize().
|
protected |
Definition at line 36 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::setSize().
|
protected |
Definition at line 27 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::getPhiMax(), and mrpt::poses::CPose2DGridTemplate< double >::setSize().
|
protected |
|
protected |
|
protected |
Definition at line 27 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::getResolutionXY(), mrpt::poses::CPose2DGridTemplate< double >::idx2x(), mrpt::poses::CPose2DGridTemplate< double >::idx2y(), mrpt::poses::CPose2DGridTemplate< double >::setSize(), mrpt::poses::CPose2DGridTemplate< double >::x2idx(), and mrpt::poses::CPose2DGridTemplate< double >::y2idx().
|
protected |
Definition at line 32 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::getAsMatrix(), mrpt::poses::CPose2DGridTemplate< double >::getByIndex(), mrpt::poses::CPose2DGridTemplate< double >::getSizePhi(), mrpt::poses::CPose2DGridTemplate< double >::idx2phi(), mrpt::poses::CPose2DGridTemplate< double >::phi2idx(), and mrpt::poses::CPose2DGridTemplate< double >::setSize().
|
protected |
The size of "m_data" is m_sizeX * m_sizeY * m_sizePhi.
Definition at line 32 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::getAsMatrix(), mrpt::poses::CPose2DGridTemplate< double >::getByIndex(), mrpt::poses::CPose2DGridTemplate< double >::getSizeX(), mrpt::poses::CPose2DGridTemplate< double >::idx2x(), mrpt::poses::CPose2DGridTemplate< double >::setSize(), and mrpt::poses::CPose2DGridTemplate< double >::x2idx().
|
protected |
Definition at line 32 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::getAsMatrix(), mrpt::poses::CPose2DGridTemplate< double >::getByIndex(), and mrpt::poses::CPose2DGridTemplate< double >::setSize().
|
protected |
Definition at line 32 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::getAsMatrix(), mrpt::poses::CPose2DGridTemplate< double >::getByIndex(), mrpt::poses::CPose2DGridTemplate< double >::getSizeY(), mrpt::poses::CPose2DGridTemplate< double >::idx2y(), mrpt::poses::CPose2DGridTemplate< double >::setSize(), and mrpt::poses::CPose2DGridTemplate< double >::y2idx().
|
protected |
Definition at line 27 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::getXMax(), and mrpt::poses::CPose2DGridTemplate< double >::setSize().
|
protected |
The limits and resolution of the grid:
Definition at line 27 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::getXMin(), mrpt::poses::CPose2DGridTemplate< double >::idx2x(), mrpt::poses::CPose2DGridTemplate< double >::setSize(), and mrpt::poses::CPose2DGridTemplate< double >::x2idx().
|
protected |
Definition at line 27 of file CPose2DGridTemplate.h.
Referenced by mrpt::poses::CPose2DGridTemplate< double >::getYMax(), and mrpt::poses::CPose2DGridTemplate< double >::setSize().
|
protected |
Page generated by Doxygen 1.8.14 for MRPT 2.0.4 Git: 33de1d0ad Sat Jun 20 11:02:42 2020 +0200 at sáb jun 20 17:35:17 CEST 2020 |