OSG::Algorithm Class Reference

#include <OSGAlgorithm.h>

Inheritance diagram for OSG::Algorithm:

OSG::AlgorithmBase OSG::FieldContainer OSG::ReflexiveContainer List of all members.

Type definitions



 OSG_GEN_INTERNALPTR (FieldContainer)
 OSG_RC_FIRST_FIELD_DECL (ChangedCallbacks)
 OSG_RC_LAST_FIELD_DECL (ChangedCallbacks)
typedef FieldContainer Self
static const bool isNodeCore = false

Public Types

typedef FieldContainer ParentContainer
typedef Inherited::TypeObject TypeObject
typedef TypeObject::InitPhase InitPhase
Type definitions


typedef Field *(ReflexiveContainer::*) FieldEditMethod (void)
typedef const Field *(ReflexiveContainer::*) FieldGetMethod (void) const

Public Member Functions

 OSG_GEN_INTERNALPTR (Algorithm)
Sync


virtual void changed (ConstFieldMaskArg whichField, UInt32 origin, BitVector detail)
Execute


virtual void execute (DrawEnv *)=0
Dump


virtual void dump (UInt32 uiIndent=0, const BitVector bvFlags=0) const
FieldContainer Get


virtual FieldContainerTypegetType (void)
virtual const FieldContainerTypegetType (void) const
virtual UInt32 getContainerSize (void) const
Binary Access


virtual UInt32 getBinSize (ConstFieldMaskArg whichField)
virtual void copyToBin (BinaryDataHandler &pMem, ConstFieldMaskArg whichField)
virtual void copyFromBin (BinaryDataHandler &pMem, ConstFieldMaskArg whichField)
Get


virtual ObjPtr shallowCopy (void) const=0
Set


void callChangedFunctors (ConstFieldMaskArg whichField)
Container Access


UInt32 addChangedFunctor (ChangedFunctor func, std::string createSymbol)
template<class FunctorT>
void subChangedFunctor (FunctorT func)
void subChangedFunctor (UInt32 uiId)
void clearChangedFunctors (void)
Field Flags


const FieldFlagsgetFieldFlags (void)
Helper


OSG_SYSTEM_DLLMAPPING void addReference (void)
OSG_SYSTEM_DLLMAPPING void subReference (void)
OSG_SYSTEM_DLLMAPPING void subReferenceLocalVar (void)
OSG_SYSTEM_DLLMAPPING Int32 getRefCount (void) const
Comparison


virtual OSG_SYSTEM_DLLMAPPING
void 
invalidateVolume (void)
dcast


OSG_SYSTEM_DLLMAPPING UInt32 getTypeId (void) const
OSG_SYSTEM_DLLMAPPING UInt16 getGroupId (void) const
OSG_SYSTEM_DLLMAPPING const
Char8 * 
getTypeName (void) const
Get Field


OSG_SYSTEM_DLLMAPPING UInt32 getNumFields (void) const
OSG_SYSTEM_DLLMAPPING EditFieldHandlePtr editField (UInt32 fieldId)
OSG_SYSTEM_DLLMAPPING EditFieldHandlePtr editField (const Char8 *fieldName)
OSG_SYSTEM_DLLMAPPING GetFieldHandlePtr getField (UInt32 fieldId) const
OSG_SYSTEM_DLLMAPPING GetFieldHandlePtr getField (const Char8 *fieldName) const
Get Field Description


OSG_SYSTEM_DLLMAPPING FieldDescriptionBasegetFieldDescription (UInt32 fieldId)
OSG_SYSTEM_DLLMAPPING FieldDescriptionBasegetFieldDescription (const Char8 *fieldName)
Comparison


OSG_SYSTEM_DLLMAPPING EditFieldHandlePtr invalidEditField (void)
OSG_SYSTEM_DLLMAPPING GetFieldHandlePtr invalidGetField (void) const

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
static UInt16 getClassGroupId (void)
 access the type of the class

Static Public Attributes

Constants


static const UInt32 NextFieldId = 1
static const BitVector NextFieldMask = 0x01

Protected Types

typedef AlgorithmBase Inherited

Protected Member Functions

Constructors


 Algorithm (void)
 Algorithm (const Algorithm &source)
Destructors


virtual ~Algorithm (void)
Sync


