fixed: auto_ptr -> unique_ptr
[opensg.git] / Source / System / Cluster / Window / SortFirst / OSGSortFirstWindowBase.h
blob8a115a43b4ef42c8af49f3c12c89ca861c332aae
1 /*---------------------------------------------------------------------------*\
2 * OpenSG *
3 * *
4 * *
5 * Copyright (C) 2000-2013 by the OpenSG Forum *
6 * *
7 * www.opensg.org *
8 * *
9 * contact: dirk@opensg.org, gerrit.voss@vossg.org, carsten_neumann@gmx.net *
10 * *
11 \*---------------------------------------------------------------------------*/
12 /*---------------------------------------------------------------------------*\
13 * License *
14 * *
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. *
18 * *
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. *
23 * *
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. *
27 * *
28 \*---------------------------------------------------------------------------*/
29 /*---------------------------------------------------------------------------*\
30 * Changes *
31 * *
32 * *
33 * *
34 * *
35 * *
36 * *
37 \*---------------------------------------------------------------------------*/
39 /*****************************************************************************\
40 *****************************************************************************
41 ** **
42 ** This file is automatically generated. **
43 ** **
44 ** Any changes made to this file WILL be lost when it is **
45 ** regenerated, which can become necessary at any time. **
46 ** **
47 ** Do not change this file, changes should be done in the derived **
48 ** class SortFirstWindow
49 ** **
50 *****************************************************************************
51 \*****************************************************************************/
54 #ifndef _OSGSORTFIRSTWINDOWBASE_H_
55 #define _OSGSORTFIRSTWINDOWBASE_H_
56 #ifdef __sgi
57 #pragma once
58 #endif
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"
73 OSG_BEGIN_NAMESPACE
76 class SortFirstWindow;
78 //! \brief SortFirstWindow Base Class.
80 class OSG_CLUSTER_DLLMAPPING SortFirstWindowBase : public ClusterWindow
82 public:
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 =================================*/
94 public:
96 enum
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 */
127 /*! \{ */
129 static FieldContainerType &getClassType (void);
130 static UInt32 getClassTypeId (void);
131 static UInt16 getClassGroupId(void);
133 /*! \} */
134 /*---------------------------------------------------------------------*/
135 /*! \name FieldContainer Get */
136 /*! \{ */
138 virtual FieldContainerType &getType (void);
139 virtual const FieldContainerType &getType (void) const;
141 virtual UInt32 getContainerSize(void) const;
143 /*! \} */
144 /*---------------------------------------------------------------------*/
145 /*! \name Field Get */
146 /*! \{ */
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;
180 /*! \} */
181 /*---------------------------------------------------------------------*/
182 /*! \name Field Set */
183 /*! \{ */
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);
190 /*! \} */
191 /*---------------------------------------------------------------------*/
192 /*! \name Ptr MField Set */
193 /*! \{ */
195 /*! \} */
196 /*---------------------------------------------------------------------*/
197 /*! \name Binary Access */
198 /*! \{ */
200 virtual SizeT getBinSize (ConstFieldMaskArg whichField);
201 virtual void copyToBin (BinaryDataHandler &pMem,
202 ConstFieldMaskArg whichField);
203 virtual void copyFromBin(BinaryDataHandler &pMem,
204 ConstFieldMaskArg whichField);
207 /*! \} */
208 /*---------------------------------------------------------------------*/
209 /*! \name Construction */
210 /*! \{ */
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);
223 /*! \} */
224 /*---------------------------------------------------------------------*/
225 /*! \name Copy */
226 /*! \{ */
228 virtual FieldContainerTransitPtr shallowCopy (void) const;
229 virtual FieldContainerTransitPtr shallowCopyLocal(
230 BitVector bFlags = FCLocal::All) const;
231 virtual FieldContainerTransitPtr shallowCopyDependent(
232 BitVector bFlags) const;
234 /*! \} */
235 /*========================= PROTECTED ===============================*/
237 protected:
239 static TypeObject _type;
241 static void classDescInserter(TypeObject &oType);
242 static const Char8 *getClassname (void );
244 /*---------------------------------------------------------------------*/
245 /*! \name Fields */
246 /*! \{ */
248 SFString _sfCompression;
249 SFUInt32 _sfSubtileSize;
250 SFBool _sfCompose;
251 MFUInt32 _mfRegion;
252 SFBool _sfUseFaceDistribution;
254 /*! \} */
255 /*---------------------------------------------------------------------*/
256 /*! \name Constructors */
257 /*! \{ */
259 SortFirstWindowBase(void);
260 SortFirstWindowBase(const SortFirstWindowBase &source);
262 /*! \} */
263 /*---------------------------------------------------------------------*/
264 /*! \name Destructors */
265 /*! \{ */
267 virtual ~SortFirstWindowBase(void);
269 /*! \} */
270 /*---------------------------------------------------------------------*/
271 /*! \name onCreate */
272 /*! \{ */
275 /*! \} */
276 /*---------------------------------------------------------------------*/
277 /*! \name Generic Field Access */
278 /*! \{ */
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);
291 /*! \} */
292 /*---------------------------------------------------------------------*/
293 /*! \name Sync */
294 /*! \{ */
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);
308 #endif
310 /*! \} */
311 /*---------------------------------------------------------------------*/
312 /*! \name Edit */
313 /*! \{ */
315 /*! \} */
316 /*---------------------------------------------------------------------*/
317 /*! \name Aspect Create */
318 /*! \{ */
320 #ifdef OSG_MT_CPTR_ASPECT
321 virtual FieldContainer *createAspectCopy(
322 const FieldContainer *pRefAspect) const;
323 #endif
325 /*! \} */
326 /*---------------------------------------------------------------------*/
327 /*! \name Edit */
328 /*! \{ */
329 /*! \} */
330 /*---------------------------------------------------------------------*/
331 /*! \name Sync */
332 /*! \{ */
334 virtual void resolveLinks(void);
336 /*! \} */
337 /*========================== PRIVATE ================================*/
339 private:
340 /*---------------------------------------------------------------------*/
342 // prohibit default functions (move to 'public' if you need one)
343 void operator =(const SortFirstWindowBase &source);
346 typedef SortFirstWindowBase *SortFirstWindowBaseP;
348 OSG_END_NAMESPACE
350 #endif /* _OSGSORTFIRSTWINDOWBASE_H_ */