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

osg::ImageComposer Class Reference
[Cluster]

Cluster image composition implementation. More...

#include <OSGImageComposer.h>

Inheritance diagram for osg::ImageComposer:

osg::ImageComposerBase osg::AttachmentContainer osg::FieldContainer List of all members.

Public Types

typedef ImageComposerPtr Ptr
enum  { EnabledFieldId = Inherited::NextFieldId, StatisticsFieldId = EnabledFieldId + 1, NextFieldId = StatisticsFieldId + 1 }

Public Member Functions

Sync
*virtual void changed (BitVector whichField, UInt32 origin)
Output
*virtual void dump (UInt32 uiIndent=0, const BitVector bvFlags=0) const
setup
*void setup (bool isClient, UInt32 clusterId, WindowPtr localWindow, ClusterWindowPtr clusterWindow)
composition
*virtual void open (void)
virtual void composeViewport (ViewportPtr port)
virtual void composeWindow (void)
virtual void close (void)
features
*virtual bool getClientRendering (void)
virtual UInt32 getUsableServers (void)
FieldContainer Get
*virtual FieldContainerTypegetType (void)
virtual const FieldContainerTypegetType (void) const
virtual UInt32 getContainerSize (void) const
Field Get
*SFBoolgetSFEnabled (void)
 Get the ImageComposer::_sfEnabled field.
SFBoolgetSFStatistics (void)
 Get the ImageComposer::_sfStatistics field.
bool & getEnabled (void)
 Get the value of the ImageComposer::_sfEnabled field.
const bool & getEnabled (void) const
 Get the value of the ImageComposer::_sfEnabled field.
bool & getStatistics (void)
 Get the value of the ImageComposer::_sfStatistics field.
const bool & getStatistics (void) const
 Get the value of the ImageComposer::_sfStatistics field.
Field Set
*void setEnabled (const bool &value)
 Set the value of the ImageComposer::_sfEnabled field.
void setStatistics (const bool &value)
 Set the value of the ImageComposer::_sfStatistics 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)
Clone
*virtual FieldContainerPtr shallowCopy (void) const =0

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 Public Attributes

static const osg::BitVector EnabledFieldMask
static const osg::BitVector StatisticsFieldMask
static const osg::BitVector MTInfluenceMask
static const BitVector AttachmentsFieldMask
static const BitVector NextFieldMask

Protected Member Functions

MT Destruction
*virtual void onDestroy (void)
MT Destruction
*virtual void onDestroy (void)
get
*bool isClient (void)
UInt32 clusterId (void)
UInt32 clusterSize (void)
UInt32 serverCount (void)
WindowPtr localWindow (void)
ClusterWindowPtr clusterWindow (void)
helpers
*bool getScreenAlignedBBox (NodePtr root, ViewportPtr vp, UInt32 &l, UInt32 &b, UInt32 &r, UInt32 &t, UInt32 &front, UInt32 &back)
Constructors
ImageComposer (void)
 ImageComposer (const ImageComposer &source)
Destructors
*virtual ~ImageComposer (void)
Sync
*void executeSyncImpl (ImageComposerBase *pOther, const BitVector &whichField)
virtual void executeSync (FieldContainer &other, const BitVector &whichField)
MT Destruction
*virtual void onDestroy (void)

Protected Attributes

protected variables
*bool _isClient
UInt32 _clusterId
UInt32 _clusterSize
UInt32 _serverCount
WindowPtr _localWindow
ClusterWindowPtr _clusterWindow
Fields
*SFBool _sfEnabled
SFBool _sfStatistics

Private Types

typedef ImageComposerBase Inherited

Private Member Functions

void operator= (const ImageComposer &source)

Static Private Member Functions

static void initMethod (void)

Friends

class FieldContainer
class ImageComposerBase

Detailed Description

An ImageComposer class is used to compose multiple images into a final image. Each cluster server produces one part of the image. This class is abstract. Derived classes should implement composition over network or other cluster interconnects.

Definition at line 54 of file OSGImageComposer.h.


Member Typedef Documentation

typedef ImageComposerBase osg::ImageComposer::Inherited [private]
 

Reimplemented from osg::ImageComposerBase.

Definition at line 58 of file OSGImageComposer.h.

typedef ImageComposerPtr osg::ImageComposerBase::Ptr [inherited]
 

Definition at line 91 of file OSGImageComposerBase.h.


Member Enumeration Documentation

anonymous enum [inherited]
 