virtual void resolveLinks (void)
Edit


OSG_SYSTEM_DLLMAPPING void subReferenceUnresolved (void)
MT Construction


OSG_SYSTEM_DLLMAPPING void onCreateAspect (const FieldContainer *createAspect, const FieldContainer *source=NULL)
OSG_SYSTEM_DLLMAPPING void onCreate (const FieldContainer *source=NULL)
virtual OSG_SYSTEM_DLLMAPPING
void 
onDestroy (UInt32 uiContainerId)
Changed


OSG_SYSTEM_DLLMAPPING void onCreate (const ReflexiveContainer *source=NULL)
virtual OSG_SYSTEM_DLLMAPPING
void 
onDestroyAspect (UInt32 uiContainerId, UInt32 uiAspect)
MT Construction


virtual OSG_SYSTEM_DLLMAPPING
bool 
deregister (UInt32 uiContainerId)
MT Construction


OSG_SYSTEM_DLLMAPPING void registerChangedContainer (void)
virtual OSG_SYSTEM_DLLMAPPING
void 
registerChangedContainerV (void)
Local Edit


void editSField (ConstFieldMaskArg whichField)
template<class FieldT>
void editMField (ConstFieldMaskArg whichField, FieldT &oField)
MT Destruction


void execEndEdit (ConstFieldMaskArg whichField)
void clearChangeEntry (ContainerChangeEntry *pRef)
Edit


OSG_SYSTEM_DLLMAPPING void setId (UInt32 uiContainerId)
OSG_SYSTEM_DLLMAPPING UInt32 getId (void) const

Static Protected Member Functions

static void classDescInserter (TypeObject &oType)
static Char8 * getClassname (void)
Init


static void initMethod (InitPhase ePhase)
Fields


static void classDescInserter (TypeObject &oType)
MT Construction


template<class ObjectT>
static void newPtr (typename ObjectT::ObjPtr &result, const ObjectT *prototypeP)
template<class ObjectT>
static void newPtr (typename ObjectT::ObjPtr &result)

Protected Attributes

Type information


FieldFlags_pFieldFlags
MFChangedFunctorCallback _mfChangedFunctors
Int32 _iRefCount
Member


BitVector _bvChanged
ContainerChangeEntry_pContainerChanges
UInt32 _uiContainerId

Static Protected Attributes

static TypeObject _type

Private Member Functions

void operator= (const Algorithm &source)
 prohibit default function (move to 'public' if needed)

Friends

class FieldContainer
class AlgorithmBase

Detailed Description

Stage

Definition at line 56 of file OSGAlgorithm.h.


Member Typedef Documentation

Reimplemented from OSG::AlgorithmBase.

Definition at line 89 of file OSGAlgorithm.h.

Definition at line 82 of file OSGAlgorithmBase.h.

Reimplemented from OSG::FieldContainer.

Definition at line 84 of file OSGAlgorithmBase.h.

Reimplemented from OSG::ReflexiveContainer.

Definition at line 85 of file OSGAlgorithmBase.h.

typedef Field*(ReflexiveContainer::*) OSG::ReflexiveContainer::FieldEditMethod(void) [inherited]

Definition at line 79 of file OSGReflexiveContainer.h.

typedef const Field*(ReflexiveContainer::*) OSG::ReflexiveContainer::FieldGetMethod(void) const [inherited]

Definition at line 81 of file OSGReflexiveContainer.h.


Constructor & Destructor Documentation

Algorithm::Algorithm ( void   )  [protected]

Definition at line 118 of file OSGAlgorithm.cpp.

00118                          :
00119     Inherited()
00120 {
00121 }

Algorithm::Algorithm ( const Algorithm source  )  [protected]

Definition at line 123 of file OSGAlgorithm.cpp.

00123                                             :
00124     Inherited(source)
00125 {
00126 }

Algorithm::~Algorithm ( void   )  [protected, virtual]

Definition at line 131 of file OSGAlgorithm.cpp.

00132 {
00133 }


Member Function Documentation

void Algorithm::changed ( ConstFieldMaskArg  whichField,
UInt32  origin,
BitVector  detail 
) [virtual]

Reimplemented from OSG::FieldContainer.

Definition at line 68 of file OSGAlgorithm.cpp.

