
#include <Image/Point2D.H>
Collaboration diagram for Point2D< T >:

This is a completely public class whose goal is just to provide a shorthand notation for 2D integer coordinates.
Definition at line 53 of file 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. | |
| Point2D (const Dims &d) | |
| Initialize from a Dims object; i=w, j=h. | |
| 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 |
| + 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 |
| * operator | |
| 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 |
| + 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 |
| * operator | |
| 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 | |
| void | clampToDims (const Dims &dims) |
| clamp the coords such that the point fits into image of dimensions dims | |
Public Attributes | |
| T | i |
| 2D coordinates | |
| T | j |
|
|||||||||
|
The default constructor initializes the coordinates to (0,0).
Definition at line 173 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||||||||
|
Initialize the Point2D from horizontal & vertical coordinates.
Definition at line 178 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||
|
Initialize from a Dims object; i=w, j=h.
Definition at line 183 of file Point2D.H. References Dims::h(), Point2D< T >::i, Point2D< T >::j, and Dims::w(). |
|
||||||||||||||
|
Explicit conversion from type T to another type U. Note that this simply uses clamped_convert, so it will clamp coordinates to the available range of T, and may round down. |
|
||||||||||
|
clamp the coords such that the point fits into image of dimensions dims
Definition at line 332 of file Point2D.H. References Dims::h(), Point2D< T >::i, Dims::isEmpty(), Point2D< T >::j, LFATAL, and Dims::w(). Referenced by FrictionSaccadeController::computeWhenNewDecision(), EnvSegmenterColorRegion::getFoa(), SimulationViewerCompress::getTraj(), and V2::I_normalization(). |
|
||||||||||
|
|||||||||
|
||||||||||||||
|
* operator
Definition at line 279 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||||||
|
* operator
Definition at line 231 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||
|
*= operator
Definition at line 253 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||
|
*= operator
Definition at line 205 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||||||
|
+ operator
Definition at line 265 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||||||
|
+ operator
Definition at line 217 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||
|
+= operator
Definition at line 243 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||
|
+= operator
Definition at line 195 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||||||
|
Definition at line 272 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||||||
|
Definition at line 224 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||
|
-= operator
Definition at line 248 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||
|
-= operator
Definition at line 200 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||||||
|
/ operator
Definition at line 286 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||||||
|
/ operator
Definition at line 238 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||
|
/= operator
Definition at line 258 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||
|
/= operator
Definition at line 210 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. |
|
||||||||||
|
the square of the euclidean distance
Definition at line 317 of file Point2D.H. References Point2D< T >::i, and Point2D< T >::j. Referenced by ThresholdSaccadeController::checkPercepts(), ThresholdSaccadeController::computeWhenNewDecision(), V1::EdgeState::distance(), Point2D< T >::distance(), and EnvSaliencyMap::getSalmap(). |
|
|||||
1.4.4