1 /*---------------------------------------------------------------------------*\
5 * Copyright (C) 2000-2013 by the OpenSG Forum *
9 * contact: dirk@opensg.org, gerrit.voss@vossg.org, carsten_neumann@gmx.net *
11 \*---------------------------------------------------------------------------*/
12 /*---------------------------------------------------------------------------*\
15 * This library is free software; you can redistribute it and/or modify it *
16 * under the terms of the GNU Library General Public License as published *
17 * by the Free Software Foundation, version 2. *
19 * This library is distributed in the hope that it will be useful, but *
20 * WITHOUT ANY WARRANTY; without even the implied warranty of *
21 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
22 * Library General Public License for more details. *
24 * You should have received a copy of the GNU Library General Public *
25 * License along with this library; if not, write to the Free Software *
26 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. *
28 \*---------------------------------------------------------------------------*/
29 /*---------------------------------------------------------------------------*\
37 \*---------------------------------------------------------------------------*/
39 /*****************************************************************************\
40 *****************************************************************************
42 ** This file is automatically generated. **
44 ** Any changes made to this file WILL be lost when it is **
45 ** regenerated, which can become necessary at any time. **
47 ** Do not change this file, changes should be done in the derived **
48 ** class SortFirstWindow
50 *****************************************************************************
51 \*****************************************************************************/
54 #ifndef _OSGSORTFIRSTWINDOWBASE_H_
55 #define _OSGSORTFIRSTWINDOWBASE_H_
61 #include "OSGConfig.h"
62 #include "OSGClusterDef.h"
64 //#include "OSGBaseTypes.h"
66 #include "OSGClusterWindow.h" // Parent
68 #include "OSGBaseFields.h" // Compression type
69 #include "OSGSysFields.h" // SubtileSize type
71 #include "OSGSortFirstWindowFields.h"
76 class SortFirstWindow
;
78 //! \brief SortFirstWindow Base Class.
80 class OSG_CLUSTER_DLLMAPPING SortFirstWindowBase
: public ClusterWindow
84 typedef ClusterWindow Inherited
;
85 typedef ClusterWindow ParentContainer
;
87 typedef Inherited::TypeObject TypeObject
;
88 typedef TypeObject::InitPhase InitPhase
;
90 OSG_GEN_INTERNALPTR(SortFirstWindow
);
92 /*========================== PUBLIC =================================*/
98 CompressionFieldId
= Inherited::NextFieldId
,
99 SubtileSizeFieldId
= CompressionFieldId
+ 1,
100 ComposeFieldId
= SubtileSizeFieldId
+ 1,
101 RegionFieldId
= ComposeFieldId
+ 1,
102 UseFaceDistributionFieldId
= RegionFieldId
+ 1,
103 NextFieldId
= UseFaceDistributionFieldId
+ 1
106 static const OSG::BitVector CompressionFieldMask
=
107 (TypeTraits
<BitVector
>::One
<< CompressionFieldId
);
108 static const OSG::BitVector SubtileSizeFieldMask
=
109 (TypeTraits
<BitVector
>::One
<< SubtileSizeFieldId
);
110 static const OSG::BitVector ComposeFieldMask
=
111 (TypeTraits
<BitVector
>::One
<< ComposeFieldId
);
112 static const OSG::BitVector RegionFieldMask
=
113 (TypeTraits
<BitVector
>::One
<< RegionFieldId
);
114 static const OSG::BitVector UseFaceDistributionFieldMask
=
115 (TypeTraits
<BitVector
>::One
<< UseFaceDistributionFieldId
);
116 static const OSG::BitVector NextFieldMask
=
117 (TypeTraits
<BitVector
>::One
<< NextFieldId
);
119 typedef SFString SFCompressionType
;
120 typedef SFUInt32 SFSubtileSizeType
;
121 typedef SFBool SFComposeType
;
122 typedef MFUInt32 MFRegionType
;
123 typedef SFBool SFUseFaceDistributionType
;
125 /*---------------------------------------------------------------------*/
126 /*! \name Class Get */
129 static FieldContainerType
&getClassType (void);
130 static UInt32
getClassTypeId (void);
131 static UInt16
getClassGroupId(void);
134 /*---------------------------------------------------------------------*/
135 /*! \name FieldContainer Get */
138 virtual FieldContainerType
&getType (void);
139 virtual const FieldContainerType
&getType (void) const;
141 virtual UInt32
getContainerSize(void) const;
144 /*---------------------------------------------------------------------*/
145 /*! \name Field Get */
149 SFString
*editSFCompression (void);
150 const SFString
*getSFCompression (void) const;
152 SFUInt32
*editSFSubtileSize (void);
153 const SFUInt32
*getSFSubtileSize (void) const;
155 SFBool
*editSFCompose (void);
156 const SFBool
*getSFCompose (void) const;
158 MFUInt32
*editMFRegion (void);
159 const MFUInt32
*getMFRegion (void) const;
161 SFBool
*editSFUseFaceDistribution(void);
162 const SFBool
*getSFUseFaceDistribution (void) const;
165 std::string
&editCompression (void);
166 const std::string
&getCompression (void) const;
168 UInt32
&editSubtileSize (void);
169 UInt32
getSubtileSize (void) const;
171 bool &editCompose (void);
172 bool getCompose (void) const;
174 MFUInt32 ::reference
editRegion (const UInt32 index
);
175 UInt32
getRegion (const UInt32 index
) const;
177 bool &editUseFaceDistribution(void);
178 bool getUseFaceDistribution (void) const;
181 /*---------------------------------------------------------------------*/
182 /*! \name Field Set */
185 void setCompression (const std::string
&value
);
186 void setSubtileSize (const UInt32 value
);
187 void setCompose (const bool value
);
188 void setUseFaceDistribution(const bool value
);
191 /*---------------------------------------------------------------------*/
192 /*! \name Ptr MField Set */
196 /*---------------------------------------------------------------------*/
197 /*! \name Binary Access */
200 virtual SizeT
getBinSize (ConstFieldMaskArg whichField
);
201 virtual void copyToBin (BinaryDataHandler
&pMem
,
202 ConstFieldMaskArg whichField
);
203 virtual void copyFromBin(BinaryDataHandler
&pMem
,
204 ConstFieldMaskArg whichField
);
208 /*---------------------------------------------------------------------*/
209 /*! \name Construction */
212 static SortFirstWindowTransitPtr
create (void);
213 static SortFirstWindow
*createEmpty (void);
215 static SortFirstWindowTransitPtr
createLocal (
216 BitVector bFlags
= FCLocal::All
);
218 static SortFirstWindow
*createEmptyLocal(
219 BitVector bFlags
= FCLocal::All
);
221 static SortFirstWindowTransitPtr
createDependent (BitVector bFlags
);
224 /*---------------------------------------------------------------------*/
228 virtual FieldContainerTransitPtr
shallowCopy (void) const;
229 virtual FieldContainerTransitPtr
shallowCopyLocal(
230 BitVector bFlags
= FCLocal::All
) const;
231 virtual FieldContainerTransitPtr
shallowCopyDependent(
232 BitVector bFlags
) const;
235 /*========================= PROTECTED ===============================*/
239 static TypeObject _type
;
241 static void classDescInserter(TypeObject
&oType
);
242 static const Char8
*getClassname (void );
244 /*---------------------------------------------------------------------*/
248 SFString _sfCompression
;
249 SFUInt32 _sfSubtileSize
;
252 SFBool _sfUseFaceDistribution
;
255 /*---------------------------------------------------------------------*/
256 /*! \name Constructors */
259 SortFirstWindowBase(void);
260 SortFirstWindowBase(const SortFirstWindowBase
&source
);
263 /*---------------------------------------------------------------------*/
264 /*! \name Destructors */
267 virtual ~SortFirstWindowBase(void);
270 /*---------------------------------------------------------------------*/
271 /*! \name onCreate */
276 /*---------------------------------------------------------------------*/
277 /*! \name Generic Field Access */
280 GetFieldHandlePtr
getHandleCompression (void) const;
281 EditFieldHandlePtr
editHandleCompression (void);
282 GetFieldHandlePtr
getHandleSubtileSize (void) const;
283 EditFieldHandlePtr
editHandleSubtileSize (void);
284 GetFieldHandlePtr
getHandleCompose (void) const;
285 EditFieldHandlePtr
editHandleCompose (void);
286 GetFieldHandlePtr
getHandleRegion (void) const;
287 EditFieldHandlePtr
editHandleRegion (void);
288 GetFieldHandlePtr
getHandleUseFaceDistribution (void) const;
289 EditFieldHandlePtr
editHandleUseFaceDistribution(void);
292 /*---------------------------------------------------------------------*/
296 #ifdef OSG_MT_CPTR_ASPECT
297 virtual void execSyncV( FieldContainer
&oFrom
,
298 ConstFieldMaskArg whichField
,
299 AspectOffsetStore
&oOffsets
,
300 ConstFieldMaskArg syncMode
,
301 const UInt32 uiSyncInfo
);
303 void execSync ( SortFirstWindowBase
*pFrom
,
304 ConstFieldMaskArg whichField
,
305 AspectOffsetStore
&oOffsets
,
306 ConstFieldMaskArg syncMode
,
307 const UInt32 uiSyncInfo
);
311 /*---------------------------------------------------------------------*/
316 /*---------------------------------------------------------------------*/
317 /*! \name Aspect Create */
320 #ifdef OSG_MT_CPTR_ASPECT
321 virtual FieldContainer
*createAspectCopy(
322 const FieldContainer
*pRefAspect
) const;
326 /*---------------------------------------------------------------------*/
330 /*---------------------------------------------------------------------*/
334 virtual void resolveLinks(void);
337 /*========================== PRIVATE ================================*/
340 /*---------------------------------------------------------------------*/
342 // prohibit default functions (move to 'public' if you need one)
343 void operator =(const SortFirstWindowBase
&source
);
346 typedef SortFirstWindowBase
*SortFirstWindowBaseP
;
350 #endif /* _OSGSORTFIRSTWINDOWBASE_H_ */