References OSG::FieldContainer::changed(), OSG::PathHandler::findFile(), OSG::FieldContainer::invalidateVolume(), and OSG::SingletonHolder< SingletonT >::the().

00071 {
00072 #if 0
00073     if(whichField & (UrlFieldMask))
00074     {
00075         if(getAbsoluteUrl().empty())
00076         {
00077             PathHandler *ph = SceneFileHandler::the()->getPathHandler();
00078 
00079             if(ph != NULL) 
00080             {
00081                 setAbsoluteUrl(ph->findFile(getUrl().c_str()));
00082             }
00083 
00084             if(getAbsoluteUrl().empty())
00085             {
00086                 setAbsoluteUrl(getUrl());
00087             }
00088 
00089             setState(NOT_LOADED);
00090         }
00091     }
00092     if(whichField & (StateFieldMask |
00093                      UrlFieldMask   |
00094                      VolumeFieldMask))
00095     {
00096         for(UInt32 i = 0; i < _mfParents.size(); i++)
00097         {
00098             _mfParents[i]->invalidateVolume();
00099         }
00100     }
00101 #endif
00102 
00103     Inherited::changed(whichField, origin, details);
00104 }

virtual void OSG::Algorithm::execute ( DrawEnv  )  [pure virtual]

virtual void OSG::Algorithm::dump ( UInt32  uiIndent = 0,
const BitVector  bvFlags = 0 
) const [virtual]

Reimplemented from OSG::FieldContainer.

void Algorithm::initMethod ( InitPhase  ePhase  )  [static, protected]

Reimplemented from OSG::FieldContainer.

Definition at line 145 of file OSGAlgorithm.cpp.

References OSG::FieldContainer::initMethod(), and OSG::TypeBase::SystemPost.

00146 {
00147     Inherited::initMethod(ePhase);
00148 
00149     if(ePhase == TypeObject::SystemPost)
00150     {
00151     }
00152 }

void OSG::Algorithm::operator= ( const Algorithm source  )  [private]

OSG::AlgorithmBase::OSG_GEN_INTERNALPTR ( Algorithm   )  [inherited]

OSG::FieldContainer::OSG_GEN_INTERNALPTR ( FieldContainer   )  [inherited]

OSG::FieldContainerType & OSG::AlgorithmBase::getClassType ( void   )  [inline, static, inherited]

Reimplemented from OSG::FieldContainer.

Definition at line 56 of file OSGAlgorithmBase.inl.

References OSG::AlgorithmBase::_type.

00057 {
00058     return _type;
00059 }

OSG::UInt32 OSG::AlgorithmBase::getClassTypeId ( void   )  [inline, static, inherited]

Reimplemented from OSG::FieldContainer.

Definition at line 63 of file OSGAlgorithmBase.inl.

References OSG::AlgorithmBase::_type, and OSG::TypeBase::getId().

00064 {
00065     return _type.getId();
00066 }

OSG::UInt16 OSG::AlgorithmBase::getClassGroupId ( void   )  [inline, static, inherited]

Reimplemented from OSG::FieldContainer.

Definition at line 69 of file OSGAlgorithmBase.inl.

References OSG::AlgorithmBase::_type, and OSG::ReflexiveContainerType::getGroupId().

00070 {
00071     return _type.getGroupId();
00072 }

FieldContainerType & OSG::AlgorithmBase::getType ( void   )  [virtual, inherited]

Reimplemented from OSG::FieldContainer.

Definition at line 111 of file OSGAlgorithmBase.cpp.

References OSG::AlgorithmBase::_type.

00112 {
00113     return _type;
00114 }

const FieldContainerType & OSG::AlgorithmBase::getType ( void   )  const [virtual, inherited]

Reimplemented from OSG::FieldContainer.

Definition at line 116 of file OSGAlgorithmBase.cpp.

References OSG::AlgorithmBase::_type.

00117 {
00118     return _type;
00119 }

UInt32 OSG::AlgorithmBase::getContainerSize ( void   )  const [virtual, inherited]

Implements OSG::ReflexiveContainer.

Definition at line 121 of file OSGAlgorithmBase.cpp.

00122 {
00123     return sizeof(Algorithm);
00124 }

UInt32 OSG::AlgorithmBase::getBinSize ( ConstFieldMaskArg  whichField  )  [virtual, inherited]

