|
User Documentation |
|
Centre for Vision, Speech & Signal Processing |
Comments:
The class represents a point in 1 dimensional projective space.
The point contains 2 real numbers which serve as its projective
coordinates.
Parent Classes:
Typedefs:
- typedef Point2dC::CoordT PCoordT;
-
A projective coordinate.
- typedef Point2dC::CoordT CCoordT;
-
An cartesian coordinate.
Methods:
- PPoint1dC()
-
Constructs the point whose coordinates are zeros, eg. non-existing
projective point.
- PPoint1dC(CCoordT x)
-
Constructs the point (x, 1).
- PPoint1dC(PCoordT p1,PCoordT p2)
-
Constructs the point (p1, p2).
- PPoint1dC(const PPoint1dC & p)
-
Copy constructor.
- const PPoint1dC & operator=(const PPoint1dC & p)
-
Assigment of point.
Access to the coordinates.
--------------------------
- const PCoordT & operator[](IndexT i) const
-
Returns the value of the (i+1)-th projective coordinate.
- PCoordT & operator[](IndexT i)
-
Access the value of the (i+1)-th projective coordinate.
- CCoordT operator()(IndexT i) const
-
Returns the value of the (i+1)-th Cartesian coordinate.
The function does not check if the point is ideal or not or
the range of the index 'i'.
- PCoordT Scale() const
-
Returns the value of the last projective coordinate P2().
- const PCoordT & P1() const
-
Returns the value of the 1-st coordinate.
- const PCoordT & P2() const
-
Returns the value of the 2-st coordinate.
- PCoordT & P1()
-
Returns the value of the 1-st coordinate.
- PCoordT & P2()
-
Returns the value of the 2-st coordinate.
- CCoordT X() const
-
Returns the value of the Cartesian coordinate. The function
does not check if the point is ideal or not.
- const PPoint1dC & PPoint1d() const
-
Access to this constant object.
- PPoint1dC & PPoint1d()
-
Access to the point.
Logical conditions.
-------------------
- BooleanT operator==(const PPoint1dC & p) const
-
Returns TRUE iff 2 points are the same projective point.
Two projective points are equal iff their 2D Cartesian representants
are equal.
- BooleanT operator!=(const PPoint1dC & p) const
-
Returns TRUE iff 2 points are different projective points.
Two projective points are different iff they are not
equal in the sense of the operator '=='.
- BooleanT IsIdeal() const
-
Returns TRUE iff this point is an ideal projective point.
The point is an ideal projective point if the absolute value of
the ratio Scale()/SumAbs() is smaller or equal to
the threshold 'Point2dC::relZero'.
- BooleanT IsColinear(const PPoint1dC & q2,const PPoint1dC & q3) const
-
Returns always TRUE.
- BooleanT IsValid() const
-
Returns TRUE if the sum of absolute values of the projective coordinates
is bigger than the threshold 'Point2dC::zeroDistance'.
Setting of the coordinates.
---------------------------
- void Set(const PPoint1dC & p)
-
Sets both coordinates according to the values of the point 'p'.
- void Set(const PCoordT p1,const PCoordT p2)
-
Sets the 1-st coordinate to be 'p1' and the 2nd one to be 'p2'.
Information about extrems.
--------------------------
- IndexT MaxIndex() const
-
Returns the index of the maximum coordinate.
- IndexT MinIndex() const
-
Returns the index of the minimum coordinate.
- IndexT AbsMaxIndex() const
-
Returns the index of the maximum coordinate in absolute value.
- IndexT AbsMinIndex() const
-
Returns the index of the minimum coordinate in absolute value.
- PCoordT Sum() const
-
Returns the sum of coordinates.
- PCoordT SumAbs() const
-
Returns the sum of absolute value of projective coordinates.
Arithmetical operations.
------------------------
- const PPoint1dC & operator+=(const PPoint1dC & point)
-
Adds the values of the coordinates of the 'point' to this point.
- const PPoint1dC & operator-=(const PPoint1dC & point)
-
Subtracts the values of the coordinates of the 'point' from this point.
- const PPoint1dC & operator*=(const RealT alpha)
-
Multiplies both coordinates by 'alpha'.
- const PPoint1dC & operator/=(const RealT alpha)
-
Divides both coordinates by 'alpha'.
- PPoint1dC operator+(const PPoint1dC & point) const
-
Returns the point which is the sum of this point and the 'point'.
- PPoint1dC operator*(const RealT alpha) const
-
Returns the point which coordinates are multiplied by 'alpha'.
- PPoint1dC operator/(const RealT alpha) const
-
Returns the point which coordinates are divided by 'alpha'.
Geometrical operations.
-----------------------
- PPoint1dC Translation(const PPoint1dC & newOrigin) const
-
Returns the point with projective coordinates related to the new origin
'newOrigin'.
- RealT operator&(const PPoint1dC & p) const
-
Returns the sum P1()*p.P1() + P2()*p.P2(). In 2 dimensional Euclidian
vector space the result is equivalent to dot product of 2 vectors.
|
Programmer:Radek Marik, Documentation by CxxDoc: Tue Mar 20 10:48:08 2001
|