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

osg::ClusterWindowBase Class Reference

ClusterWindow Base Class.

#include <OSGClusterWindowBase.h>

Inheritance diagram for osg::ClusterWindowBase:

osg::Window osg::WindowBase osg::AttachmentContainer osg::FieldContainer osg::ClusterWindow osg::MultiDisplayWindowBase osg::SortFirstWindowBase osg::MultiDisplayWindow osg::SortFirstWindow List of all members.

Extension handling

bool hasExtension (UInt32 id)
bool hasExtension (const Char8 *s)
void * getFunction (UInt32 id)
void * getFunctionNoCheck (UInt32 id)
void dumpExtensions (void)
GLExtensionFunction getFunctionByName (const Char8 *s)
Real32 getConstantValue (GLenum val)
const Vec2fgetConstantValuev (GLenum val)
const std::vector< std::string > & getRegisteredFunctions (void)
const std::vector< std::string > & getExtensions (void)
const std::vector< std::string > & getIgnoredExtensions (void)
*static void setGLLibraryName (const Char8 *s)
static Int32 getExtensionId (const Char8 *s)
static bool hasCommonExtension (UInt32 id)
static const std::vector<
std::string > & 
getRegisteredExtensions (void)

GL object handling

*void validateGLObject (UInt32 id)
void validateAllGLObjects (void)
GLObjectStatusE getGLObjectStatus (UInt32 id)
void setGLObjectId (UInt32 id, UInt32 id2)
UInt32 getGLObjectId (UInt32 id)
static void refreshGLObject (UInt32 id)
static void reinitializeGLObject (UInt32 id)
static void destroyGLObject (UInt32 id, UInt32 num=1)
static void unpackIdStatus (UInt32 idstatus, UInt32 &id, GLObjectStatusE &status)

GL object handling

void doInitRegisterGLObject (UInt32 id, UInt32 num)
*static void initRegisterGLObject (UInt32 id, UInt32 num)
static UInt32 packIdStatus (UInt32 id, GLObjectStatusE status)

Public Types

typedef ClusterWindowPtr Ptr
enum  {
  ServersFieldId = Inherited::NextFieldId, ConnectionTypeFieldId = ServersFieldId + 1, ConnectionInterfaceFieldId = ConnectionTypeFieldId + 1, ConnectionDestinationFieldId = ConnectionInterfaceFieldId + 1,
  ConnectionParamsFieldId = ConnectionDestinationFieldId + 1, ServicePortFieldId = ConnectionParamsFieldId + 1, ServiceAddressFieldId = ServicePortFieldId + 1, ClientWindowFieldId = ServiceAddressFieldId + 1,
  InterleaveFieldId = ClientWindowFieldId + 1, FrameCountFieldId = InterleaveFieldId + 1, ComposerFieldId = FrameCountFieldId + 1, AutostartFieldId = ComposerFieldId + 1,
  CalibrationFieldId = AutostartFieldId + 1, NextFieldId = CalibrationFieldId + 1
}
typedef ArgsCollector< UInt32GLObjectFunctorArgs
typedef TypedVoidFunctor2Base<
PtrCallArg< Window >, GLObjectFunctorArgs
GLObjectFunctor
typedef void(* GLExtensionFunction )(void)
enum  GLObjectStatusE {
  notused = 1, initialize, reinitialize, initialized,
  needrefresh, destroy, finaldestroy
}
enum  { statusShift = 3, statusMask = 7 }

Public Member Functions

FieldContainer Get
*virtual FieldContainerTypegetType (void)
virtual const FieldContainerTypegetType (void) const
virtual UInt32 getContainerSize (void) const
Field Get
*MFStringgetMFServers (void)
 Get the ClusterWindow::_mfServers field.
SFStringgetSFConnectionType (void)
 Get the ClusterWindow::_sfConnectionType field.
SFStringgetSFConnectionInterface (void)
 Get the ClusterWindow::_sfConnectionInterface field.
SFStringgetSFConnectionDestination (void)
 Get the ClusterWindow::_sfConnectionDestination field.
SFStringgetSFConnectionParams (void)
 Get the ClusterWindow::_sfConnectionParams field.
SFUInt32getSFServicePort (void)
 Get the ClusterWindow::_sfServicePort field.
SFStringgetSFServiceAddress (void)
 Get the ClusterWindow::_sfServiceAddress field.
SFWindowPtrgetSFClientWindow (void)
 Get the ClusterWindow::_sfClientWindow field.
SFUInt32getSFInterleave (void)
 Get the ClusterWindow::_sfInterleave field.