Reimplemented from OSG::ReflexiveContainer.

Definition at line 135 of file OSGAlgorithmBase.cpp.

References OSG::ReflexiveContainer::getBinSize().

00136 {
00137     UInt32 returnValue = Inherited::getBinSize(whichField);
00138 
00139 
00140     return returnValue;
00141 }

void OSG::AlgorithmBase::copyToBin ( BinaryDataHandler pMem,
ConstFieldMaskArg  whichField 
) [virtual, inherited]

Reimplemented from OSG::ReflexiveContainer.

Definition at line 143 of file OSGAlgorithmBase.cpp.

References OSG::ReflexiveContainer::copyToBin().

00145 {
00146     Inherited::copyToBin(pMem, whichField);
00147 
00148 }

void OSG::AlgorithmBase::copyFromBin ( BinaryDataHandler pMem,
ConstFieldMaskArg  whichField 
) [virtual, inherited]

Reimplemented from OSG::FieldContainer.

Definition at line 150 of file OSGAlgorithmBase.cpp.

References OSG::FieldContainer::copyFromBin().

00152 {
00153     Inherited::copyFromBin(pMem, whichField);
00154 
00155 }

static void OSG::AlgorithmBase::classDescInserter ( TypeObject oType  )  [static, protected, inherited]

void OSG::FieldContainer::classDescInserter ( TypeObject oType  )  [static, protected, inherited]

Reimplemented in OSG::PolygonChunkBase, OSG::ClipPlaneChunkBase, OSG::TransformChunkBase, OSG::ShaderParameterChunkBase, OSG::SHLParameterChunkBase, OSG::ProgramChunkBase, OSG::FragmentProgramChunkBase, OSG::TexGenChunkBase, OSG::MaterialChunkBase, OSG::TextureEnvChunkBase, OSG::LightChunkBase, OSG::TextureObjChunkBase, OSG::StringAttributeMapBase, OSG::ContainerPoolBase, OSG::TypedGeoIntegralProperty< GeoPropertyDesc >, OSG::GeoPropertyBase, and OSG::GeoVectorPropertyBase.

Definition at line 58 of file OSGFieldContainer.cpp.

References OSG::ReflexiveContainerType::addInitialDesc(), OSG::ReflexiveContainer::invalidEditField(), OSG::ReflexiveContainer::invalidGetField(), OSG_RC_FIELD_DESC, and OSG::Field::SFDefaultFlags.

00059 {
00060     FieldDescriptionBase *pDesc = NULL;
00061 
00062     pDesc = new MFChangedFunctorCallback::Description(
00063         MFChangedFunctorCallback::getClassType(),
00064         "changedCallbacks",
00065         "List of callback functors to notify of changes.",
00066         OSG_RC_FIELD_DESC(FieldContainer::ChangedCallbacks),
00067         false,
00068         Field::SFDefaultFlags,
00069         static_cast<FieldEditMethodSig>(&FieldContainer::invalidEditField),
00070         static_cast<FieldGetMethodSig >(&FieldContainer::invalidGetField ));
00071 
00072     oType.addInitialDesc(pDesc);
00073 }

Char8 * OSG::AlgorithmBase::getClassname ( void   )  [inline, static, protected, inherited]

Reimplemented from OSG::FieldContainer.

Definition at line 92 of file OSGAlgorithmBase.inl.

00093 {
00094     return "Algorithm";
00095 }

void OSG::AlgorithmBase::resolveLinks ( void   )  [protected, virtual, inherited]

Reimplemented from OSG::FieldContainer.

Definition at line 198 of file OSGAlgorithmBase.cpp.

References OSG::FieldContainer::resolveLinks().

00199 {
00200     Inherited::resolveLinks();
00201 
00202 
00203 }

OSG::FieldContainer::OSG_RC_FIRST_FIELD_DECL ( ChangedCallbacks   )  [inherited]

OSG::FieldContainer::OSG_RC_LAST_FIELD_DECL ( ChangedCallbacks   )  [inherited]

virtual ObjPtr OSG::FieldContainer::shallowCopy ( void   )  const [pure virtual, inherited]

