Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

osg::PolygonChunkBase Class Reference

PolygonChunk Base Class.

#include <OSGPolygonChunkBase.h>

Inheritance diagram for osg::PolygonChunkBase:

osg::StateChunk osg::StateChunkBase osg::Attachment osg::FieldContainer osg::PolygonChunk List of all members.

Public Types

typedef PolygonChunkPtr Ptr
enum  {
  CullFaceFieldId = Inherited::NextFieldId, FrontFaceFieldId = CullFaceFieldId + 1, FrontModeFieldId = FrontFaceFieldId + 1, BackModeFieldId = FrontModeFieldId + 1,
  SmoothFieldId = BackModeFieldId + 1, OffsetFactorFieldId = SmoothFieldId + 1, OffsetBiasFieldId = OffsetFactorFieldId + 1, OffsetPointFieldId = OffsetBiasFieldId + 1,
  OffsetLineFieldId = OffsetPointFieldId + 1, OffsetFillFieldId = OffsetLineFieldId + 1, StippleFieldId = OffsetFillFieldId + 1, NextFieldId = StippleFieldId + 1
}

Public Member Functions

FieldContainer Get
*virtual FieldContainerTypegetType (void)
virtual const FieldContainerTypegetType (void) const
virtual UInt32 getContainerSize (void) const
Field Get
*SFInt32getSFCullFace (void)
 Get the PolygonChunk::_sfCullFace field.
SFInt32getSFFrontFace (void)
 Get the PolygonChunk::_sfFrontFace field.
SFInt32getSFFrontMode (void)
 Get the PolygonChunk::_sfFrontMode field.
SFInt32getSFBackMode (void)
 Get the PolygonChunk::_sfBackMode field.
SFBoolgetSFSmooth (void)
 Get the PolygonChunk::_sfSmooth field.
SFReal32getSFOffsetFactor (void)
 Get the PolygonChunk::_sfOffsetFactor field.
SFReal32getSFOffsetBias (void)
 Get the PolygonChunk::_sfOffsetBias field.
SFBoolgetSFOffsetPoint (void)
 Get the PolygonChunk::_sfOffsetPoint field.
SFBoolgetSFOffsetLine (void)
 Get the PolygonChunk::_sfOffsetLine field.
SFBoolgetSFOffsetFill (void)
 Get the PolygonChunk::_sfOffsetFill field.
MFInt32getMFStipple (void)
 Get the PolygonChunk::_mfStipple field.
Int32getCullFace (void)
 Get the value of the PolygonChunk::_sfCullFace field.
const Int32getCullFace (void) const
 Get the value of the PolygonChunk::_sfCullFace field.
Int32getFrontFace (void)
 Get the value of the PolygonChunk::_sfFrontFace field.
const Int32getFrontFace (void) const
 Get the value of the PolygonChunk::_sfFrontFace field.
Int32getFrontMode (void)
 Get the value of the PolygonChunk::_sfFrontMode field.
const Int32getFrontMode (void) const
 Get the value of the PolygonChunk::_sfFrontMode field.
Int32getBackMode (void)
 Get the value of the PolygonChunk::_sfBackMode field.
const Int32getBackMode (void) const
 Get the value of the PolygonChunk::_sfBackMode field.
bool & getSmooth (void)
 Get the value of the PolygonChunk::_sfSmooth field.
const bool & getSmooth (void) const
 Get the value of the PolygonChunk::_sfSmooth field.
Real32getOffsetFactor (void)
 Get the value of the PolygonChunk::_sfOffsetFactor field.
const Real32getOffsetFactor (void) const
 Get the value of the PolygonChunk::_sfOffsetFactor field.
Real32getOffsetBias (void)
 Get the value of the PolygonChunk::_sfOffsetBias field.
const Real32getOffsetBias (void) const
 Get the value of the PolygonChunk::_sfOffsetBias field.
bool & getOffsetPoint (void)
 Get the value of the PolygonChunk::_sfOffsetPoint field.