SFUInt32getSFFrameCount (void)
 Get the ClusterWindow::_sfFrameCount field.
SFImageComposerPtrgetSFComposer (void)
 Get the ClusterWindow::_sfComposer field.
MFStringgetMFAutostart (void)
 Get the ClusterWindow::_mfAutostart field.
MFDisplayCalibrationPtrgetMFCalibration (void)
 Get the ClusterWindow::_mfCalibration field.
std::string & getConnectionType (void)
 Get the value of the ClusterWindow::_sfConnectionType field.
const std::string & getConnectionType (void) const
 Get the value of the ClusterWindow::_sfConnectionType field.
std::string & getConnectionInterface (void)
 Get the value of the ClusterWindow::_sfConnectionInterface field.
const std::string & getConnectionInterface (void) const
 Get the value of the ClusterWindow::_sfConnectionInterface field.
std::string & getConnectionDestination (void)
 Get the value of the ClusterWindow::_sfConnectionDestination field.
const std::string & getConnectionDestination (void) const
 Get the value of the ClusterWindow::_sfConnectionDestination field.
std::string & getConnectionParams (void)
 Get the value of the ClusterWindow::_sfConnectionParams field.
const std::string & getConnectionParams (void) const
 Get the value of the ClusterWindow::_sfConnectionParams field.
UInt32getServicePort (void)
 Get the value of the ClusterWindow::_sfServicePort field.
const UInt32getServicePort (void) const
 Get the value of the ClusterWindow::_sfServicePort field.
std::string & getServiceAddress (void)
 Get the value of the ClusterWindow::_sfServiceAddress field.
const std::string & getServiceAddress (void) const
 Get the value of the ClusterWindow::_sfServiceAddress field.
WindowPtrgetClientWindow (void)
 Get the value of the ClusterWindow::_sfClientWindow field.
const WindowPtrgetClientWindow (void) const
 Get the value of the ClusterWindow::_sfClientWindow field.
UInt32getInterleave (void)
 Get the value of the ClusterWindow::_sfInterleave field.
const UInt32getInterleave (void) const
 Get the value of the ClusterWindow::_sfInterleave field.
UInt32getFrameCount (void)
 Get the value of the ClusterWindow::_sfFrameCount field.
const UInt32getFrameCount (void) const
 Get the value of the ClusterWindow::_sfFrameCount field.
ImageComposerPtrgetComposer (void)
 Get the value of the ClusterWindow::_sfComposer field.
const ImageComposerPtrgetComposer (void) const
 Get the value of the ClusterWindow::_sfComposer field.
std::string & getServers (const UInt32 index)
 Get the value of the index element the ClusterWindow::_mfServers field.
MFStringgetServers (void)
 Get the ClusterWindow::_mfServers field.
const MFStringgetServers (void) const
 Get the ClusterWindow::_mfServers field.
std::string & getAutostart (const UInt32 index)
 Get the value of the index element the ClusterWindow::_mfAutostart field.
MFStringgetAutostart (void)
 Get the ClusterWindow::_mfAutostart field.
const MFStringgetAutostart (void) const
 Get the ClusterWindow::_mfAutostart field.
DisplayCalibrationPtrgetCalibration (const UInt32 index)
 Get the value of the index element the ClusterWindow::_mfCalibration field.
MFDisplayCalibrationPtrgetCalibration (void)
 Get the ClusterWindow::_mfCalibration field.
const MFDisplayCalibrationPtrgetCalibration (void) const
 Get the ClusterWindow::_mfCalibration field.
Field Set
*void setConnectionType (const std::string &value)
 Set the value of the ClusterWindow::_sfConnectionType field.
void setConnectionInterface (const std::string &value)
 Set the value of the ClusterWindow::_sfConnectionInterface field.
void setConnectionDestination (const std::string &value)
 Set the value of the ClusterWindow::_sfConnectionDestination field.
void setConnectionParams (const std::string &value)
 Set the value of the ClusterWindow::_sfConnectionParams field.
void setServicePort (const UInt32 &value)
 Set the value of the ClusterWindow::_sfServicePort field.
void setServiceAddress (const std::string &value)
 Set the value of the ClusterWindow::_sfServiceAddress field.
void setClientWindow (const WindowPtr &value)
 Set the value of the ClusterWindow::_sfClientWindow field.
void setInterleave (const UInt32 &value)
 Set the value of the ClusterWindow::_sfInterleave field.
void setFrameCount (const UInt32 &value)
 Set the value of the ClusterWindow::_sfFrameCount field.
