Main Page | Modules | Namespace List | Class Hierarchy | Class List | Namespace Members | Class Members

VIEW::GeometricObject Class Reference
[Geometric primitives and their management]

GeometricObject class. More...

#include <geometricObject.h>

Inheritance diagram for VIEW::GeometricObject:

VIEW::Box VIEW::Disc VIEW::GridVisualisation VIEW::Label VIEW::Line VIEW::Mesh VIEW::MultiLine VIEW::Point VIEW::QuadMesh VIEW::SimpleBox VIEW::Sphere VIEW::Tube VIEW::TwoColoredLine VIEW::TwoColoredTube List of all members.

Public Member Functions

 GeometricObject () throw ()
 Default Constructor.
 GeometricObject (const GeometricObject &object) throw ()
 Copy constructor.
virtual ~GeometricObject () throw ()
 Destructor.
virtual void clear () throw ()
 Explicit default initialization.
Assignment methods
void set (const GeometricObject &object) throw ()
 Assignment.
GeometricObjectoperator= (const GeometricObject &object) throw ()
 Assignment operator.
void swap (GeometricObject &object) throw ()
 Swapping of geometricObjects.
Accessors: inspectors and mutators
void setComposite (const Composite *composite) throw ()
const CompositegetComposite () const throw ()
debuggers and diagnostics
virtual bool isValid () const throw ()
 Internal state and consistency self-validation.
virtual void dump (std::ostream &s=std::cout, Size depth=0) const throw ()
 Internal value dump.
void setColor (const ColorRGBA &color) throw ()
void setColor (const ColorUnit &red, const ColorUnit &green, const ColorUnit &blue, const ColorUnit &alpha=(float) 1) throw ()
const ColorRGBAgetColor () const throw ()
ColorRGBAgetColor () throw ()
void getColor (ColorUnit &red, ColorUnit &green, ColorUnit &blue, ColorUnit &alpha) const throw ()
void getColors (HashSet< String > &colors)
 Insert the colors of this object into the hashset.
bool operator== (const GeometricObject &object) const throw ()
 Needed for MSVC.
bool operator< (const GeometricObject &object) const throw ()
 Needed for MSVC.
virtual void getVertices (std::vector< Vector3 > &) const

Detailed Description

GeometricObject class.

The class GeometricObject is the most important base class for a geometric primitive. All geometric primitives must be derived from this class. This class contains only the general information like color, name and the composite pointer.


Constructor & Destructor Documentation

VIEW::GeometricObject::GeometricObject  )  throw ()
 

Default Constructor.

The state of this geometricObject is:

  • selected color is set to yellow (1.0, 1.0, 0.0, 1.0)
  • name is set to "unknown"
  • typename is set to "GeometricObject"
    Returns:
    GeometricObject new constructed geometricObject
    See also:
    ColorRGBA

VIEW::GeometricObject::GeometricObject const GeometricObject object  )  throw ()
 

Copy constructor.

Parameters:
object the geometricObject to be copied (cloned)

virtual VIEW::GeometricObject::~GeometricObject  )  throw () [virtual]
 

Destructor.


Member Function Documentation

virtual void VIEW::GeometricObject::clear  )  throw () [virtual]
 

Explicit default initialization.

Set the state of this geometricObject to the default values. The state of this geometricObject is:

  • selected color is set to yellow (1.0, 1.0, 0.0, 1.0)
  • name is set to "unknown"

Reimplemented in VIEW::Box, VIEW::Disc, VIEW::Label, VIEW::Line, VIEW::Mesh, VIEW::MultiLine, VIEW::Point, VIEW::SimpleBox, VIEW::Sphere, VIEW::Tube, VIEW::TwoColoredLine, and VIEW::TwoColoredTube.

virtual void VIEW::GeometricObject::dump std::ostream &  s = std::cout,
Size  depth = 0
const throw () [virtual]
 

Internal value dump.

Dump the current state of this geometricObject to the output ostream s with dumping depth depth.

Parameters:
s output stream where to output the state of this geometricObject
depth the dumping depth
See also:
ColorRGBA::dump

Reimplemented in VIEW::Box, VIEW::Disc, VIEW::Label, VIEW::Line, VIEW::Mesh, VIEW::MultiLine, VIEW::Point, VIEW::SimpleBox, VIEW::Sphere, VIEW::Tube, VIEW::TwoColoredLine, and VIEW::TwoColoredTube.

virtual bool VIEW::GeometricObject::isValid  )  const throw () [virtual]
 

Internal state and consistency self-validation.

Initiate self-validation of the internal state and data structure consistencies of this geometricObject. If the internal state of this geometricObject is correct (self-validated) and consistent true is returned, false otherwise.

Returns:
bool true if the internal state of this geometricObject is correct

Reimplemented in VIEW::Box, VIEW::Disc, VIEW::Label, VIEW::Line, VIEW::Mesh, VIEW::MultiLine, VIEW::Point, VIEW::SimpleBox, VIEW::Sphere, VIEW::Tube, VIEW::TwoColoredLine, and VIEW::TwoColoredTube.

GeometricObject& VIEW::GeometricObject::operator= const GeometricObject object  )  throw ()
 

Assignment operator.

Calls set.

void VIEW::GeometricObject::swap GeometricObject object  )  throw ()
 

Swapping of geometricObjects.

Parameters:
object the geometricObject being swapped with this geometricObject