mimas::line Class Reference

updated by stu 20030228. More...

#include <line.h>

Collaboration diagram for mimas::line:

Collaboration graph
[legend]
List of all members.

Public Types

typedef boost::numeric::ublas::vector<
double
Vector

Public Member Functions

 line (void)
 line (double sx, double sy, double ex, double ey)
 line (const Vector &_start, const Vector &_end)
Vector getVector (void) const
Vector findMidPoint (void) const
Vector getIntersection (const line &l2, bool *on_this_line, bool *on_that_line) const
Vector getIntersectionAngle (const line &l2, angle *retval) const
const VectorgetStart (void) const
const VectorgetEnd (void) const
VectorgetStart (void)
VectorgetEnd (void)
double length (void) const
angle getAngle (const line &l) const

Detailed Description

updated by stu 20030228.

removing the vectors-as-pointers. this cuts down on the number of new's and delete's we need to do and speed things up loads. Ive removed the base class too for now. there doesn't really seem to be much need for it, and again, it slows down construction times.

I'll leave you to work this one out. There should be lots of overloaded operators for lines too, but i havent got around to it yet.

Definition at line 29 of file line.h.


Member Typedef Documentation

typedef boost::numeric::ublas::vector< double > mimas::line::Vector

Definition at line 32 of file line.h.


Constructor & Destructor Documentation

mimas::line::line ( void   )  [inline]

Definition at line 41 of file line.h.

mimas::line::line ( double  sx,
double  sy,
double  ex,
double  ey 
) [inline]

Definition at line 45 of file line.h.

mimas::line::line ( const Vector _start,
const Vector _end 
) [inline]

Definition at line 51 of file line.h.


Member Function Documentation

Vector mimas::line::getVector ( void   )  const [inline]

Definition at line 55 of file line.h.

Vector mimas::line::findMidPoint ( void   )  const [inline]

Definition at line 60 of file line.h.

Vector mimas::line::getIntersection ( const line l2,
bool *  on_this_line,
bool *  on_that_line 
) const

Vector mimas::line::getIntersectionAngle ( const line l2,
angle retval 
) const

const Vector& mimas::line::getStart ( void   )  const [inline]

Definition at line 68 of file line.h.

const Vector& mimas::line::getEnd ( void   )  const [inline]

Definition at line 69 of file line.h.

Vector& mimas::line::getStart ( void   )  [inline]

Definition at line 70 of file line.h.

Vector& mimas::line::getEnd ( void   )  [inline]

Definition at line 71 of file line.h.

double mimas::line::length ( void   )  const [inline]

Definition at line 72 of file line.h.

Referenced by mimas::data< T >::readFromFile().

angle mimas::line::getAngle ( const line l  )  const


The documentation for this class was generated from the following file:
[GNU/Linux] [Qt] [Mesa] [STL] [Lapack] [Boost] [Magick++] [Xalan-C and Xerces-C] [doxygen] [graphviz] [FFTW] [popt] [xine] [Gnuplot] [gnu-arch] [gcc] [gstreamer] [autoconf/automake/make] [freshmeat.net] [opensource.org] [sourceforge.net] [MMVL]
mimas 2.1 - Copyright Mon Oct 30 11:31:35 2006, Bala Amavasai, Stuart Meikle, Arul Selvan, Fabio Caparrelli, Jan Wedekind, Manuel Boissenin, ...