void setComposer (const ImageComposerPtr &value)
 Set the value of the ClusterWindow::_sfComposer 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
Sync
*virtual void changed (BitVector whichField, UInt32 origin)
Viewport handling
*void addPort (const ViewportPtr &portP)
void insertPort (UInt32 portIndex, const ViewportPtr &portP)
void replacePort (UInt32 portIndex, const ViewportPtr &portP)
void replacePortBy (const ViewportPtr &portP, const ViewportPtr &newPortP)
void subPort (const ViewportPtr &portP)
void subPort (UInt32 portIndex)
Size handling
*bool isResizePending (void)
virtual void resize (int width, int height)
virtual void resizeGL (void)
void setSize (UInt16 width, UInt16 height)
Drawing
*virtual void frameInit (void)
virtual void frameExit (void)
virtual void draw (DrawAction *action=NULL)
virtual void drawAllViewports (DrawAction *action=NULL)
virtual void render (RenderActionBase *action=NULL)
virtual void renderAllViewports (RenderActionBase *action=NULL)
Window system implementation functions
*virtual void init (void)=0
virtual void activate (void)=0
virtual void deactivate (void)=0
virtual void swap (void)=0
Output
*virtual void dump (UInt32 uiIndent=0, const BitVector bvFlags=0) const
Field Get
*SFUInt16getSFWidth (void)
 Get the Window::_sfWidth field.
SFUInt16getSFHeight (void)
 Get the Window::_sfHeight field.
MFViewportPtrgetMFPort (void)
 Get the Window::_mfPort field.
SFBoolgetSFResizePending (void)
 Get the Window::_sfResizePending field.
UInt16getWidth (void)
 Get the value of the Window::_sfWidth field.
const UInt16getWidth (void) const
 Get the value of the Window::_sfWidth field.
UInt16getHeight (void)
 Get the value of the Window::_sfHeight field.
const UInt16getHeight (void) const
 Get the value of the Window::_sfHeight field.
bool & getResizePending (void)
 Get the value of the Window::_sfResizePending field.
const bool & getResizePending (void) const
 Get the value of the Window::_sfResizePending field.
ViewportPtrgetPort (const UInt32 index)
 Get the value of the index element the Window::_mfPort field.
MFViewportPtrgetPort (void)
 Get the Window::_mfPort field.
const MFViewportPtrgetPort (void) const
 Get the Window::_mfPort field.
Field Set
*void setWidth (const UInt16 &value)
 Set the value of the Window::_sfWidth field.
void setHeight (const UInt16 &value)
 Set the value of the Window::_sfHeight field.
void setResizePending (const bool &value)
 Set the value of the Window::_sfResizePending field.
Handle Attachments
*void addAttachment (const AttachmentPtr &fieldContainerP, UInt16 binding=0)
void subAttachment (const AttachmentPtr &fieldContainerP, UInt16 binding=0)
AttachmentPtr findAttachment (UInt32 groupId, UInt16 binding=0)
AttachmentPtr findAttachment (const FieldContainerType &type, UInt16 binding=0)
Field Access *SFAttachmentMapgetSFAttachments (void)
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 ClusterWindowPtr create (void)
 create a new instance of the class
static ClusterWindowPtr createEmpty (void)
 create an empty new instance of the class, do not copy the prototype
Class Get
*static const char * getClassname (void)
Extension registration
*static UInt32 registerExtension (const Char8 *s)
static void ignoreExtensions (const Char8 *s)
static UInt32 registerFunction (const Char8 *s, Int32 ext=-1)
static void registerConstant (GLenum val)
GL object registration
*static UInt32 registerGLObject (GLObjectFunctor functor, UInt32 num=1)
Get Class Type Information
static UInt16 getClassGroupId (void)

Static Public Attributes

static const osg::BitVector ServersFieldMask
static const osg::BitVector ConnectionTypeFieldMask
static const osg::BitVector ConnectionInterfaceFieldMask
static const osg::BitVector ConnectionDestinationFieldMask
static const osg::BitVector ConnectionParamsFieldMask
static const osg::BitVector ServicePortFieldMask
static const osg::BitVector ServiceAddressFieldMask
static const osg::BitVector ClientWindowFieldMask
static const osg::BitVector InterleaveFieldMask
static const osg::BitVector FrameCountFieldMask
static const osg::BitVector ComposerFieldMask
static const osg::BitVector AutostartFieldMask
static const osg::BitVector CalibrationFieldMask
static const osg::BitVector MTInfluenceMask
static const Real32 unknownConstant = -1e100
static const osg::BitVector WidthFieldMask
static const osg::BitVector HeightFieldMask
static const osg::BitVector PortFieldMask
static const osg::BitVector ResizePendingFieldMask
static const osg::BitVector GlObjectEventCounterFieldMask
static const osg::BitVector GlObjectLastRefreshFieldMask
static const osg::BitVector GlObjectLastReinitializeFieldMask
static const BitVector AttachmentsFieldMask
static const BitVector NextFieldMask
CoredNodePtr helper
static const bool isNodeCore = false

