GLC_Line Class Reference

GLC_Line : OpenGL 3D Line. More...

#include <glc_line.h>

Inheritance diagram for GLC_Line:
GLC_Polylines GLC_Geometry

List of all members.

Public Member Functions

Constructor / Destructor

 GLC_Line (const GLC_Point3d &, const GLC_Point3d &)
 Construct an GLC_Line by to point.
 GLC_Line (const GLC_Line &)
 Copy constructor.
virtual ~GLC_Line ()
 Default dstructor.
Get Functions

GLC_Point3d point1 (void) const
 Return the point1 coordinate.
GLC_Point3d point2 (void) const
 Return the point2 coordinate.
virtual const GLC_BoundingBoxboundingBox (void)
 Return the point bounding box.
virtual GLC_Geometryclone () const
 Return a copy of the geometry.
Set Functions

void setCoordinate (const GLC_Point3d &point1, const GLC_Point3d &point2)
 Set Line coordinate by 3D point.
void clear ()
 Clear the content of this line Data and makes it empty.
GLC_Lineoperator= (const GLC_Line &line)
 Set this line from the given line and return a reference of this line.

Private Member Functions

OpenGL Functions

virtual void glDraw (const GLC_RenderProperties &)
 Virtual interface for OpenGL Geometry set up.
Private services Functions

void createWire ()
 Create the wire.

Private Attributes

GLC_Point3d m_Point1
 First point of the line.
GLC_Point3d m_Point2
 First point of the line.

Detailed Description

GLC_Line : OpenGL 3D Line.

An GLC_Line is just a simple renderable 3D Line

Definition at line 37 of file glc_line.h.


Constructor & Destructor Documentation

GLC_Line::GLC_Line ( const GLC_Point3d point1,
const GLC_Point3d point2 
)

Construct an GLC_Line by to point.

Definition at line 30 of file glc_line.cpp.

References createWire().

Referenced by clone().

GLC_Line::GLC_Line ( const GLC_Line line  ) 

Copy constructor.

Definition at line 38 of file glc_line.cpp.

References createWire().

GLC_Line::~GLC_Line (  )  [virtual]

Default dstructor.

Definition at line 46 of file glc_line.cpp.


Member Function Documentation

const GLC_BoundingBox & GLC_Line::boundingBox ( void   )  [virtual]

Return the point bounding box.

Reimplemented from GLC_Polylines.

Definition at line 55 of file glc_line.cpp.

void GLC_Line::clear (  )  [inline, virtual]

Clear the content of this line Data and makes it empty.

Reimplemented from GLC_Polylines.

Definition at line 86 of file glc_line.h.

References GLC_Polylines::clear().

Referenced by setCoordinate().

GLC_Geometry * GLC_Line::clone (  )  const [virtual]

Return a copy of the geometry.

Reimplemented from GLC_Polylines.

Definition at line 60 of file glc_line.cpp.

References GLC_Line().

void GLC_Line::createWire (  )  [private]

Create the wire.

Definition at line 101 of file glc_line.cpp.

References GLC_Polylines::addPolyline(), m_Point1, and m_Point2.

Referenced by GLC_Line(), and setCoordinate().

void GLC_Line::glDraw ( const GLC_RenderProperties renderProperties  )  [private, virtual]

Virtual interface for OpenGL Geometry set up.

This Virtual function is implemented here.

Reimplemented from GLC_Polylines.

Definition at line 92 of file glc_line.cpp.

GLC_Line & GLC_Line::operator= ( const GLC_Line line  ) 

Set this line from the given line and return a reference of this line.

Definition at line 77 of file glc_line.cpp.

References m_Point1, and m_Point2.

GLC_Point3d GLC_Line::point1 ( void   )  const [inline]

Return the point1 coordinate.

Definition at line 62 of file glc_line.h.

GLC_Point3d GLC_Line::point2 ( void   )  const [inline]

Return the point2 coordinate.

Definition at line 66 of file glc_line.h.

void GLC_Line::setCoordinate ( const GLC_Point3d point1,
const GLC_Point3d point2 
)

Set Line coordinate by 3D point.

Definition at line 69 of file glc_line.cpp.

References clear(), createWire(), m_Point1, and m_Point2.


Member Data Documentation

First point of the line.

Definition at line 122 of file glc_line.h.

Referenced by createWire(), operator=(), and setCoordinate().

First point of the line.

Definition at line 125 of file glc_line.h.

Referenced by createWire(), operator=(), and setCoordinate().


The documentation for this class was generated from the following files:

SourceForge.net Logo

©2005-2011 Laurent Ribon