Enumerator:
EnabledFieldId 
StatisticsFieldId 
NextFieldId 

Reimplemented from osg::AttachmentContainer.

Definition at line 93 of file OSGImageComposerBase.h.

00094     {
00095         EnabledFieldId    = Inherited::NextFieldId,
00096         StatisticsFieldId = EnabledFieldId    + 1,
00097         NextFieldId       = StatisticsFieldId + 1
00098     };


Constructor & Destructor Documentation

ImageComposer::ImageComposer void   )  [protected]
 

Definition at line 82 of file OSGImageComposer.cpp.

00082                                  :
00083     Inherited()
00084 {
00085 }

ImageComposer::ImageComposer const ImageComposer source  )  [protected]
 

Definition at line 87 of file OSGImageComposer.cpp.

00087                                                         :
00088     Inherited(source)
00089 {
00090 }

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

Definition at line 92 of file OSGImageComposer.cpp.

00093 {
00094 }


Member Function Documentation

void ImageComposer::changed BitVector  whichField,
UInt32  origin
[virtual]
 

Reimplemented from osg::AttachmentContainer.

Definition at line 98 of file OSGImageComposer.cpp.

References osg::AttachmentContainer::changed().

00099 {
00100     Inherited::changed(whichField, origin);
00101 }

void ImageComposer::dump UInt32  uiIndent = 0,
const BitVector  bvFlags = 0
const [virtual]
 

Reimplemented from osg::AttachmentContainer.

Definition at line 103 of file OSGImageComposer.cpp.

References SLOG.

00105 {
00106     SLOG << "Dump ImageComposer NI" << std::endl;
00107 }

void ImageComposer::setup bool  isClient,
UInt32  clusterId,
WindowPtr  localWindow,
ClusterWindowPtr  clusterWindow
 

initialize the composer

Definition at line 113 of file OSGImageComposer.cpp.

References _clusterId, _clusterSize, _clusterWindow, _isClient, _localWindow, and _serverCount.

00117 {
00118     _isClient = isClient;
00119     _clusterId = clusterId;
00120     _localWindow = localWindow;
00121     _clusterWindow = clusterWindow;
00122     _clusterSize = clusterWindow->getServers().size()+1;
00123     _serverCount = clusterWindow->getServers().size();
00124 }

void ImageComposer::open void   )  [virtual]
 

open composer

Definition at line 130 of file OSGImageComposer.cpp.

00131 {
00132 }

void ImageComposer::composeViewport ViewportPtr  port  )  [virtual]
 

compose singel viewport

Definition at line 136 of file OSGImageComposer.cpp.

00137 {
00138 }

void ImageComposer::composeWindow void   )  [virtual]
 

compose whole window

Definition at line 142 of file OSGImageComposer.cpp.

00143 {
00144 }

void ImageComposer::close void   )  [virtual]
 

close composer

Definition at line 148 of file OSGImageComposer.cpp.

00149 {
00150 }

bool ImageComposer::getClientRendering void   )  [virtual]
 

The default is that the cluster window should render on the client side. Overload this method if the composer is not able to handle client rendering.

Definition at line 158 of file OSGImageComposer.cpp.

00159 {
00160     return true;
00161 }

UInt32 ImageComposer::getUsableServers void   )  [virtual]
 

Return the number of Servers that can be uses by the composer

Definition at line 165 of file OSGImageComposer.cpp.

References serverCount().

00166 {
00167     return serverCount();
00168 }

bool osg::ImageComposer::isClient void   )  [inline, protected]
 

Definition at line 45 of file OSGImageComposer.inl.

References _isClient.

00046 {
00047     return _isClient;
00048 }

UInt32 osg::ImageComposer::clusterId void   )  [inline, protected]
 

Definition at line 50 of file OSGImageComposer.inl.

References _clusterId.

00051 {
00052     return _clusterId;
00053 }

UInt32 osg::ImageComposer::clusterSize void   )  [inline, protected]
 

Definition at line 55 of file OSGImageComposer.inl.

References _clusterSize.

00056 {
00057     return _clusterSize;
00058 }

UInt32 osg::ImageComposer::serverCount void   )  [inline, protected]
 

Definition at line 60 of file OSGImageComposer.inl.

References _serverCount.

Referenced by getUsableServers().

00061 {
00062     return _serverCount;
00063 }

WindowPtr osg::ImageComposer::localWindow void   )  [inline, protected]
 

Definition at line 65 of file OSGImageComposer.inl.