Protected Member Functions

Constructors
ClusterWindowBase (void)
 ClusterWindowBase (const ClusterWindowBase &source)
Destructors
*virtual ~ClusterWindowBase (void)
Sync
*void executeSyncImpl (ClusterWindowBase *pOther, const BitVector &whichField)
virtual void executeSync (FieldContainer &other, const BitVector &whichField)
GL setup handling
*virtual void setupGL (void)
MT Construction
*void onCreate (const FieldContainer *source=NULL)
void onCreateAspect (const FieldContainer *aspect0, const FieldContainer *source=NULL)
Field Get
*SFUInt32getSFGlObjectEventCounter (void)
 Get the Window::_sfGlObjectEventCounter field.
MFUInt32getMFGlObjectLastRefresh (void)
 Get the Window::_mfGlObjectLastRefresh field.
MFUInt32getMFGlObjectLastReinitialize (void)
 Get the Window::_mfGlObjectLastReinitialize field.
UInt32getGlObjectEventCounter (void)
 Get the value of the Window::_sfGlObjectEventCounter field.
const UInt32getGlObjectEventCounter (void) const
 Get the value of the Window::_sfGlObjectEventCounter field.
UInt32getGlObjectLastRefresh (UInt32 index)
 Get the value of the index element the Window::_mfGlObjectLastRefresh field.
MFUInt32getGlObjectLastRefresh (void)
 Get the Window::_mfGlObjectLastRefresh field.
const MFUInt32getGlObjectLastRefresh (void) const
 Get the Window::_mfGlObjectLastRefresh field.
UInt32getGlObjectLastReinitialize (UInt32 index)
 Get the value of the index element the Window::_mfGlObjectLastReinitialize field.
MFUInt32getGlObjectLastReinitialize (void)
 Get the Window::_mfGlObjectLastReinitialize field.
const MFUInt32getGlObjectLastReinitialize (void) const
 Get the Window::_mfGlObjectLastReinitialize field.
Field Set
*void setGlObjectEventCounter (const UInt32 &value)
 Set the value of the Window::_sfGlObjectEventCounter field.
Sync
*void executeSyncImpl (WindowBase *pOther, const BitVector &whichField)
Sync
void executeSyncImpl (AttachmentContainer *pOther, const BitVector &whichField)
Sync
void executeSyncImpl (FieldContainer *pOther, const BitVector &whichField)
Pointer
*AttachmentContainerPtr getPtr (void)
MT Edit
template<class FieldTypeT>
*void beginEditX (const BitVector &whichField, FieldTypeT &field)
template<class FieldTypeT>
void endEditX (const BitVector &whichField, FieldTypeT &field)

Static Protected Member Functions

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
*MFString _mfServers
SFString _sfConnectionType
SFString _sfConnectionInterface
SFString _sfConnectionDestination
SFString _sfConnectionParams
SFUInt32 _sfServicePort
SFString _sfServiceAddress
SFWindowPtr _sfClientWindow
SFUInt32 _sfInterleave
SFUInt32 _sfFrameCount
SFImageComposerPtr _sfComposer
MFString _mfAutostart
MFDisplayCalibrationPtr _mfCalibration
Map for GL cvonstant handling
*typedef std::map< GLenum,
Vec2f
ConstHash
Fields
*SFUInt16 _sfWidth
SFUInt16 _sfHeight
MFViewportPtr _mfPort
SFBool _sfResizePending
SFUInt32 _sfGlObjectEventCounter
MFUInt32 _mfGlObjectLastRefresh
MFUInt32 _mfGlObjectLastReinitialize
Fields
*SFAttachmentMap _attachmentMap
Member
*UInt32 _shares

Private Types

typedef Window Inherited

Private Member Functions

void operator= (const ClusterWindowBase &source)

Static Private Attributes

static FieldDescription_desc []
 ClusterWindow description.
static FieldContainerType _type

Friends

class FieldContainer
GL object handling helper class
class GLObject

Detailed Description

Definition at line 93 of file OSGClusterWindowBase.h.


Member Typedef Documentation

typedef Window osg::ClusterWindowBase::Inherited [private]
 