const bool & getOffsetPoint (void) const
 Get the value of the PolygonChunk::_sfOffsetPoint field.
bool & getOffsetLine (void)
 Get the value of the PolygonChunk::_sfOffsetLine field.
const bool & getOffsetLine (void) const
 Get the value of the PolygonChunk::_sfOffsetLine field.
bool & getOffsetFill (void)
 Get the value of the PolygonChunk::_sfOffsetFill field.
const bool & getOffsetFill (void) const
 Get the value of the PolygonChunk::_sfOffsetFill field.
Int32getStipple (const UInt32 index)
 Get the value of the index element the PolygonChunk::_mfStipple field.
MFInt32getStipple (void)
 Get the PolygonChunk::_mfStipple field.
const MFInt32getStipple (void) const
 Get the PolygonChunk::_mfStipple field.
Field Set
*void setCullFace (const Int32 &value)
 Set the value of the PolygonChunk::_sfCullFace field.
void setFrontFace (const Int32 &value)
 Set the value of the PolygonChunk::_sfFrontFace field.
void setFrontMode (const Int32 &value)
 Set the value of the PolygonChunk::_sfFrontMode field.
void setBackMode (const Int32 &value)
 Set the value of the PolygonChunk::_sfBackMode field.
void setSmooth (const bool &value)
 Set the value of the PolygonChunk::_sfSmooth field.
void setOffsetFactor (const Real32 &value)
 Set the value of the PolygonChunk::_sfOffsetFactor field.
void setOffsetBias (const Real32 &value)
 Set the value of the PolygonChunk::_sfOffsetBias field.
void setOffsetPoint (const bool &value)
 Set the value of the PolygonChunk::_sfOffsetPoint field.
void setOffsetLine (const bool &value)
 Set the value of the PolygonChunk::_sfOffsetLine field.
void setOffsetFill (const bool &value)
 Set the value of the PolygonChunk::_sfOffsetFill field.
Binary Access
*virtual UInt32 getBinSize (const BitVector &whichField)
virtual void copyToBin (BinaryDataHandler &pMem, const BitVector &whichField)
virtual void copyFromBin (BinaryDataHandler &pMem, const BitVector &whichField)
Copy
*virtual FieldContainerPtr shallowCopy (void) const
Chunk Class Access
*UInt32 getClassId (void) const
virtual const StateChunkClassgetClass (void) const
Sync
*virtual void changed (BitVector whichField, UInt32 origin)
Output
*virtual void dump (UInt32 uiIndent=0, const BitVector bvFlags=0) const
State
*virtual void activate (DrawActionBase *action, UInt32 index=0)
virtual void changeFrom (DrawActionBase *action, StateChunk *old, UInt32 index=0)
virtual void deactivate (DrawActionBase *action, UInt32 index=0)
virtual bool isTransparent (void) const
Comparison
*virtual Real32 switchCost (StateChunk *chunk)
virtual bool operator< (const StateChunk &other) const
virtual bool operator== (const StateChunk &other) const
virtual bool operator!= (const StateChunk &other) const
Parents
*MFFieldContainerPtrgetParents (void)
const MFFieldContainerPtrgetParents (void) const
MFFieldContainerPtrgetMFParents (void)
void addParent (FieldContainerPtr parent)
void subParent (FieldContainerPtr parent)
Int32 findParent (FieldContainerPtr parent)
Parents
*SFBoolgetInternal (void)
const SFBoolgetInternal (void) const
SFBoolgetSFInternal (void)
void setInternal (bool bVal)
Get Instance Type Information
UInt32 getTypeId (void) const
UInt16 getGroupId (void) const
const Char8getTypeName (void) const
Generic Field Access *FieldgetField (UInt32 fieldId)
FieldgetField (const Char8 *fieldName)
Get Instance Type Information
UInt32 getTypeId (void) const
UInt16 getGroupId (void) const
const Char8getTypeName (void) const
Generic Field Access *FieldgetField (UInt32 fieldId)
FieldgetField (const Char8 *fieldName)

