51 template <
class OTHERCLASS>
106 static constexpr
bool empty() {
return false; }
111 throw std::logic_error(
format(
112 "Try to change the size of CPoint2D to %u.",
113 static_cast<unsigned>(
n)));
double x() const
Common members of all points & poses classes.
static constexpr bool is_PDF()
static void resize(const size_t n)
static constexpr bool empty()
CPoint2D(const CPoseOrPoint< OTHERCLASS > &b)
Constructor from x/y coordinates given from other pose.
mrpt::math::CArrayDouble< 2 > m_coords
[x,y]
CArrayNumeric is an array for numeric types supporting several mathematical operations (actually...
static constexpr size_type max_size()
CPoint2D(const mrpt::math::TPoint2D &o)
Implicit constructor from lightweight type.
A base class for representing a point in 2D or 3D.
double x
X,Y,Z coordinates.
CPoint2D(double x=0, double y=0)
Constructor for initializing point coordinates.
The base template class for 2D & 3D points and poses.
A class used to store a 2D point.
Classes for 2D/3D geometry representation, both of single values and probability density distribution...
void setToNaN() override
Set all data fields to quiet NaN.
#define DEFINE_SERIALIZABLE(class_name)
This declaration must be inserted in all CSerializable classes definition, within the class declarati...
A class used to store a 2D pose, including the 2D coordinate point and a heading (phi) angle...
std::string format(const char *fmt,...) MRPT_printf_format_check(1
A std::string version of C sprintf.
std::ptrdiff_t difference_type
double value_type
The type of the elements.
The virtual base class which provides a unified interface for all persistent objects in MRPT...
CPoint2D operator-(const CPose2D &b) const
The operator D="this"-b is the pose inverse compounding operator, the resulting points "D" fulfils: "...
mrpt::math::TPoint2D asTPoint() const
CPoint2D(const mrpt::math::TPoint3D &o)
Explicit constructor from lightweight type (loses the z coord).
static constexpr bool is_3D()
static constexpr size_type size()
const double & const_reference