References _localWindow.

00066 {
00067     return _localWindow;
00068 }

ClusterWindowPtr osg::ImageComposer::clusterWindow void   )  [inline, protected]
 

Definition at line 70 of file OSGImageComposer.inl.

References _clusterWindow.

00071 {
00072     return _clusterWindow;
00073 }

bool ImageComposer::getScreenAlignedBBox NodePtr  node,
ViewportPtr  vp,
UInt32 l,
UInt32 b,
UInt32 r,
UInt32 t,
UInt32 front,
UInt32 back
[protected]
 

get screen aligned bounding box of the given geometrie. width and hight are given in pixels. depth is given as uint32. Returns false if the node is invisible

Definition at line 176 of file OSGImageComposer.cpp.

References osg::DynamicVolume::getBounds(), osg::TransformationMatrix< ValueTypeT >::multFullMatrixPnt(), osg::TransformationMatrix< ValueTypeT >::multLeft(), p, and osg::DynamicVolume::transform().

00180 {
00181     UInt32 width     = vp->getPixelWidth();
00182     UInt32 height    = vp->getPixelHeight();
00183     Matrix viewing;
00184     Matrix projection;
00185     Real32 rNear     = vp->getCamera()->getNear();
00186     Vec3f              vol[2];
00187     Pnt3f              pnt;
00188     Real32             minx=0,miny=0,minz=0;
00189     Real32             maxx=0,maxy=0,maxz=0;
00190     Matrix            *p;
00191 
00192     vp->getCamera()->getViewing(viewing,width,height);
00193     vp->getCamera()->getProjection(projection,width,height);
00194 
00195     // default
00196     l=b=r=t=0;
00197     // get whole transformation
00198     Matrix m=node->getToWorld();
00199     m.multLeft(viewing);
00200     // get transformed volume
00201     node->updateVolume();
00202     DynamicVolume volume=node->getVolume();
00203     // bug in osg base
00204     /*
00205     if(volume.isEmpty())
00206     {
00207         _visible=false;
00208         return;
00209     }
00210     */
00211     volume.transform(m);
00212     // get min,max
00213     volume.getBounds(vol[0], vol[1]);
00214     // min < rNear
00215     if(vol[0][2] > -rNear)
00216         return false;
00217     if(vol[1][2] > -rNear)
00218     {
00219         // volume lays on the fron clipping plane
00220         vol[1][2] = -rNear;
00221         p=&projection;
00222     }
00223     else
00224     {
00225         // volume lays on the visible side of the clipping plane
00226         node->getVolume().getBounds(vol[0], vol[1]);
00227         m.multLeft(projection);
00228         p=&m;
00229     }
00230     // create corners of a bounding box
00231     for(int i=0;i<8;++i)
00232     {
00233         p->multFullMatrixPnt(Pnt3f( vol[ (i   )&1 ][0] ,
00234                                     vol[ (i>>1)&1 ][1] ,
00235                                     vol[ (i>>2)&1 ][2]) , pnt);
00236         if(i>0)
00237         {
00238             if(minx > pnt[0]) minx = pnt[0];
00239             if(miny > pnt[1]) miny = pnt[1];
00240             if(minz > pnt[2]) minz = pnt[2];
00241             if(maxx < pnt[0]) maxx = pnt[0];
00242             if(maxy < pnt[1]) maxy = pnt[1];
00243             if(maxz < pnt[2]) maxz = pnt[2];
00244         }
00245         else
00246         {
00247             maxx = minx = pnt[0];
00248             maxy = miny = pnt[1];
00249             maxz = minz = pnt[2];
00250         }
00251     }
00252 
00253     // visible ?
00254     if(maxx<-1 || maxy<-1 ||
00255        minx> 1 || miny> 1)
00256     {
00257         return false;
00258     }
00259     else
00260     {
00261         minx=width  * ( minx + 1.0 ) / 2.0 - .5;
00262         maxx=width  * ( maxx + 1.0 ) / 2.0 + .5;
00263         miny=height * ( miny + 1.0 ) / 2.0 - .5;
00264         maxy=height * ( maxy + 1.0 ) / 2.0 + .5;
00265 
00266         if(minx <  0     ) minx = 0;
00267         if(maxx >= width ) maxx = width-1;
00268 
00269         if(miny <  0     ) miny = 0;
00270         if(maxy >= height) maxy = height-1;
00271 
00272         l=(Int32)minx;
00273         b=(Int32)miny;
00274         r=(Int32)maxx;
00275         t=(Int32)maxy;
00276 
00277 /*
00278         maxz = 1 / (2.0 / (maxz+1));
00279         minz = 1 / (2.0 / (minz+1));
00280 */
00281 
00282         front = (UInt32)( (double)(((UInt64)1)<<32) * (minz+1) / 2);
00283         back  = (UInt32)( (double)(((UInt64)1)<<32) * (maxz+1) / 2);
00284     }
00285 
00286 #if 0
00287         glPushMatrix();
00288         glLoadIdentity();
00289         glMatrixMode(GL_PROJECTION);
00290         glPushMatrix();
00291         glLoadIdentity();
00292         glOrtho(0,width,
00293                 0,height,
00294                 -1,1);
00295         glDisable(GL_DEPTH_TEST);
00296         glEnable(GL_COLOR_MATERIAL);
00297         glBegin(GL_LINE_LOOP);
00298         glColor3f(1, 1, 0);
00299         glVertex2f(l,b);
00300         glVertex2f(r,b);
00301         glVertex2f(r,t);
00302         glVertex2f(l,t);
00303         glEnd();
00304         glDisable(GL_COLOR_MATERIAL);
00305         glEnable(GL_DEPTH_TEST);
00306         glPopMatrix();
00307         glMatrixMode(GL_MODELVIEW);
00308         glPopMatrix();
00309         glPopAttrib();
00310 #endif
00311 
00312     return true;
00313 }