Reimplemented from osg::Window.

Reimplemented in osg::ClusterWindow, osg::MultiDisplayWindow, osg::MultiDisplayWindowBase, osg::SortFirstWindow, and osg::SortFirstWindowBase.

Definition at line 97 of file OSGClusterWindowBase.h.

typedef ClusterWindowPtr osg::ClusterWindowBase::Ptr
 

Reimplemented from osg::WindowBase.

Reimplemented in osg::MultiDisplayWindowBase, and osg::SortFirstWindowBase.

Definition at line 102 of file OSGClusterWindowBase.h.

typedef ArgsCollector<UInt32> osg::Window::GLObjectFunctorArgs [inherited]
 

Definition at line 96 of file OSGWindow.h.

typedef TypedVoidFunctor2Base<PtrCallArg<Window> , GLObjectFunctorArgs> osg::Window::GLObjectFunctor [inherited]
 

Definition at line 99 of file OSGWindow.h.

typedef void(* osg::Window::GLExtensionFunction)(void) [inherited]
 

Definition at line 101 of file OSGWindow.h.


Member Enumeration Documentation

anonymous enum
 

Enumerator:
ServersFieldId 
ConnectionTypeFieldId 
ConnectionInterfaceFieldId 
ConnectionDestinationFieldId 
ConnectionParamsFieldId 
ServicePortFieldId 
ServiceAddressFieldId 
ClientWindowFieldId 
InterleaveFieldId 
FrameCountFieldId 
ComposerFieldId 
AutostartFieldId 
CalibrationFieldId 
NextFieldId 

Reimplemented from osg::Window.

Definition at line 104 of file OSGClusterWindowBase.h.

00105     {
00106         ServersFieldId               = Inherited::NextFieldId,
00107         ConnectionTypeFieldId        = ServersFieldId               + 1,
00108         ConnectionInterfaceFieldId   = ConnectionTypeFieldId        + 1,
00109         ConnectionDestinationFieldId = ConnectionInterfaceFieldId   + 1,
00110         ConnectionParamsFieldId      = ConnectionDestinationFieldId + 1,
00111         ServicePortFieldId           = ConnectionParamsFieldId      + 1,
00112         ServiceAddressFieldId        = ServicePortFieldId           + 1,
00113         ClientWindowFieldId          = ServiceAddressFieldId        + 1,
00114         InterleaveFieldId            = ClientWindowFieldId          + 1,
00115         FrameCountFieldId            = InterleaveFieldId            + 1,
00116         ComposerFieldId              = FrameCountFieldId            + 1,
00117         AutostartFieldId             = ComposerFieldId              + 1,
00118         CalibrationFieldId           = AutostartFieldId             + 1,
00119         NextFieldId                  = CalibrationFieldId           + 1
00120     };

enum osg::Window::GLObjectStatusE [inherited]
 

Enumeration values for the status of the GL objects. This is primarily used to signal the object's callback functions what to do. See OpenGL Objects & Extension Handling for a description.

Enumerator:
notused  Object is not used at all right now.
initialize  The object is being initialized for the first time.
reinitialize  The object is being re-initialized, i.e. it has changed significantly.
initialized  The object is initialized and valid.
needrefresh  The object is initialized but needs a refresh.
destroy  The object is to be destroyed, i.e. removed from the current OpenGL context.
finaldestroy  The object has been removed from all OpenGL contexts and used ressources but be freed now.

Definition at line 78 of file OSGWindow.h.

00079     {
00080         notused      = 1, 
00081         initialize, 
00082         reinitialize, 
00083         initialized,
00084         needrefresh, 
00085         destroy, 
00086         finaldestroy 
00087     };

anonymous enum [inherited]
 

Enumerator:
statusShift  Shift value to transform object id and status into asingle int.
statusMask  Mask value to transform object id and status into asingle int.

Definition at line 92 of file OSGWindow.h.

00092 { statusShift = 3, statusMask = 7 }; 


Constructor & Destructor Documentation

ClusterWindowBase::ClusterWindowBase void   )  [protected]
 

Definition at line 299 of file OSGClusterWindowBase.cpp.

00299                                          :
00300     _mfServers                (), 
00301     _sfConnectionType         (), 
00302     _sfConnectionInterface    (), 
00303     _sfConnectionDestination  (), 
00304     _sfConnectionParams       (), 
00305     _sfServicePort            (UInt32(8437)), 
00306     _sfServiceAddress         (std::string("224.245.211.234")), 
00307     _sfClientWindow           (), 
00308     _sfInterleave             (UInt32(0)), 
00309