Implemented in OSG::RotateManipulatorBase, OSG::MoveManipulatorBase, OSG::ScaleManipulatorBase, OSG::LineChunkBase, OSG::TwoSidedLightingChunkBase, OSG::PointChunkBase, OSG::PolygonChunkBase, OSG::ColorMaskChunkBase, OSG::CubeTextureObjChunkBase, OSG::TextureTransformChunkBase, OSG::StencilChunkBase, OSG::DepthChunkBase, OSG::ClipPlaneChunkBase, OSG::TransformChunkBase, OSG::SHLChunkBase, OSG::SHLParameterChunkBase, OSG::ShaderParameterMatrixBase, OSG::ShaderParameterVec2fBase, OSG::ShaderParameterMVec4fBase, OSG::ShaderParameterIntBase, OSG::ShaderParameterMRealBase, OSG::ShaderParameterMIntBase, OSG::ShaderParameterMVec3fBase, OSG::ShaderParameterBoolBase, OSG::ShaderParameterVec4fBase, OSG::ShaderParameterMVec2fBase, OSG::ShaderParameterStringBase, OSG::ShaderParameterVec3fBase, OSG::ShaderParameterMMatrixBase, OSG::ShaderParameterRealBase, OSG::TextureSelectChunkBase, OSG::TextureObjRefChunkBase, OSG::RegisterCombinersChunkBase, OSG::VertexProgramChunkBase, OSG::FragmentProgramChunkBase, OSG::SimpleShadowMapEngineBase, OSG::ScreenLODBase, OSG::TextureBackgroundBase, OSG::PassiveBackgroundBase, OSG::DepthClearBackgroundBase, OSG::PolygonBackgroundBase, OSG::TextureGrabBackgroundBase, OSG::SkyBackgroundBase, OSG::GradientBackgroundBase, OSG::SolidBackgroundBase, OSG::StereoBufferViewportBase, OSG::ColorBufferViewportBase, OSG::PassiveViewportBase, OSG::ProjectionCameraDecoratorBase, OSG::PerspectiveCameraBase, OSG::OrthographicCameraBase, OSG::OffCenterPerspectiveCameraBase, OSG::TileCameraDecoratorBase, OSG::MatrixCameraBase, OSG::MatrixCameraDecoratorBase, OSG::ShearedStereoCameraDecoratorBase, OSG::TextureGrabForegroundBase, OSG::FileGrabForegroundBase, OSG::GrabForegroundBase, OSG::ImageForegroundBase, OSG::PolygonForegroundBase, OSG::GLUTWindowBase, OSG::AlgorithmStageBase, OSG::SimpleStageBase, OSG::StageBase, OSG::DirectionalLightBase, OSG::SpotLightBase, OSG::PointLightBase, OSG::DistanceLODBase, OSG::SwitchBase, OSG::InverseTransformBase, OSG::TransformBase, OSG::VisitSubTreeBase, OSG::BillboardBase, OSG::ComponentTransformBase, OSG::InlineBase, OSG::ProxyGroupBase, OSG::MultiCoreBase, OSG::HDRStageBase, OSG::XWindowBase, OSG::SimpleStatisticsForegroundBase, OSG::MultiDisplayWindowBase, OSG::ClusterWindowBase, OSG::SortFirstWindowBase, OSG::BinarySwapComposerBase, OSG::ParallelComposerBase, OSG::SepiaComposerBase, OSG::SortLastWindowBase, OSG::PipelineComposerBase, OSG::BalancedMultiWindowBase, OSG::TexGenChunkBase, OSG::MaterialChunkBase, OSG::TextureEnvChunkBase, OSG::LightChunkBase, OSG::StateBase, OSG::BlendChunkBase, OSG::TextureObjChunkBase, OSG::GroupBase, OSG::MaterialGroupBase, OSG::LightEnvBase, OSG::ChunkOverrideGroupBase, OSG::ImageBase, OSG::StringAttributeMapBase, OSG::ContainerPoolBase, OSG::ViewportBase, OSG::RenderOptionsBase, OSG::PassiveWindowBase, OSG::TextureBufferBase, OSG::FBOViewportBase, OSG::RenderBufferBase, OSG::FrameBufferObjectBase, OSG::CubeTextureChunkBase, OSG::TextureChunkBase, OSG::SimpleTexturedMaterialBase, OSG::SimpleMaterialBase, OSG::ChunkMaterialBase, OSG::MultiPassMaterialBase, OSG::SwitchMaterialBase, OSG::QuadTreeTerrainBase, OSG::TiledQuadTreeTerrainBase, OSG::ParticlesBase, OSG::GeometryBase, OSG::GeoMultiPropertyDataBase, OSG::GeoMultiPropertyBase, and OSG::GeoStatsAttachmentBase.