void ImageComposer::initMethod void   )  [static, private]
 

Definition at line 67 of file OSGImageComposer.cpp.

00068 {
00069 }

void osg::ImageComposer::operator= const ImageComposer source  )  [private]
 

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

Reimplemented from osg::AttachmentContainer.

Definition at line 58 of file OSGImageComposerBase.inl.

References osg::ImageComposerBase::_type.

00059 {
00060     return _type; 
00061 } 

osg::UInt32 osg::ImageComposerBase::getClassTypeId void   )  [inline, static, inherited]
 

Reimplemented from osg::AttachmentContainer.

Definition at line 65 of file OSGImageComposerBase.inl.

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

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

FieldContainerType & ImageComposerBase::getType void   )  [virtual, inherited]
 

Reimplemented from osg::AttachmentContainer.

Definition at line 117 of file OSGImageComposerBase.cpp.

References osg::ImageComposerBase::_type.

00118 {
00119     return _type; 
00120 } 

const FieldContainerType & ImageComposerBase::getType void   )  const [virtual, inherited]
 

Reimplemented from osg::AttachmentContainer.

Definition at line 122 of file OSGImageComposerBase.cpp.

References osg::ImageComposerBase::_type.

00123 {
00124     return _type;
00125 } 

UInt32 ImageComposerBase::getContainerSize void   )  const [virtual, inherited]
 

Reimplemented from osg::AttachmentContainer.

Definition at line 128 of file OSGImageComposerBase.cpp.

00129 { 
00130     return sizeof(ImageComposer); 
00131 }

SFBool * osg::ImageComposerBase::getSFEnabled void   )  [inline, inherited]
 

Definition at line 75 of file OSGImageComposerBase.inl.

References osg::ImageComposerBase::_sfEnabled.

00076 {
00077     return &_sfEnabled;
00078 }

SFBool * osg::ImageComposerBase::getSFStatistics void   )  [inline, inherited]
 

Definition at line 82 of file OSGImageComposerBase.inl.

References osg::ImageComposerBase::_sfStatistics.

00083 {
00084     return &_sfStatistics;
00085 }

bool & osg::ImageComposerBase::getEnabled void   )  [inline, inherited]
 

Definition at line 90 of file OSGImageComposerBase.inl.

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

00091 {
00092     return _sfEnabled.getValue();
00093 }

const bool & osg::ImageComposerBase::getEnabled void   )  const [inline, inherited]
 

Definition at line 97 of file OSGImageComposerBase.inl.

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

00098 {
00099     return _sfEnabled.getValue();
00100 }

bool & osg::ImageComposerBase::getStatistics void   )  [inline, inherited]
 

Definition at line 111 of file OSGImageComposerBase.inl.

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

00112 {
00113     return _sfStatistics.getValue();
00114 }

const bool & osg::ImageComposerBase::getStatistics void   )  const [inline, inherited]
 

Definition at line 118 of file OSGImageComposerBase.inl.

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

00119 {
00120     return _sfStatistics.getValue();
00121 }

