Developer Documentation
RAVL, Recognition And Vision Library
USER HOME PAGE CLASS LIST CONTENTS
Ravl - Math - Geometry - 2D - Curve2dLineC
 

  PUBLIC
Curve2dLineC::Curve2dLineC(void)
Curve2dLineC::Curve2dLineC(const SArray1dC &)
Curve2dLineC::Curve2dLineC(Point2dC,Point2dC)
Curve2dLineC::Curve2dLineC(const LineABC2dC &)
Curve2dLineC::Curve2dLineC(RealT,RealT)
Curve2dLineC::Curve2dLineC(Point2dC,Vector2dC)
Curve2dLineC::Curve2dLineC(RealT,RealT,RealT)
Curve2dLineC::FitLSQ(const SArray1dC &)
Curve2dLineC::Fit(const SArray1dC &)
Curve2dLineC::AssessFit(const SArray1dC &)
Curve2dLineC::Angle(void)
Curve2dLineC::operator =(const LineABC2dC &)
Curve2dLineC::Tangent(RealT) const
Curve2dLineC::UnitTangent(RealT) const
Curve2dLineC::UnitNormal(void) const
Curve2dLineC::Point(RealT) const
Curve2dLineC::Closest(Point2dC) const
Curve2dLineC::GetLimits(RealT &,RealT &,const IndexRange2dC &) const
Curve2dLineC::GetName(void) const
Curve2dLineC::CodeSize(void) const
Curve2dLineC::WriteGF(ostream &) const
Curve2dLineC::WriteGFHeader(ostream &)
Curve2dLineC::Print(ostream &) const
LineABC2dC::Normal(void) const
LineABC2dC::UnitNormal(void) const
LineABC2dC::Rho(void) const
LineABC2dC::A(void) const
LineABC2dC::B(void) const
LineABC2dC::C(void) const
LineABC2dC::ValueX(const RealT) const
LineABC2dC::ValueY(const RealT) const
LineABC2dC::Residuum(const Point2dC &) const
LineABC2dC::MakeUnitNormal(void)
LineABC2dC::AreParallel(const LineABC2dC &) const
LineABC2dC::Intersection(const LineABC2dC &,Point2dC &) const
LineABC2dC::Intersection(const LineABC2dC &) const
LineABC2dC::SqrEuclidDistance(const Point2dC &) const
LineABC2dC::SignedDistance(const Point2dC &) const
LineABC2dC::Distance(const Point2dC &) const
LineABC2dC::Projection(const Point2dC &) const
LineABC2dC::operator >>(istream &,LineABC2dC &)

   Curve2dLineC   
 
Parametric Line.
 
include "Ravl/Curve2dLine.hh"
Created:26/08/98 
Source file:Ravl/Math/Geometry/Euclidean/2D/Curve2dLine.hh
User Level:Normal
Library:RavlMath
In Scope:RavlN

Comments:
This class modifies the line equation so it always has a unit normal.

Parent Classes: Derived Classes: Methods:
Curve2dLineC()
Default constructor.

Curve2dLineC(const SArray1dC<Point2dC> & Pnts)
Make a line that best fits the given points.

Curve2dLineC(Point2dC p1,Point2dC p2)
Make a line passing through two pixels.

Curve2dLineC(const LineABC2dC & Line)
From a line.

Curve2dLineC(RealT row,RealT theta)
From Y axis crossing point and angle.

Curve2dLineC(Point2dC mid,Vector2dC dir)
From a point and a direction.

Curve2dLineC(RealT a,RealT b,RealT c)
From paramiters.

RealT FitLSQ(const SArray1dC<Point2dC> & Pnts)
Make a line that fits points.

RealT Fit(const SArray1dC<Point2dC> & Pnts)
Default fitting method.

RealT AssessFit(const SArray1dC<Point2dC> & Pnts)
Measure error for fit.

AngleC Angle()

const Curve2dLineC & operator =(const LineABC2dC & It)
Assign from a plain LineABC.

Vector2dC Tangent(RealT) const
Tangent to curve at p

Vector2dC UnitTangent(RealT) const
Tangent to curve at p

Vector2dC UnitNormal() const
Get the unit normal.

Point2dC Point(RealT p) const
Localion of curve at p

RealT Closest(Point2dC Pnt) const
Parametric value of closest point on curve to Pnt.

void GetLimits(RealT & Low,RealT & High,const IndexRange2dC & Rect) const
Get limits of paramiter if shape is within Rect.

char * GetName() const
Name of primitive.

IntT CodeSize() const
Estimated bits to code primitive.

bool WriteGF(ostream & Out) const
Write GF file.

static bool WriteGFHeader(ostream & Out)
Write GF file.

void Print(ostream & out) const
Print to ostream.

Access to the elements of the object.

#include "Ravl/LineABC2d.hh"
Vector2dC Normal() const
Returns the normal of the line.

Vector2dC UnitNormal() const
Returns the normal of the line normalized to have unit size.

RealT Rho() const
Returns the distance of the line from the origin of the coordinate system.

RealT A() const
Returns parameter a.

RealT B() const
Returns parameter b.

RealT C() const
Returns parameter c.

RealT ValueX(const RealT y) const
Returns the value of x coordinate if the y coordinate is known.
If the parameter A() is zero, the zero is returned.

RealT ValueY(const RealT x) const
Returns the value of y coordinate if the x coordinate is known.
If the parameter B() is zero, the zero is returned.

Geometrical constructions.

RealT Residuum(const Point2dC & p) const
Returns the value of the function A()*p.X()+B()*p.Y()+C() often used in geometrical computations.

LineABC2dC & MakeUnitNormal()
Normalizes the equation so that the normal vector is unit.

bool AreParallel(const LineABC2dC & line) const
Returns TRUE if the lines are parallel.

bool Intersection(const LineABC2dC & line,Point2dC & here) const
Find the intersection of two lines.
If the intersection doesn't exist, the function returns false. The intersection is assigned to 'here'.

Point2dC Intersection(const LineABC2dC & line) const
Returns the intersection of both lines.
If the intersection doesn't exist, the function returns Point2dC(0,0).

RealT SqrEuclidDistance(const Point2dC & point) const
Returns the squared Euclidian distance of the 'point' from the line.

RealT SignedDistance(const Point2dC & point) const
Returns the signed distance of the 'point' from the line.
The return value is greater than 0 if the point is on the left side of the line. The left side of the line is determined by the direction of the normal.

RealT Distance(const Point2dC & point) const
Returns the distance of the 'point' from the line.

Point2dC Projection(const Point2dC & point) const
Returns the point which is the orthogonal projection of the 'point' to the line.
It is the same as intersection of this line with the perpendicular line passing through the 'point'.

istream & operator >>(istream & inS,LineABC2dC & line)


Maintainer:Charles Galambos, Created: 26/08/98, Documentation by CxxDoc: Tue Aug 13 09:59:30 2002