Static Public Member Functions

Class Get
*static FieldContainerTypegetClassType (void)
 access the type of the class
static UInt32 getClassTypeId (void)
 access the numerical type of the class
Construction
*static PolygonChunkPtr create (void)
 create a new instance of the class
static PolygonChunkPtr createEmpty (void)
 create an empty new instance of the class, do not copy the prototype
Static Chunk Class Access
*static UInt32 getStaticClassId (void)
static const StateChunkClassgetStaticClass (void)
Get Class Type Information
static UInt16 getClassGroupId (void)
Get Class Type Information
static UInt16 getClassGroupId (void)

Static Public Attributes

static const osg::BitVector CullFaceFieldMask
static const osg::BitVector FrontFaceFieldMask
static const osg::BitVector FrontModeFieldMask
static const osg::BitVector BackModeFieldMask
static const osg::BitVector SmoothFieldMask
static const osg::BitVector OffsetFactorFieldMask
static const osg::BitVector OffsetBiasFieldMask
static const osg::BitVector OffsetPointFieldMask
static const osg::BitVector OffsetLineFieldMask
static const osg::BitVector OffsetFillFieldMask
static const osg::BitVector StippleFieldMask
static const osg::BitVector MTInfluenceMask
static const BitVector InternalFieldMask = (1 << Attachment::InternalFieldId)
static const BitVector ParentsFieldMask = (1 << Attachment::ParentsFieldId)
static const BitVector NextFieldMask
CoredNodePtr helper
static const bool isNodeCore = false
CoredNodePtr helper
static const bool isNodeCore = false

Protected Member Functions

Constructors
PolygonChunkBase (void)
 PolygonChunkBase (const PolygonChunkBase &source)
Destructors
*virtual ~PolygonChunkBase (void)
Sync
*void executeSyncImpl (PolygonChunkBase *pOther, const BitVector &whichField)
virtual void executeSync (FieldContainer &other, const BitVector &whichField)
Sync
*void executeSyncImpl (StateChunkBase *pOther, const BitVector &whichField)
Sync
void executeSyncImpl (Attachment *pOther, const BitVector &whichField)
Sync
void executeSyncImpl (FieldContainer *pOther, const BitVector &whichField)
MT Destruction
*virtual void onDestroy (void)
MT Edit
template<class FieldTypeT>
*void beginEditX (const BitVector &whichField, FieldTypeT &field)
template<class FieldTypeT>
void endEditX (const BitVector &whichField, FieldTypeT &field)
MT Construction
*void onCreate (const FieldContainer *source=NULL)
void onCreateAspect (const FieldContainer *aspect0, const FieldContainer *source=NULL)
Sync
void executeSyncImpl (FieldContainer *pOther, const BitVector &whichField)
MT Edit
template<class FieldTypeT>
*void beginEditX (const BitVector &whichField, FieldTypeT &field)
template<class FieldTypeT>
void endEditX (const BitVector &whichField, FieldTypeT &field)
MT Construction
*void onCreate (const FieldContainer *source=NULL)
void onCreateAspect (const FieldContainer *aspect0, const FieldContainer *source=NULL)

Static Protected Member Functions

static void initMethod (void)
Create Fieldcontainer
template<class ObjectPtrT>
*static void newPtr (ObjectPtrT &result, const typename ObjectPtrT::StoredObjectType *prototypeP)
template<class ObjectPtrT>
static void newPtr (ObjectPtrT &result)
Create Fieldcontainer
template<class ObjectPtrT>
*static void newPtr (ObjectPtrT &result, const typename ObjectPtrT::StoredObjectType *prototypeP)
template<class ObjectPtrT>
static void newPtr (ObjectPtrT &result)

Protected Attributes

