JeVoisBase
1.22
JeVois Smart Embedded Machine Vision Toolkit Base Modules
|
|
This is a basic class to encode 2D integer coordinates. More...
#include <jevoisbase/Components/RoadFinder/Point2D.H>
Public Member Functions | |
Point2D () | |
The default constructor initializes the coordinates to (0,0) | |
Point2D (const T ii, const T jj) | |
Initialize the Point2D from horizontal & vertical coordinates. | |
template<class U > | |
Point2D (const Point2D< U > &a) | |
Explicit conversion from type T to another type U. | |
Point2D< T > & | operator+= (const Point2D< T > &p) |
+= operator | |
Point2D< T > & | operator-= (const Point2D< T > &p) |
-= operator | |
Point2D< T > & | operator*= (const Point2D< T > &p) |
*= operator | |
Point2D< T > & | operator/= (const Point2D< T > &p) |
/= operator | |
template<class U > | |
Point2D< typename promote_trait< T, U >::TP > | operator+ (const Point2D< U > &p) const |
template<class U > | |
Point2D< typename promote_trait< T, U >::TP > | operator- (const Point2D< U > &p) const |
template<class U > | |
Point2D< typename promote_trait< T, U >::TP > | operator* (const Point2D< U > &p) const |
template<class U > | |
Point2D< typename promote_trait< T, U >::TP > | operator/ (const Point2D< U > &p) const |
/ operator | |
Point2D< T > & | operator+= (const T val) |
+= operator | |
Point2D< T > & | operator-= (const T val) |
-= operator | |
Point2D< T > & | operator*= (const T val) |
*= operator | |
Point2D< T > & | operator/= (const T val) |
/= operator | |
template<class U > | |
Point2D< typename promote_trait< T, U >::TP > | operator+ (const U val) const |
template<class U > | |
Point2D< typename promote_trait< T, U >::TP > | operator- (const U val) const |
template<class U > | |
Point2D< typename promote_trait< T, U >::TP > | operator* (const U val) const |
template<class U > | |
Point2D< typename promote_trait< T, U >::TP > | operator/ (const U val) const |
/ operator | |
bool | isValid () const |
test whether i and j are both positive | |
promote_trait< T, float >::TP | squdist (const Point2D< T > &p) const |
the square of the euclidean distance | |
promote_trait< T, float >::TP | distance (const Point2D< T > &p) const |
the euclidean distance from p | |
promote_trait< T, float >::TP | magnitude () const |
the Magnitude | |
promote_trait< T, float >::TP | distanceToLine (const Point2D< T > &p, const Point2D< T > &q, const bool getsigned=false) const |
the euclidean distance from line pq | |
promote_trait< T, float >::TP | distanceToSegment (const Point2D< T > &p, const Point2D< T > &q) const |
the euclidean distance from segment pq | |
Public Attributes | |
T | i |
2D coordinates | |
T | j |
This is a basic class to encode 2D integer coordinates.
This is a completely public class whose goal is just to provide a shorthand notation for 2D integer coordinates.
|
inline |
the euclidean distance from p
Definition at line 357 of file Point2D.H.
Referenced by angleMeasure(), RoadFinder::combine(), RoadFinder::computeVanishingLines(), RoadFinder::discardDuplicates(), RoadFinder::findLine2(), RoadFinder::getLineFitness(), RoadFinder::getPixels(), and RoadFinder::updateRoadModel().
|
inline |
the euclidean distance from line pq
Definition at line 369 of file Point2D.H.
References Point2D< T >::i, and Point2D< T >::j.
|
inline |
the euclidean distance from segment pq
Definition at line 382 of file Point2D.H.
References Point2D< T >::i, and Point2D< T >::j.
|
inline |
test whether i and j are both positive
Definition at line 341 of file Point2D.H.
Referenced by RoadFinder::process().
|
inline |
|
inline |
|
inline |
*= operator
Definition at line 235 of file Point2D.H.
References Point2D< T >::i, and Point2D< T >::j.
|
inline |
|
inline |
+= operator
Definition at line 225 of file Point2D.H.
References Point2D< T >::i, and Point2D< T >::j.
|
inline |
|
inline |
-= operator
Definition at line 230 of file Point2D.H.
References Point2D< T >::i, and Point2D< T >::j.
|
inline |
/ operator
Definition at line 268 of file Point2D.H.
References Point2D< T >::i, and Point2D< T >::j.
|
inline |
/= operator
Definition at line 240 of file Point2D.H.
References Point2D< T >::i, and Point2D< T >::j.
|
inline |
the square of the euclidean distance
Definition at line 347 of file Point2D.H.
References Point2D< T >::i, and Point2D< T >::j.
T Point2D< T >::i |
2D coordinates
Definition at line 157 of file Point2D.H.
Referenced by angleMeasure(), RoadFinder::computeHoughSegments(), RoadFinder::computeRoadCenterPoint(), RoadFinder::computeVanishingLines(), Point2D< T >::distanceToLine(), Point2D< T >::distanceToSegment(), RoadFinder::fitLine(), RoadFinder::getLineFitness(), RoadFinder::getPixels(), RoadFinder::getPixelsQuick(), RoadFinder::getVanishingPoint(), operator!=(), Point2D< T >::operator*(), Point2D< T >::operator*=(), Point2D< T >::operator+(), Point2D< T >::operator+=(), Point2D< T >::operator-(), Point2D< T >::operator-=(), Point2D< T >::operator/(), Point2D< T >::operator/=(), operator<(), operator==(), operator>(), pnpoly(), pnTriangle(), RoadFinder::process(), RoadFinder::RoadFinder(), Point2D< T >::squdist(), RoadFinder::trackVanishingLines(), and RoadFinder::updateLine().
T Point2D< T >::j |
Definition at line 157 of file Point2D.H.
Referenced by angleMeasure(), RoadFinder::computeHoughSegments(), RoadFinder::computeRoadCenterPoint(), RoadFinder::computeVanishingLines(), Point2D< T >::distanceToLine(), Point2D< T >::distanceToSegment(), RoadFinder::fitLine(), RoadFinder::getLineFitness(), RoadFinder::getPixels(), RoadFinder::getPixelsQuick(), operator!=(), Point2D< T >::operator*(), Point2D< T >::operator*=(), Point2D< T >::operator+(), Point2D< T >::operator+=(), Point2D< T >::operator-(), Point2D< T >::operator-=(), Point2D< T >::operator/(), Point2D< T >::operator/=(), operator<(), operator==(), operator>(), pnpoly(), pnTriangle(), RoadFinder::process(), RoadFinder::RoadFinder(), Point2D< T >::squdist(), RoadFinder::trackVanishingLines(), and RoadFinder::updateLine().