void osg::ImageComposerBase::setEnabled const bool &  value  )  [inline, inherited]
 

Definition at line 104 of file OSGImageComposerBase.inl.

References osg::ImageComposerBase::_sfEnabled, and osg::SField< FieldTypeT, fieldNameSpace >::setValue().

00105 {
00106     _sfEnabled.setValue(value);
00107 }

void osg::ImageComposerBase::setStatistics const bool &  value  )  [inline, inherited]
 

Definition at line 125 of file OSGImageComposerBase.inl.

References osg::ImageComposerBase::_sfStatistics, and osg::SField< FieldTypeT, fieldNameSpace >::setValue().

00126 {
00127     _sfStatistics.setValue(value);
00128 }

UInt32 ImageComposerBase::getBinSize const BitVector whichField  )  [virtual, inherited]
 

Reimplemented from osg::AttachmentContainer.

Definition at line 192 of file OSGImageComposerBase.cpp.

References osg::ImageComposerBase::_sfEnabled, osg::ImageComposerBase::_sfStatistics, osg::ImageComposerBase::EnabledFieldMask, osg::SField< FieldTypeT, fieldNameSpace >::getBinSize(), osg::AttachmentContainer::getBinSize(), osg::FieldBits::NoField, and osg::ImageComposerBase::StatisticsFieldMask.

00193 {
00194     UInt32 returnValue = Inherited::getBinSize(whichField);
00195 
00196     if(FieldBits::NoField != (EnabledFieldMask & whichField))
00197     {
00198         returnValue += _sfEnabled.getBinSize();
00199     }
00200 
00201     if(FieldBits::NoField != (StatisticsFieldMask & whichField))
00202     {
00203         returnValue += _sfStatistics.getBinSize();
00204     }
00205 
00206 
00207     return returnValue;
00208 }

void ImageComposerBase::copyToBin BinaryDataHandler pMem,
const BitVector whichField
[virtual, inherited]
 

Reimplemented from osg::AttachmentContainer.

Definition at line 210 of file OSGImageComposerBase.cpp.

References osg::ImageComposerBase::_sfEnabled, osg::ImageComposerBase::_sfStatistics, osg::SField< FieldTypeT, fieldNameSpace >::copyToBin(), osg::AttachmentContainer::copyToBin(), osg::ImageComposerBase::EnabledFieldMask, osg::FieldBits::NoField, and osg::ImageComposerBase::StatisticsFieldMask.

00212 {
00213     Inherited::copyToBin(pMem, whichField);
00214 
00215     if(FieldBits::NoField != (EnabledFieldMask & whichField))
00216     {
00217         _sfEnabled.copyToBin(pMem);
00218     }
00219 
00220     if(FieldBits::NoField != (StatisticsFieldMask & whichField))
00221     {
00222         _sfStatistics.copyToBin(pMem);
00223     }
00224 
00225 
00226 }

void ImageComposerBase::copyFromBin BinaryDataHandler pMem,
const BitVector whichField
[virtual, inherited]
 

Reimplemented from osg::AttachmentContainer.

Definition at line 228 of file OSGImageComposerBase.cpp.

References osg::ImageComposerBase::_sfEnabled, osg::ImageComposerBase::_sfStatistics, osg::SField< FieldTypeT, fieldNameSpace >::copyFromBin(), osg::AttachmentContainer::copyFromBin(), osg::ImageComposerBase::EnabledFieldMask, osg::FieldBits::NoField, and osg::ImageComposerBase::StatisticsFieldMask.

00230 {
00231     Inherited::copyFromBin(pMem, whichField);
00232 
00233     if(FieldBits::NoField != (EnabledFieldMask & whichField))
00234     {
00235         _sfEnabled.copyFromBin(pMem);
00236     }
00237 
00238     if(FieldBits::NoField != (StatisticsFieldMask & whichField))
00239     {
00240         _sfStatistics.copyFromBin(pMem);
00241     }
00242 
00243 
00244 }

void ImageComposerBase::executeSyncImpl ImageComposerBase pOther,
const BitVector whichField
[protected, inherited]
 

Definition at line 247 of file OSGImageComposerBase.cpp.

References osg::ImageComposerBase::_sfEnabled, osg::ImageComposerBase::_sfStatistics, osg::ImageComposerBase::EnabledFieldMask, osg::AttachmentContainer::executeSyncImpl(), osg::FieldBits::NoField, osg::ImageComposerBase::StatisticsFieldMask, and osg::SField< FieldTypeT, fieldNameSpace >::syncWith().