Fields
*SFInt32 _sfCullFace
SFInt32 _sfFrontFace
SFInt32 _sfFrontMode
SFInt32 _sfBackMode
SFBool _sfSmooth
SFReal32 _sfOffsetFactor
SFReal32 _sfOffsetBias
SFBool _sfOffsetPoint
SFBool _sfOffsetLine
SFBool _sfOffsetFill
MFInt32 _mfStipple
Fields
*SFBool _sfInternal
MFFieldContainerPtr _parents
Member
*UInt32 _shares
Member
*UInt32 _shares

Private Types

typedef StateChunk Inherited

Private Member Functions

void operator= (const PolygonChunkBase &source)

Static Private Attributes

static FieldDescription_desc []
 PolygonChunk description.
static FieldContainerType _type

Friends

class FieldContainer

Detailed Description

Definition at line 91 of file OSGPolygonChunkBase.h.


Member Typedef Documentation

typedef StateChunk osg::PolygonChunkBase::Inherited [private]
 

Reimplemented from osg::StateChunk.

Reimplemented in osg::PolygonChunk.

Definition at line 95 of file OSGPolygonChunkBase.h.

typedef PolygonChunkPtr osg::PolygonChunkBase::Ptr
 

Reimplemented from osg::StateChunkBase.

Definition at line 100 of file OSGPolygonChunkBase.h.


Member Enumeration Documentation

anonymous enum
 

Enumerator:
CullFaceFieldId 
FrontFaceFieldId 
FrontModeFieldId 
BackModeFieldId 
SmoothFieldId 
OffsetFactorFieldId 
OffsetBiasFieldId 
OffsetPointFieldId 
OffsetLineFieldId 
OffsetFillFieldId 
StippleFieldId 
NextFieldId 

Reimplemented from osg::Attachment.

Definition at line 102 of file OSGPolygonChunkBase.h.

00103     {
00104         CullFaceFieldId     = Inherited::NextFieldId,
00105         FrontFaceFieldId    = CullFaceFieldId     + 1,
00106         FrontModeFieldId    = FrontFaceFieldId    + 1,
00107         BackModeFieldId     = FrontModeFieldId    + 1,
00108         SmoothFieldId       = BackModeFieldId     + 1,
00109         OffsetFactorFieldId = SmoothFieldId       + 1,
00110         OffsetBiasFieldId   = OffsetFactorFieldId + 1,
00111         OffsetPointFieldId  = OffsetBiasFieldId   + 1,
00112         OffsetLineFieldId   = OffsetPointFieldId  + 1,
00113         OffsetFillFieldId   = OffsetLineFieldId   + 1,
00114         StippleFieldId      = OffsetFillFieldId   + 1,
00115         NextFieldId         = StippleFieldId      + 1
00116     };


Constructor & Destructor Documentation

PolygonChunkBase::PolygonChunkBase void   )  [protected]
 

Definition at line 283 of file OSGPolygonChunkBase.cpp.

00283                                        :
00284     _sfCullFace               (Int32(GL_NONE)), 
00285     _sfFrontFace              (Int32(GL_CCW)), 
00286     _sfFrontMode              (Int32(GL_FILL)), 
00287     _sfBackMode               (Int32(GL_FILL)), 
00288     _sfSmooth                 (bool(GL_FALSE)), 
00289     _sfOffsetFactor           (Real32(0)), 
00290     _sfOffsetBias             (Real32(0)), 
00291     _sfOffsetPoint            (bool(GL_FALSE)), 
00292     _sfOffsetLine             (bool(GL_FALSE)), 
00293     _sfOffsetFill             (bool(GL_FALSE)), 
00294     _mfStipple                (), 
00295     Inherited() 
00296 {
00297 }

PolygonChunkBase::PolygonChunkBase const PolygonChunkBase source  )  [protected]
 

Definition at line 303 of file OSGPolygonChunkBase.cpp.

