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 CSMGLUTWindow!
50 *****************************************************************************
51 \*****************************************************************************/
57 #pragma warning(disable: 4355) // turn off 'this' : used in base member initializer list warning
58 #pragma warning(disable: 4290) // disable exception specification warning
61 #include "OSGConfig.h"
66 #include "OSGCSMGLUTWindowBase.h"
67 #include "OSGCSMGLUTWindow.h"
69 #include <boost/bind.hpp>
73 /***************************************************************************\
75 \***************************************************************************/
77 /*! \class OSG::CSMGLUTWindow
81 /***************************************************************************\
82 * Field Documentation *
83 \***************************************************************************/
86 /***************************************************************************\
87 * FieldType/FieldTrait Instantiation *
88 \***************************************************************************/
90 #if !defined(OSG_DO_DOC) || defined(OSG_DOC_DEV)
91 PointerType FieldTraits
<CSMGLUTWindow
*, nsOSG
>::_type(
94 CSMGLUTWindow::getClassType(),
98 OSG_FIELDTRAITS_GETTYPE_NS(CSMGLUTWindow
*, nsOSG
)
100 OSG_EXPORT_PTR_SFIELD_FULL(PointerSField
,
104 OSG_EXPORT_PTR_MFIELD_FULL(PointerMField
,
108 /***************************************************************************\
109 * Field Description *
110 \***************************************************************************/
112 void CSMGLUTWindowBase::classDescInserter(TypeObject
&oType
)
117 CSMGLUTWindowBase::TypeObject
CSMGLUTWindowBase::_type(
118 CSMGLUTWindowBase::getClassname(),
119 Inherited::getClassname(),
122 reinterpret_cast<PrototypeCreateF
>(&CSMGLUTWindowBase::createEmptyLocal
),
123 reinterpret_cast<InitContainerF
>(&CSMGLUTWindow::initMethod
),
124 reinterpret_cast<ExitContainerF
>(&CSMGLUTWindow::exitMethod
),
125 reinterpret_cast<InitalInsertDescFunc
>(&CSMGLUTWindow::classDescInserter
),
128 "<?xml version=\"1.0\"?>\n"
131 " name=\"CSMGLUTWindow\"\n"
132 " parent=\"CSMWindow\"\n"
133 " library=\"ContribCSM\"\n"
134 " pointerfieldtypes=\"both\"\n"
135 " structure=\"concrete\"\n"
136 " systemcomponent=\"true\"\n"
137 " parentsystemcomponent=\"true\"\n"
138 " decoratable=\"false\"\n"
139 " useLocalIncludes=\"false\"\n"
140 " isNodeCore=\"false\"\n"
141 " isBundle=\"true\"\n"
143 "</FieldContainer>\n",
147 /*------------------------------ get -----------------------------------*/
149 FieldContainerType
&CSMGLUTWindowBase::getType(void)
154 const FieldContainerType
&CSMGLUTWindowBase::getType(void) const
159 UInt32
CSMGLUTWindowBase::getContainerSize(void) const
161 return sizeof(CSMGLUTWindow
);
164 /*------------------------- decorator get ------------------------------*/
171 /*------------------------------ access -----------------------------------*/
173 SizeT
CSMGLUTWindowBase::getBinSize(ConstFieldMaskArg whichField
)
175 SizeT returnValue
= Inherited::getBinSize(whichField
);
181 void CSMGLUTWindowBase::copyToBin(BinaryDataHandler
&pMem
,
182 ConstFieldMaskArg whichField
)
184 Inherited::copyToBin(pMem
, whichField
);
188 void CSMGLUTWindowBase::copyFromBin(BinaryDataHandler
&pMem
,
189 ConstFieldMaskArg whichField
)
191 Inherited::copyFromBin(pMem
, whichField
);
195 //! create a new instance of the class
196 CSMGLUTWindowTransitPtr
CSMGLUTWindowBase::createLocal(BitVector bFlags
)
198 CSMGLUTWindowTransitPtr fc
;
200 if(getClassType().getPrototype() != NULL
)
202 FieldContainerTransitPtr tmpPtr
=
203 getClassType().getPrototype()-> shallowCopyLocal(bFlags
);
205 fc
= dynamic_pointer_cast
<CSMGLUTWindow
>(tmpPtr
);
211 //! create a new instance of the class, copy the container flags
212 CSMGLUTWindowTransitPtr
CSMGLUTWindowBase::createDependent(BitVector bFlags
)
214 CSMGLUTWindowTransitPtr fc
;
216 if(getClassType().getPrototype() != NULL
)
218 FieldContainerTransitPtr tmpPtr
=
219 getClassType().getPrototype()-> shallowCopyDependent(bFlags
);
221 fc
= dynamic_pointer_cast
<CSMGLUTWindow
>(tmpPtr
);
227 //! create a new instance of the class
228 CSMGLUTWindowTransitPtr
CSMGLUTWindowBase::create(void)
230 return createLocal();
233 CSMGLUTWindow
*CSMGLUTWindowBase::createEmptyLocal(BitVector bFlags
)
235 CSMGLUTWindow
*returnValue
;
237 newPtr
<CSMGLUTWindow
>(returnValue
, bFlags
);
239 returnValue
->_pFieldFlags
->_bNamespaceMask
&= ~bFlags
;
244 //! create an empty new instance of the class, do not copy the prototype
245 CSMGLUTWindow
*CSMGLUTWindowBase::createEmpty(void)
247 return createEmptyLocal();
251 FieldContainerTransitPtr
CSMGLUTWindowBase::shallowCopyLocal(
252 BitVector bFlags
) const
254 CSMGLUTWindow
*tmpPtr
;
256 newPtr(tmpPtr
, dynamic_cast<const CSMGLUTWindow
*>(this), bFlags
);
258 FieldContainerTransitPtr
returnValue(tmpPtr
);
260 tmpPtr
->_pFieldFlags
->_bNamespaceMask
&= ~bFlags
;
265 FieldContainerTransitPtr
CSMGLUTWindowBase::shallowCopyDependent(
266 BitVector bFlags
) const
268 CSMGLUTWindow
*tmpPtr
;
270 newPtr(tmpPtr
, dynamic_cast<const CSMGLUTWindow
*>(this), ~bFlags
);
272 FieldContainerTransitPtr
returnValue(tmpPtr
);
274 tmpPtr
->_pFieldFlags
->_bNamespaceMask
= bFlags
;
279 FieldContainerTransitPtr
CSMGLUTWindowBase::shallowCopy(void) const
281 return shallowCopyLocal();
287 /*------------------------- constructors ----------------------------------*/
289 CSMGLUTWindowBase::CSMGLUTWindowBase(void) :
294 CSMGLUTWindowBase::CSMGLUTWindowBase(const CSMGLUTWindowBase
&source
) :
300 /*-------------------------- destructors ----------------------------------*/
302 CSMGLUTWindowBase::~CSMGLUTWindowBase(void)
308 #ifdef OSG_MT_CPTR_ASPECT
309 void CSMGLUTWindowBase::execSyncV( FieldContainer
&oFrom
,
310 ConstFieldMaskArg whichField
,
311 AspectOffsetStore
&oOffsets
,
312 ConstFieldMaskArg syncMode
,
313 const UInt32 uiSyncInfo
)
315 CSMGLUTWindow
*pThis
= static_cast<CSMGLUTWindow
*>(this);
317 pThis
->execSync(static_cast<CSMGLUTWindow
*>(&oFrom
),
326 #ifdef OSG_MT_CPTR_ASPECT
327 FieldContainer
*CSMGLUTWindowBase::createAspectCopy(
328 const FieldContainer
*pRefAspect
) const
330 CSMGLUTWindow
*returnValue
;
332 newAspectCopy(returnValue
,
333 dynamic_cast<const CSMGLUTWindow
*>(pRefAspect
),
334 dynamic_cast<const CSMGLUTWindow
*>(this));
340 void CSMGLUTWindowBase::resolveLinks(void)
342 Inherited::resolveLinks();