Autoware.Auto
autoware::motion::planning::parking_planner::Point2D< T > Class Template Reference

Class describing a point in two-dimensional space. More...

#include <geometry.hpp>

Public Member Functions

 Point2D () noexcept
 No-argument constructor. More...
 
 Point2D (T x, T y) noexcept
 Scalar type Constructor. More...
 
bool operator== (const Point2D< T > &other) const noexcept
 Check for equality of two points. More...
 
Point2D< T > operator+ (const Point2D< T > &other) const noexcept
 Add two points. More...
 
Point2D< T > operator- (const Point2D< T > &other) const noexcept
 Subtract one point from the other. More...
 
Point2D< T > operator/ (const T dividend) const
 Divide by a constant. More...
 
Point2D< T > operator* (const T multiplier) const noexcept
 Multiply by something. More...
 
norm2 () const noexcept
 Compute the 2-norm of a point (as in, the distance to the origin) More...
 
dot (const Point2D< T > &other) const noexcept
 Perform inner-product. More...
 
void rotate (const T angle) noexcept
 Rotate around the origin. More...
 
const std::pair< T, T > & get_coord () const noexcept
 Get the coordinates. More...
 

Detailed Description

template<typename T>
class autoware::motion::planning::parking_planner::Point2D< T >

Class describing a point in two-dimensional space.

Constructor & Destructor Documentation

◆ Point2D() [1/2]

template<typename T>
autoware::motion::planning::parking_planner::Point2D< T >::Point2D ( )
inlinenoexcept

No-argument constructor.

◆ Point2D() [2/2]

template<typename T>
autoware::motion::planning::parking_planner::Point2D< T >::Point2D ( x,
y 
)
inlinenoexcept

Scalar type Constructor.

Member Function Documentation

◆ dot()

template<typename T>
T autoware::motion::planning::parking_planner::Point2D< T >::dot ( const Point2D< T > &  other) const
inlinenoexcept

Perform inner-product.

◆ get_coord()

template<typename T>
const std::pair<T, T>& autoware::motion::planning::parking_planner::Point2D< T >::get_coord ( ) const
inlinenoexcept

Get the coordinates.

◆ norm2()

template<typename T>
T autoware::motion::planning::parking_planner::Point2D< T >::norm2 ( ) const
inlinenoexcept

Compute the 2-norm of a point (as in, the distance to the origin)

◆ operator*()

template<typename T>
Point2D<T> autoware::motion::planning::parking_planner::Point2D< T >::operator* ( const T  multiplier) const
inlinenoexcept

Multiply by something.

◆ operator+()

template<typename T>
Point2D<T> autoware::motion::planning::parking_planner::Point2D< T >::operator+ ( const Point2D< T > &  other) const
inlinenoexcept

Add two points.

◆ operator-()

template<typename T>
Point2D<T> autoware::motion::planning::parking_planner::Point2D< T >::operator- ( const Point2D< T > &  other) const
inlinenoexcept

Subtract one point from the other.

◆ operator/()

template<typename T>
Point2D<T> autoware::motion::planning::parking_planner::Point2D< T >::operator/ ( const T  dividend) const
inline

Divide by a constant.

◆ operator==()

template<typename T>
bool autoware::motion::planning::parking_planner::Point2D< T >::operator== ( const Point2D< T > &  other) const
inlinenoexcept

Check for equality of two points.

◆ rotate()

template<typename T>
void autoware::motion::planning::parking_planner::Point2D< T >::rotate ( const T  angle)
inlinenoexcept

Rotate around the origin.


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