GL Studio SCECpp Runtime Library
Classes | Public Member Functions | Protected Member Functions | List of all members
GlsCompositeObject Class Referenceabstract

#include <gls_composite_object.h>

Inheritance diagram for GlsCompositeObject:
GlsDisplayObject GlsComponentBase GlsGroup GlsOdometer

Classes

struct  InitParameters
 

Public Member Functions

virtual void SetChildrenAlphaMode (const GlsAlphaMode alphaMode)=0
 
virtual void SetChildrenFillColor (const GlsColor &fillColor)=0
 
virtual void SetChildrenLineColor (const GlsColor &lineColor)=0
 
virtual void SetChildrenLineWidth (const GlsFloat32 lineWidth)=0
 
virtual void SetChildrenPolygonMode (const GlsPolygonMode polygonMode)=0
 
- Public Member Functions inherited from GlsDisplayObject
virtual void Draw (GlsStateManager &gl, const GlsFloat64 time)=0
 
virtual void Calculate (const GlsFloat64 time)
 
virtual GlsDisplayObjectPickTest (const GlsVector2D &windowCoord, GlsInputManager &inputManager, const GlsMatrixAffineD::GLMatrixAffineF &parentDrawMatrix)
 
GlsDisplayObjectHandleEvent (GlsEvent &event)
 
ObjectType GetObjectType (void) const
 
void SetBlinking (const GlsBool blinking)
 
void SetBlinkRate (const GlsFloat32 blinkRate)
 
void SetDynamicRotation (const GlsVector3D &dynamicRotation)
 
void SetDynamicScale (const GlsVector3D &dynamicScale)
 
void SetDynamicTranslation (const GlsVector3D &dynamicTranslation)
 
void SetVisibility (const GlsBool visible)
 
void SetParent (GlsDisplayObject *const parent)
 
void SetPickMode (const PickMode pickMode)
 
GlsBool NeedCalculate (void) const
 
void InvalidatePickCache (void)
 

Protected Member Functions

 GlsCompositeObject (const InitParameters &initParameters, GlsEventDispatcher *const eventDispatcher)
 
virtual ~GlsCompositeObject ()
 
- Protected Member Functions inherited from GlsDisplayObject
 GlsDisplayObject (const InitParameters &initParameters, const ObjectType objectType, GlsEventDispatcher *const eventDispatcher)
 
virtual ~GlsDisplayObject ()
 
GlsBool CalcDrawMatrix (const GlsMatrixAffineD *const additionalTransform, const GlsBool includeLocation)
 
virtual void CalcWindowPickRegion (GlsInputManager &inputManager, const GlsMatrixAffineD::GLMatrixAffineF &parentDrawMatrix)
 
GlsBool IsBlinkedOff (const GlsFloat64 time) const
 

Additional Inherited Members

- Public Types inherited from GlsDisplayObject
enum  ObjectType { OBJECT_TYPE_COMPOSITE, OBJECT_TYPE_RENDERABLE }
 
enum  PickMode { PICK_MODE_NEVER, PICK_MODE_FIRST, PICK_MODE_ALWAYS }
 
- Protected Attributes inherited from GlsDisplayObject
const GlsMatrixAffineD _dcsMatrix
 
const GlsMatrixAffineD _dcsMatrixInverse
 
const GlsBool _dcsMatrixIsIdentity
 
const GlsVector3D _location
 
const GlsBool _needCalculate
 
const ObjectType _objectType
 
const PickRegion _pickRegion
 
GlsEventDispatcher *const _eventDispatcher
 
const GlsVector3D _rotationPoint
 
GlsBool _blinking
 
GlsFloat32 _blinkRate
 
GlsMatrixAffineD::GLMatrixAffineF _drawMatrix
 
GlsVector3D _dynamicRotation
 
GlsVector3D _dynamicScale
 
GlsBool _dynamicScaleIsUnity
 
GlsVector3D _dynamicTranslation
 
GlsBool _needCalcDrawMatrix
 
GlsBool _visible
 
PickMode _pickMode
 
GlsBool _windowPickRegionValid
 
GlsVector2D _windowPickLowerLeft
 
GlsVector2D _windowPickUpperRight
 
GlsVector2D _windowPickUpperLeft
 
GlsVector2D _windowPickLowerRight
 
GlsMatrixAffineD::GLMatrixAffineF _pickMatrix
 
GlsDisplayObject_parent
 

Detailed Description

The GlsCompositeObject is an abstract base class that serves as an interface for manipulating sets of display objects.

Invariant
base class invariant holds

Constructor & Destructor Documentation

GlsCompositeObject::GlsCompositeObject ( const InitParameters initParameters,
GlsEventDispatcher *const  eventDispatcher 
)
protected

Constructor - create instance

Parameters
initParametersinitialization parameters for instance
eventDispatcherevent dispatcher for this object else GLS_NULL
Precondition
initParameters.IsValid()
Postcondition
instance is constructed
virtual GlsCompositeObject::~GlsCompositeObject ( )
protectedvirtual

Destructor - shall never be called

Precondition
none
Postcondition
none

Member Function Documentation

virtual void GlsCompositeObject::SetChildrenAlphaMode ( const GlsAlphaMode  alphaMode)
pure virtual

Set the alpha mode of the contained objects

Parameters
alphaModedesired alpha mode
Precondition
GlsAlphaModeIsValid( alphaMode )
Postcondition
contained objects have new alpha mode

Implemented in GlsComponentBase, and GlsGroup.

virtual void GlsCompositeObject::SetChildrenFillColor ( const GlsColor fillColor)
pure virtual

Set the fill color of the contained objects

Parameters
fillColordesired fill color
Precondition
fillColor.IsValid()
Postcondition
contained objects have new fill color

Implemented in GlsComponentBase, and GlsGroup.

virtual void GlsCompositeObject::SetChildrenLineColor ( const GlsColor lineColor)
pure virtual

Set the line color of the contained objects

Parameters
lineColordesired line color
Precondition
lineColor.IsValid()
Postcondition
contained objects have new line color

Implemented in GlsComponentBase, and GlsGroup.

virtual void GlsCompositeObject::SetChildrenLineWidth ( const GlsFloat32  lineWidth)
pure virtual

Set the line width of the contained objects

Parameters
lineWidthnew line width, GlsRenderObject::LINE_WIDTH_MIN <= lineWidth <= GlsRenderObject::LINE_WIDTH_MAX
Precondition
GlsLineWidthIsValid( lineWidth )
Postcondition
contained objects have new line width

Implemented in GlsComponentBase, and GlsGroup.

virtual void GlsCompositeObject::SetChildrenPolygonMode ( const GlsPolygonMode  polygonMode)
pure virtual

Set the polygon mode of the contained objects

Parameters
polygonModenew polygon mode
Precondition
GlsPolygonModeIsValid( polygonMode )
Postcondition
contained objects have new polygon mode

Implemented in GlsComponentBase, and GlsGroup.