00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054 #ifndef _OSGCLUSTERWINDOWBASE_H_
00055 #define _OSGCLUSTERWINDOWBASE_H_
00056 #ifdef __sgi
00057 #pragma once
00058 #endif
00059
00060
00061 #include <OSGConfig.h>
00062 #include <OSGSystemDef.h>
00063
00064 #include <OSGBaseTypes.h>
00065 #include <OSGRefPtr.h>
00066 #include <OSGCoredNodePtr.h>
00067
00068 #include <OSGWindow.h>
00069
00070 #include <OSGStringFields.h>
00071 #include <OSGStringFields.h>
00072 #include <OSGStringFields.h>
00073 #include <OSGStringFields.h>
00074 #include <OSGStringFields.h>
00075 #include <OSGUInt32Fields.h>
00076 #include <OSGStringFields.h>
00077 #include <OSGWindowFields.h>
00078 #include <OSGUInt32Fields.h>
00079 #include <OSGUInt32Fields.h>
00080 #include <OSGImageComposerFields.h>
00081 #include <OSGStringFields.h>
00082 #include <OSGDisplayCalibrationFields.h>
00083
00084 #include <OSGClusterWindowFields.h>
00085
00086 OSG_BEGIN_NAMESPACE
00087
00088 class ClusterWindow;
00089 class BinaryDataHandler;
00090
00092
00093 class OSG_SYSTEMLIB_DLLMAPPING ClusterWindowBase : public Window
00094 {
00095 private:
00096
00097 typedef Window Inherited;
00098
00099
00100 public:
00101
00102 typedef ClusterWindowPtr Ptr;
00103
00104 enum
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 };
00121
00122 static const OSG::BitVector ServersFieldMask;
00123 static const OSG::BitVector ConnectionTypeFieldMask;
00124 static const OSG::BitVector ConnectionInterfaceFieldMask;
00125 static const OSG::BitVector ConnectionDestinationFieldMask;
00126 static const OSG::BitVector ConnectionParamsFieldMask;
00127 static const OSG::BitVector ServicePortFieldMask;
00128 static const OSG::BitVector ServiceAddressFieldMask;
00129 static const OSG::BitVector ClientWindowFieldMask;
00130 static const OSG::BitVector InterleaveFieldMask;
00131 static const OSG::BitVector FrameCountFieldMask;
00132 static const OSG::BitVector ComposerFieldMask;
00133 static const OSG::BitVector AutostartFieldMask;
00134 static const OSG::BitVector CalibrationFieldMask;
00135
00136
00137 static const OSG::BitVector MTInfluenceMask;
00138
00139
00143 static FieldContainerType &getClassType (void);
00144 static UInt32 getClassTypeId (void);
00145
00147
00151 virtual FieldContainerType &getType (void);
00152 virtual const FieldContainerType &getType (void) const;
00153
00154 virtual UInt32 getContainerSize(void) const;
00155
00157
00161 MFString *getMFServers (void);
00162 SFString *getSFConnectionType (void);
00163 SFString *getSFConnectionInterface(void);
00164 SFString *getSFConnectionDestination(void);
00165 SFString *getSFConnectionParams(void);
00166 SFUInt32 *getSFServicePort (void);
00167 SFString *getSFServiceAddress (void);
00168 SFWindowPtr *getSFClientWindow (void);
00169 SFUInt32 *getSFInterleave (void);
00170 SFUInt32 *getSFFrameCount (void);
00171 SFImageComposerPtr *getSFComposer (void);
00172 MFString *getMFAutostart (void);
00173 MFDisplayCalibrationPtr *getMFCalibration (void);
00174
00175 std::string &getConnectionType (void);
00176 const std::string &getConnectionType (void) const;
00177 std::string &getConnectionInterface(void);
00178 const std::string &getConnectionInterface(void) const;
00179 std::string &getConnectionDestination(void);
00180 const std::string &getConnectionDestination(void) const;
00181 std::string &getConnectionParams(void);
00182 const std::string &getConnectionParams(void) const;
00183 UInt32 &getServicePort (void);
00184 const UInt32 &getServicePort (void) const;
00185 std::string &getServiceAddress (void);
00186 const std::string &getServiceAddress (void) const;
00187 WindowPtr &getClientWindow (void);
00188 const WindowPtr &getClientWindow (void) const;
00189 UInt32 &getInterleave (void);
00190 const UInt32 &getInterleave (void) const;
00191 UInt32 &getFrameCount (void);
00192 const UInt32 &getFrameCount (void) const;
00193 ImageComposerPtr &getComposer (void);
00194 const ImageComposerPtr &getComposer (void) const;
00195 std::string &getServers (const UInt32 index);
00196 MFString &getServers (void);
00197 const MFString &getServers (void) const;
00198 std::string &getAutostart (const UInt32 index);
00199 MFString &getAutostart (void);
00200 const MFString &getAutostart (void) const;
00201 DisplayCalibrationPtr &getCalibration (const UInt32 index);
00202 MFDisplayCalibrationPtr &getCalibration (void);
00203 const MFDisplayCalibrationPtr &getCalibration (void) const;
00204
00206
00210 void setConnectionType ( const std::string &value );
00211 void setConnectionInterface( const std::string &value );
00212 void setConnectionDestination( const std::string &value );
00213 void setConnectionParams( const std::string &value );
00214 void setServicePort ( const UInt32 &value );
00215 void setServiceAddress ( const std::string &value );
00216 void setClientWindow ( const WindowPtr &value );
00217 void setInterleave ( const UInt32 &value );
00218 void setFrameCount ( const UInt32 &value );
00219 void setComposer ( const ImageComposerPtr &value );
00220
00222
00227
00231 virtual UInt32 getBinSize (const BitVector &whichField);
00232 virtual void copyToBin ( BinaryDataHandler &pMem,
00233 const BitVector &whichField);
00234 virtual void copyFromBin( BinaryDataHandler &pMem,
00235 const BitVector &whichField);
00236
00237
00239
00243 static ClusterWindowPtr create (void);
00244 static ClusterWindowPtr createEmpty (void);
00245
00248
00252 virtual FieldContainerPtr shallowCopy (void) const;
00253
00255
00256 protected:
00257
00258
00262 MFString _mfServers;
00263 SFString _sfConnectionType;
00264 SFString _sfConnectionInterface;
00265 SFString _sfConnectionDestination;
00266 SFString _sfConnectionParams;
00267 SFUInt32 _sfServicePort;
00268 SFString _sfServiceAddress;
00269 SFWindowPtr _sfClientWindow;
00270 SFUInt32 _sfInterleave;
00271 SFUInt32 _sfFrameCount;
00272 SFImageComposerPtr _sfComposer;
00273 MFString _mfAutostart;
00274 MFDisplayCalibrationPtr _mfCalibration;
00275
00277
00281 ClusterWindowBase(void);
00282 ClusterWindowBase(const ClusterWindowBase &source);
00283
00285
00289 virtual ~ClusterWindowBase(void);
00290
00292
00296 #if !defined(OSG_FIXED_MFIELDSYNC)
00297 void executeSyncImpl( ClusterWindowBase *pOther,
00298 const BitVector &whichField);
00299
00300 virtual void executeSync( FieldContainer &other,
00301 const BitVector &whichField);
00302 #else
00303 void executeSyncImpl( ClusterWindowBase *pOther,
00304 const BitVector &whichField,
00305 const SyncInfo &sInfo );
00306
00307 virtual void executeSync( FieldContainer &other,
00308 const BitVector &whichField,
00309 const SyncInfo &sInfo);
00310
00311 virtual void execBeginEdit (const BitVector &whichField,
00312 UInt32 uiAspect,
00313 UInt32 uiContainerSize);
00314
00315 void execBeginEditImpl (const BitVector &whichField,
00316 UInt32 uiAspect,
00317 UInt32 uiContainerSize);
00318
00319 virtual void onDestroyAspect(UInt32 uiId, UInt32 uiAspect);
00320 #endif
00321
00323
00324 private:
00325
00326 friend class FieldContainer;
00327
00328 static FieldDescription *_desc[];
00329 static FieldContainerType _type;
00330
00331
00332
00333 void operator =(const ClusterWindowBase &source);
00334 };
00335
00336
00337
00338
00339
00340
00341 typedef ClusterWindowBase *ClusterWindowBaseP;
00342
00343 typedef osgIF<ClusterWindowBase::isNodeCore,
00344 CoredNodePtr<ClusterWindow>,
00345 FieldContainer::attempt_to_create_CoredNodePtr_on_non_NodeCore_FC
00346 >::_IRet ClusterWindowNodePtr;
00347
00348 typedef RefPtr<ClusterWindowPtr> ClusterWindowRefPtr;
00349
00350 OSG_END_NAMESPACE
00351
00352 #define OSGCLUSTERWINDOWBASE_HEADER_CVSID "@(#)$Id: FCBaseTemplate_h.h,v 1.38 2005/07/08 06:37:35 vossg Exp $"
00353
00354 #endif