void OSG::FieldContainer::callChangedFunctors ( ConstFieldMaskArg  whichField  )  [inline, inherited]

Definition at line 73 of file OSGFieldContainer.inl.

References OSG::FieldContainer::_mfChangedFunctors.

Referenced by OSG::FieldContainer::changed(), and OSG::FieldContainer::resolveLinks().

00074 {
00075     MFChangedFunctorCallback::iterator       cfIt = _mfChangedFunctors.begin();
00076     MFChangedFunctorCallback::const_iterator cfEnd= _mfChangedFunctors.end();
00077 
00078     while(cfIt != cfEnd)
00079     {
00080         if(cfIt->_func)
00081             (cfIt->_func)(this, whichField);
00082 
00083         ++cfIt;
00084     }
00085 }

UInt32 OSG::FieldContainer::addChangedFunctor ( ChangedFunctor  func,
std::string  createSymbol 
) [inline, inherited]

Definition at line 232 of file OSGFieldContainer.inl.

References OSG::ChangedFunctorCallback::_createSymbol, OSG::ChangedFunctorCallback::_func, OSG::FieldContainer::_mfChangedFunctors, and OSG::ChangedFunctorCallback::_uiId.

00234 {
00235     ChangedFunctorCallback oTmp;
00236 
00237     oTmp._func         = func;
00238     oTmp._uiId         = _mfChangedFunctors.size();
00239     oTmp._createSymbol = createSymbol;
00240 
00241     _mfChangedFunctors.push_back(oTmp);
00242 
00243     return oTmp._uiId;
00244 }

template<class FunctorT>
void OSG::FieldContainer::subChangedFunctor ( FunctorT  func  )  [inline, inherited]

Definition at line 247 of file OSGFieldContainer.inl.

References OSG::FieldContainer::_mfChangedFunctors.

00248 {
00249     MFChangedFunctorCallback::iterator       cfIt = _mfChangedFunctors.begin();
00250     MFChangedFunctorCallback::const_iterator cfEnd= _mfChangedFunctors.end();
00251 
00252     while(cfIt != cfEnd)
00253     {
00254         if(cfIt->_func == func)
00255             break;
00256 
00257         ++cfIt;
00258     }
00259 
00260     if(cfIt != cfEnd)
00261         _mfChangedFunctors.erase(cfIt);
00262 }

void OSG::FieldContainer::subChangedFunctor ( UInt32  uiId  )  [inline, inherited]

Definition at line 265 of file OSGFieldContainer.inl.

References OSG::FieldContainer::_mfChangedFunctors.

00266 {
00267     MFChangedFunctorCallback::iterator       cfIt = _mfChangedFunctors.begin();
00268     MFChangedFunctorCallback::const_iterator cfEnd= _mfChangedFunctors.end();
00269 
00270     while(cfIt != cfEnd)
00271     {
00272         if(cfIt->_uiId == uiId)
00273             break;
00274 
00275         ++cfIt;
00276     }
00277 
00278     if(cfIt != cfEnd)
00279         _mfChangedFunctors.erase(cfIt);
00280 }

void OSG::FieldContainer::clearChangedFunctors ( void   )  [inline, inherited]

Definition at line 283 of file OSGFieldContainer.inl.

References OSG::FieldContainer::_mfChangedFunctors.

00284 {
00285     _mfChangedFunctors.clear();
00286 }

const FieldFlags * OSG::FieldContainer::getFieldFlags ( void   )  [inline, inherited]

Definition at line 289 of file OSGFieldContainer.inl.

References OSG::FieldContainer::_pFieldFlags.

00290 {
00291     return _pFieldFlags;
00292 }

void OSG::FieldContainer::addReference ( void   )  [inline, inherited]

void OSG::FieldContainer::subReference ( void   )  [inline, inherited]

Definition at line 97 of file OSGFieldContainer.inl.