Referenced by osg::ImageComposerBase::executeSync().

00249 {
00250 
00251     Inherited::executeSyncImpl(pOther, whichField);
00252 
00253     if(FieldBits::NoField != (EnabledFieldMask & whichField))
00254         _sfEnabled.syncWith(pOther->_sfEnabled);
00255 
00256     if(FieldBits::NoField != (StatisticsFieldMask & whichField))
00257         _sfStatistics.syncWith(pOther->_sfStatistics);
00258 
00259 
00260 }

void AttachmentContainer::executeSyncImpl AttachmentContainer pOther,
const BitVector whichField
[protected, inherited]
 

Definition at line 316 of file OSGAttachmentContainer.cpp.

References osg::AttachmentContainer::_attachmentMap, osg::AttachmentContainer::AttachmentsFieldMask, osg::FieldContainer::executeSyncImpl(), osg::FieldBits::NoField, and osg::SField< FieldTypeT, fieldNameSpace >::syncWith().

Referenced by osg::AttachmentContainer::executeSync(), osg::WindowBase::executeSyncImpl(), osg::ViewportBase::executeSyncImpl(), osg::ShaderParameterBase::executeSyncImpl(), osg::Node::executeSyncImpl(), osg::NodeCore::executeSyncImpl(), osg::MaterialBase::executeSyncImpl(), osg::ImageComposerBase::executeSyncImpl(), osg::ImageBase::executeSyncImpl(), osg::ForegroundBase::executeSyncImpl(), osg::DisplayCalibrationBase::executeSyncImpl(), osg::CameraBase::executeSyncImpl(), and osg::BackgroundBase::executeSyncImpl().

00319 {
00320     Inherited::executeSyncImpl(pOther, whichField);
00321 
00322     if (FieldBits::NoField != (AttachmentsFieldMask & whichField))
00323     {
00324         _attachmentMap.syncWith(pOther->_attachmentMap);
00325     }
00326 }

void osg::FieldContainer::executeSyncImpl FieldContainer pOther,
const BitVector whichField
[inline, protected, inherited]
 

Definition at line 333 of file OSGFieldContainerImpl.inl.

Referenced by osg::StateBase::executeSyncImpl(), osg::DVRShaderBase::executeSyncImpl(), osg::DVRClipGeometryBase::executeSyncImpl(), osg::AttachmentContainer::executeSyncImpl(), and osg::Attachment::executeSyncImpl().

00335 {
00336 }

void ImageComposerBase::executeSync FieldContainer other,
const BitVector whichField
[protected, virtual, inherited]
 

Reimplemented from osg::AttachmentContainer.

Definition at line 135 of file OSGImageComposerBase.cpp.

References osg::ImageComposerBase::executeSyncImpl().

00137 {
00138     this->executeSyncImpl((ImageComposerBase *) &other, whichField);
00139 }

void AttachmentContainer::addAttachment const AttachmentPtr fieldContainerP,
UInt16  binding = 0
[inherited]
 

Definition at line 84 of file OSGAttachmentContainer.cpp.

References osg::addRefCP(), osg::beginEditCP(), osg::endEditCP(), osg::NullFC, and osg::subRefCP().

Referenced by osg::AttachmentContainer::AttachmentContainer(), osg::Node::onCreate(), and osg::Image::setAttachmentField().

00086 {
00087     UInt32 key;
00088 
00089     if(fieldContainerP == NullFC)
00090         return;
00091 
00092     key = (UInt32 (fieldContainerP->getGroupId()) << 16) | binding;
00093 
00094     addRefCP(fieldContainerP);
00095 
00096     beginEditCP(fieldContainerP, Attachment::ParentsFieldMask);
00097     {
00098         fieldContainerP->addParent(getPtr());
00099     }
00100     endEditCP  (fieldContainerP, Attachment::ParentsFieldMask);
00101 
00102     AttachmentMap::iterator fcI = _attachmentMap.getValue().find(key);
00103 
00104     if(fcI != _attachmentMap.getValue().end())
00105     {
00106         beginEditCP((*fcI).second, Attachment::ParentsFieldMask);
00107         {
00108             (*fcI).second->subParent(getPtr());
00109         }
00110         endEditCP  ((*fcI).second, Attachment::ParentsFieldMask);
00111 
00112         subRefCP((*fcI).second);
00113 
00114         (*fcI).second = fieldCo