00303                                                                  :
00304     _sfCullFace               (source._sfCullFace               ), 
00305     _sfFrontFace              (source._sfFrontFace              ), 
00306     _sfFrontMode              (source._sfFrontMode              ), 
00307     _sfBackMode               (source._sfBackMode               ), 
00308     _sfSmooth                 (source._sfSmooth                 ), 
00309     _sfOffsetFactor           (source._sfOffsetFactor           ), 
00310     _sfOffsetBias             (source._sfOffsetBias             ), 
00311     _sfOffsetPoint            (source._sfOffsetPoint            ), 
00312     _sfOffsetLine             (source._sfOffsetLine             ), 
00313     _sfOffsetFill             (source._sfOffsetFill             ), 
00314     _mfStipple                (source._mfStipple                ), 
00315     Inherited                 (source)
00316 {
00317 }

PolygonChunkBase::~PolygonChunkBase void   )  [protected, virtual]
 

Definition at line 321 of file OSGPolygonChunkBase.cpp.

00322 {
00323 }


Member Function Documentation

osg::FieldContainerType & osg::PolygonChunkBase::getClassType void   )  [inline, static]
 

Reimplemented from osg::StateChunkBase.

Definition at line 58 of file OSGPolygonChunkBase.inl.

References _type.

Referenced by create().

00059 {
00060     return _type; 
00061 } 

osg::UInt32 osg::PolygonChunkBase::getClassTypeId void   )  [inline, static]
 

Reimplemented from osg::StateChunkBase.

Definition at line 65 of file OSGPolygonChunkBase.inl.

References _type, and osg::TypeBase::getId().

00066 {
00067     return _type.getId(); 
00068 } 

FieldContainerType & PolygonChunkBase::getType void   )  [virtual]
 

Reimplemented from osg::StateChunkBase.

Definition at line 224 of file OSGPolygonChunkBase.cpp.

References _type.

00225 {
00226     return _type; 
00227 } 

const FieldContainerType & PolygonChunkBase::getType void   )  const [virtual]
 

Reimplemented from osg::StateChunkBase.

Definition at line 229 of file OSGPolygonChunkBase.cpp.

References _type.

00230 {
00231     return _type;
00232 } 

UInt32 PolygonChunkBase::getContainerSize void   )  const [virtual]
 

Reimplemented from osg::StateChunkBase.

Definition at line 244 of file OSGPolygonChunkBase.cpp.

00245 { 
00246     return sizeof(PolygonChunk); 
00247 }

SFInt32 * osg::PolygonChunkBase::getSFCullFace void   )  [inline]
 

Definition at line 101 of file OSGPolygonChunkBase.inl.

References _sfCullFace.

00102 {
00103     return &_sfCullFace;
00104 }

SFInt32 * osg::PolygonChunkBase::getSFFrontFace void   )  [inline]
 

Definition at line 108 of file OSGPolygonChunkBase.inl.

References _sfFrontFace.

00109 {
00110     return &_sfFrontFace;
00111 }

SFInt32 * osg::PolygonChunkBase::getSFFrontMode void   )  [inline]
 

Definition at line 115 of file OSGPolygonChunkBase.inl.

References _sfFrontMode.

00116 {
00117     return &_sfFrontMode;
00118 }

SFInt32 * osg::PolygonChunkBase::getSFBackMode void   )  [inline]
 

Definition at line 122 of file OSGPolygonChunkBase.inl.

References _sfBackMode.

00123 {
00124     return &_sfBackMode;
00125 }

SFBool * osg::PolygonChunkBase::getSFSmooth void   )  [inline]
 

Definition at line 129 of file OSGPolygonChunkBase.inl.

References _sfSmooth.

00130 {
00131     return &_sfSmooth;
00132 }

SFReal32 * osg::PolygonChunkBase::getSFOffsetFactor void   )  [inline]
 

Definition at line 136 of file OSGPolygonChunkBase.inl.

References _sfOffsetFactor.

00137 {
00138     return &_sfOffsetFactor;
00139 }

SFReal32 * osg::PolygonChunkBase::getSFOffsetBias void   )  [inline]
 

Definition at line 143 of file OSGPolygonChunkBase.inl.

References _sfOffsetBias.

00144 {
00145     return &_sfOffsetBias;
00146 }