References OSG::FieldContainer::_iRefCount, OSG::ChangeList::addSubRefd(), OSG::ChangeList::decSubRefLevel(), OSG::FieldContainer::deregister(), OSG::Thread::getCurrentAspect(), OSG::Thread::getCurrentChangeList(), OSG::ReflexiveContainer::getId(), OSG::ChangeList::incSubRefLevel(), OSG::FieldContainer::onDestroy(), OSG::ReflexiveContainer::onDestroyAspect(), OSG::FieldContainer::resolveLinks(), and OSG::subRef().

00098 {
00099     --_iRefCount;
00100 
00101     if(_iRefCount <= 0)
00102     {
00103         Thread::getCurrentChangeList()->incSubRefLevel();
00104 
00105         this->resolveLinks();
00106 
00107         Thread::getCurrentChangeList()->decSubRefLevel();
00108 
00109         Thread::getCurrentChangeList()->addSubRefd(Inherited::getId());
00110 
00111 #ifdef OSG_MT_CPTR_ASPECT
00112         this->onDestroyAspect(Inherited::getId(), Thread::getCurrentAspect());
00113 
00114         _pAspectStore->removePtrForAspect(Thread::getCurrentAspect());
00115 
00116         if(_pAspectStore->getRefCount() == 1)
00117         {
00118             this->deregister(Inherited::getId());
00119             this->onDestroy (Inherited::getId());
00120         }
00121 
00122         OSG::subRef(_pAspectStore);
00123 #else
00124         this->deregister     (Inherited::getId()   );
00125         this->onDestroyAspect(Inherited::getId(), 0);
00126         this->onDestroy      (Inherited::getId()   );
00127 #endif
00128 
00129         delete this;
00130     }
00131     else
00132     {
00133         Thread::getCurrentChangeList()->addSubRefd(Inherited::getId());
00134     }
00135 
00136 }

void OSG::FieldContainer::subReferenceLocalVar ( void   )  [inline, inherited]

Definition at line 140 of file OSGFieldContainer.inl.

References OSG::FieldContainer::_iRefCount, OSG::ChangeList::addSubRefd(), OSG::ChangeList::decSubRefLevel(), OSG::FieldContainer::deregister(), OSG::Thread::getCurrentAspect(), OSG::Thread::getCurrentChangeList(), OSG::ReflexiveContainer::getId(), OSG::ChangeList::incSubRefLevel(), OSG::FieldContainer::onDestroy(), OSG::ReflexiveContainer::onDestroyAspect(), OSG::FieldContainer::resolveLinks(), and OSG::subRef().

00141 {
00142     --_iRefCount;
00143 
00144     if(_iRefCount <= 0)
00145     {
00146 
00147         Thread::getCurrentChangeList()->incSubRefLevel();
00148 
00149         this->resolveLinks();
00150 
00151         Thread::getCurrentChangeList()->decSubRefLevel();
00152 
00153         Thread::getCurrentChangeList()->addSubRefd(Inherited::getId(),
00154                                                    true);
00155 
00156 #ifdef OSG_MT_CPTR_ASPECT
00157         this->onDestroyAspect(Inherited::getId(), Thread::getCurrentAspect());
00158 
00159         _pAspectStore->removePtrForAspect(Thread::getCurrentAspect());
00160 
00161         if(_pAspectStore->getRefCount() == 1)
00162         {
00163             this->deregister(Inherited::getId());
00164             this->onDestroy (Inherited::getId());
00165         }
00166 
00167         OSG::subRef(_pAspectStore);
00168 #else
00169         this->deregister     (Inherited::getId()   );
00170         this->onDestroyAspect(Inherited::getId(), 0);
00171         this->onDestroy      (Inherited::getId()   );
00172 #endif
00173 
00174         delete this;
00175     }
00176     else
00177     {
00178         Thread::getCurrentChangeList()->addSubRefd(Inherited::getId());
00179     }
00180 
00181 }

Int32 OSG::FieldContainer::getRefCount ( void   )  const [inline, inherited]

Definition at line 184 of file OSGFieldContainer.inl.

References OSG::FieldContainer::_iRefCount.

00185 {
00186     return _iRefCount;
00187 }

void OSG::FieldContainer::invalidateVolume ( void   )  [virtual, inherited]

Reimplemented in OSG::Node, and OSG::NodeCore.

Definition at line 115 of file OSGFieldContainer.cpp.

Referenced by changed().

00116 {
00117 }