SFBool * osg::PolygonChunkBase::getSFOffsetPoint void   )  [inline]
 

Definition at line 150 of file OSGPolygonChunkBase.inl.

References _sfOffsetPoint.

00151 {
00152     return &_sfOffsetPoint;
00153 }

SFBool * osg::PolygonChunkBase::getSFOffsetLine void   )  [inline]
 

Definition at line 157 of file OSGPolygonChunkBase.inl.

References _sfOffsetLine.

00158 {
00159     return &_sfOffsetLine;
00160 }

SFBool * osg::PolygonChunkBase::getSFOffsetFill void   )  [inline]
 

Definition at line 164 of file OSGPolygonChunkBase.inl.

References _sfOffsetFill.

00165 {
00166     return &_sfOffsetFill;
00167 }

MFInt32 * osg::PolygonChunkBase::getMFStipple void   )  [inline]
 

Definition at line 171 of file OSGPolygonChunkBase.inl.

References _mfStipple.

00172 {
00173     return &_mfStipple;
00174 }

Int32 & osg::PolygonChunkBase::getCullFace void   )  [inline]
 

Definition at line 179 of file OSGPolygonChunkBase.inl.

References _sfCullFace, and osg::SField< FieldTypeT, fieldNameSpace >::getValue().

Referenced by osg::PolygonChunk::operator==().

00180 {
00181     return _sfCullFace.getValue();
00182 }

const Int32 & osg::PolygonChunkBase::getCullFace void   )  const [inline]
 

Definition at line 186 of file OSGPolygonChunkBase.inl.

References _sfCullFace, and osg::SField< FieldTypeT, fieldNameSpace >::getValue().

00187 {
00188     return _sfCullFace.getValue();
00189 }

Int32 & osg::PolygonChunkBase::getFrontFace void   )  [inline]
 

Definition at line 200 of file OSGPolygonChunkBase.inl.

References _sfFrontFace, and osg::SField< FieldTypeT, fieldNameSpace >::getValue().

Referenced by osg::PolygonChunk::operator==().

00201 {
00202     return _sfFrontFace.getValue();
00203 }

const Int32 & osg::PolygonChunkBase::getFrontFace void   )  const [inline]
 

Definition at line 207 of file OSGPolygonChunkBase.inl.

References _sfFrontFace, and osg::SField< FieldTypeT, fieldNameSpace >::getValue().

00208 {
00209     return _sfFrontFace.getValue();
00210 }

Int32 & osg::PolygonChunkBase::getFrontMode void   )  [inline]
 

Definition at line 221 of file OSGPolygonChunkBase.inl.

References _sfFrontMode, and osg::SField< FieldTypeT, fieldNameSpace >::getValue().

Referenced by osg::PolygonChunk::operator==().

00222 {
00223     return _sfFrontMode.getValue();
00224 }

const Int32 & osg::PolygonChunkBase::getFrontMode void   )  const [inline]
 

Definition at line 228 of file OSGPolygonChunkBase.inl.

References _sfFrontMode, and osg::SField< FieldTypeT, fieldNameSpace >::getValue().

00229 {
00230     return _sfFrontMode.getValue();
00231 }

Int32 & osg::PolygonChunkBase::getBackMode void   )  [inline]
 

Definition at line 242 of file OSGPolygonChunkBase.inl.

References _sfBackMode, and osg::SField< FieldTypeT, fieldNameSpace >::getValue().

Referenced by osg::PolygonChunk::operator==().

00243 {
00244     return _sfBackMode.getValue();
00245 }

const Int32 & osg::PolygonChunkBase::getBackMode void   )  const [inline]
 

Definition at line 249 of file OSGPolygonChunkBase.inl.

References _sfBackMode, and osg::SField< FieldTypeT, fieldNameSpace >::getValue().

00250 {
00251     return _sfBackMode.getValue();
00252 }

bool & osg::PolygonChunkBase::getSmooth void   )  [inline]
 

Definition at line 263 of file OSGPolygonChunkBase.inl.

References _sfSmooth, and