changed: gcc8 base update
[opensg.git] / Source / System / Window / FrameBufferObjects / OSGFrameBufferObjectBase.inl
blobd3f068c64c92ed91dc841741870fdb5a7e717ec7
1 /*---------------------------------------------------------------------------*\
2  *                                OpenSG                                     *
3  *                                                                           *
4  *                                                                           *
5  *               Copyright (C) 2000-2013 by the OpenSG Forum                 *
6  *                                                                           *
7  * contact: dirk@opensg.org, gerrit.voss@vossg.org, carsten_neumann@gmx.net  *
8  *                                                                           *
9 \*---------------------------------------------------------------------------*/
10 /*---------------------------------------------------------------------------*\
11  *                                License                                    *
12  *                                                                           *
13  * This library is free software; you can redistribute it and/or modify it   *
14  * under the terms of the GNU Library General Public License as published    *
15  * by the Free Software Foundation, version 2.                               *
16  *                                                                           *
17  * This library is distributed in the hope that it will be useful, but       *
18  * WITHOUT ANY WARRANTY; without even the implied warranty of                *
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU         *
20  * Library General Public License for more details.                          *
21  *                                                                           *
22  * You should have received a copy of the GNU Library General Public         *
23  * License along with this library; if not, write to the Free Software       *
24  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.                 *
25  *                                                                           *
26 \*---------------------------------------------------------------------------*/
27 /*---------------------------------------------------------------------------*\
28  *                                Changes                                    *
29  *                                                                           *
30  *                                                                           *
31  *                                                                           *
32  *                                                                           *
33  *                                                                           *
34  *                                                                           *
35 \*---------------------------------------------------------------------------*/
37 /*****************************************************************************\
38  *****************************************************************************
39  **                                                                         **
40  **                  This file is automatically generated.                  **
41  **                                                                         **
42  **          Any changes made to this file WILL be lost when it is          **
43  **           regenerated, which can become necessary at any time.          **
44  **                                                                         **
45  **     Do not change this file, changes should be done in the derived      **
46  **     class FrameBufferObject!
47  **                                                                         **
48  *****************************************************************************
49 \*****************************************************************************/
51 OSG_BEGIN_NAMESPACE
55 //! access the type of the class
56 inline
57 OSG::FieldContainerType &FrameBufferObjectBase::getClassType(void)
59     return _type;
62 //! access the numerical type of the class
63 inline
64 OSG::UInt32 FrameBufferObjectBase::getClassTypeId(void)
66     return _type.getId();
69 inline
70 OSG::UInt16 FrameBufferObjectBase::getClassGroupId(void)
72     return _type.getGroupId();
75 /*------------------------------ get -----------------------------------*/
77 //! Get the value of the FrameBufferObject::_sfGLId field.
79 inline
80 GLenum &FrameBufferObjectBase::editGLId(void)
82     editSField(GLIdFieldMask);
84     return _sfGLId.getValue();
87 //! Get the value of the FrameBufferObject::_sfGLId field.
88 inline
89 const GLenum &FrameBufferObjectBase::getGLId(void) const
91     return _sfGLId.getValue();
94 //! Set the value of the FrameBufferObject::_sfGLId field.
95 inline
96 void FrameBufferObjectBase::setGLId(const GLenum &value)
98     editSField(GLIdFieldMask);
100     _sfGLId.setValue(value);
102 //! Get the value of the FrameBufferObject::_sfMultiSampleGLId field.
104 inline
105 GLenum &FrameBufferObjectBase::editMultiSampleGLId(void)
107     editSField(MultiSampleGLIdFieldMask);
109     return _sfMultiSampleGLId.getValue();
112 //! Get the value of the FrameBufferObject::_sfMultiSampleGLId field.
113 inline
114 const GLenum &FrameBufferObjectBase::getMultiSampleGLId(void) const
116     return _sfMultiSampleGLId.getValue();
119 //! Set the value of the FrameBufferObject::_sfMultiSampleGLId field.
120 inline
121 void FrameBufferObjectBase::setMultiSampleGLId(const GLenum &value)
123     editSField(MultiSampleGLIdFieldMask);
125     _sfMultiSampleGLId.setValue(value);
127 //! Get the value of the FrameBufferObject::_sfWidth field.
129 inline
130 UInt16 &FrameBufferObjectBase::editWidth(void)
132     editSField(WidthFieldMask);
134     return _sfWidth.getValue();
137 //! Get the value of the FrameBufferObject::_sfWidth field.
138 inline
139       UInt16  FrameBufferObjectBase::getWidth(void) const
141     return _sfWidth.getValue();
144 //! Set the value of the FrameBufferObject::_sfWidth field.
145 inline
146 void FrameBufferObjectBase::setWidth(const UInt16 value)
148     editSField(WidthFieldMask);
150     _sfWidth.setValue(value);
152 //! Get the value of the FrameBufferObject::_sfHeight field.
154 inline
155 UInt16 &FrameBufferObjectBase::editHeight(void)
157     editSField(HeightFieldMask);
159     return _sfHeight.getValue();
162 //! Get the value of the FrameBufferObject::_sfHeight field.
163 inline
164       UInt16  FrameBufferObjectBase::getHeight(void) const
166     return _sfHeight.getValue();
169 //! Set the value of the FrameBufferObject::_sfHeight field.
170 inline
171 void FrameBufferObjectBase::setHeight(const UInt16 value)
173     editSField(HeightFieldMask);
175     _sfHeight.setValue(value);
177 //! Get the value of the FrameBufferObject::_sfPostProcessOnDeactivate field.
179 inline
180 bool &FrameBufferObjectBase::editPostProcessOnDeactivate(void)
182     editSField(PostProcessOnDeactivateFieldMask);
184     return _sfPostProcessOnDeactivate.getValue();
187 //! Get the value of the FrameBufferObject::_sfPostProcessOnDeactivate field.
188 inline
189       bool  FrameBufferObjectBase::getPostProcessOnDeactivate(void) const
191     return _sfPostProcessOnDeactivate.getValue();
194 //! Set the value of the FrameBufferObject::_sfPostProcessOnDeactivate field.
195 inline
196 void FrameBufferObjectBase::setPostProcessOnDeactivate(const bool value)
198     editSField(PostProcessOnDeactivateFieldMask);
200     _sfPostProcessOnDeactivate.setValue(value);
202 //! Get the value of the FrameBufferObject::_sfEnableMultiSample field.
204 inline
205 bool &FrameBufferObjectBase::editEnableMultiSample(void)
207     editSField(EnableMultiSampleFieldMask);
209     return _sfEnableMultiSample.getValue();
212 //! Get the value of the FrameBufferObject::_sfEnableMultiSample field.
213 inline
214       bool  FrameBufferObjectBase::getEnableMultiSample(void) const
216     return _sfEnableMultiSample.getValue();
219 //! Set the value of the FrameBufferObject::_sfEnableMultiSample field.
220 inline
221 void FrameBufferObjectBase::setEnableMultiSample(const bool value)
223     editSField(EnableMultiSampleFieldMask);
225     _sfEnableMultiSample.setValue(value);
227 //! Get the value of the FrameBufferObject::_sfColorSamples field.
229 inline
230 UInt32 &FrameBufferObjectBase::editColorSamples(void)
232     editSField(ColorSamplesFieldMask);
234     return _sfColorSamples.getValue();
237 //! Get the value of the FrameBufferObject::_sfColorSamples field.
238 inline
239       UInt32  FrameBufferObjectBase::getColorSamples(void) const
241     return _sfColorSamples.getValue();
244 //! Set the value of the FrameBufferObject::_sfColorSamples field.
245 inline
246 void FrameBufferObjectBase::setColorSamples(const UInt32 value)
248     editSField(ColorSamplesFieldMask);
250     _sfColorSamples.setValue(value);
252 //! Get the value of the FrameBufferObject::_sfCoverageSamples field.
254 inline
255 UInt32 &FrameBufferObjectBase::editCoverageSamples(void)
257     editSField(CoverageSamplesFieldMask);
259     return _sfCoverageSamples.getValue();
262 //! Get the value of the FrameBufferObject::_sfCoverageSamples field.
263 inline
264       UInt32  FrameBufferObjectBase::getCoverageSamples(void) const
266     return _sfCoverageSamples.getValue();
269 //! Set the value of the FrameBufferObject::_sfCoverageSamples field.
270 inline
271 void FrameBufferObjectBase::setCoverageSamples(const UInt32 value)
273     editSField(CoverageSamplesFieldMask);
275     _sfCoverageSamples.setValue(value);
277 //! Get the value of the FrameBufferObject::_sfFixedSampleLocation field.
279 inline
280 bool &FrameBufferObjectBase::editFixedSampleLocation(void)
282     editSField(FixedSampleLocationFieldMask);
284     return _sfFixedSampleLocation.getValue();
287 //! Get the value of the FrameBufferObject::_sfFixedSampleLocation field.
288 inline
289       bool  FrameBufferObjectBase::getFixedSampleLocation(void) const
291     return _sfFixedSampleLocation.getValue();
294 //! Set the value of the FrameBufferObject::_sfFixedSampleLocation field.
295 inline
296 void FrameBufferObjectBase::setFixedSampleLocation(const bool value)
298     editSField(FixedSampleLocationFieldMask);
300     _sfFixedSampleLocation.setValue(value);
304 //! Get the value of the \a index element the FrameBufferObject::_mfDrawBuffers field.
305 inline
306 const GLenum &FrameBufferObjectBase::getDrawBuffers(const UInt32 index) const
308     return _mfDrawBuffers[index];
311 inline
312 MFGLenum           ::reference FrameBufferObjectBase::editDrawBuffers(const UInt32 index)
314     editMField(DrawBuffersFieldMask, _mfDrawBuffers);
316     return _mfDrawBuffers[index];
321 #ifdef OSG_MT_CPTR_ASPECT
322 inline
323 void FrameBufferObjectBase::execSync (      FrameBufferObjectBase *pFrom,
324                                         ConstFieldMaskArg  whichField,
325                                         AspectOffsetStore &oOffsets,
326                                         ConstFieldMaskArg  syncMode,
327                                   const UInt32             uiSyncInfo)
329     Inherited::execSync(pFrom, whichField, oOffsets, syncMode, uiSyncInfo);
331     if(FieldBits::NoField != (GLIdFieldMask & whichField))
332         _sfGLId.syncWith(pFrom->_sfGLId);
334     if(FieldBits::NoField != (MultiSampleGLIdFieldMask & whichField))
335         _sfMultiSampleGLId.syncWith(pFrom->_sfMultiSampleGLId);
337     if(FieldBits::NoField != (ColorAttachmentsFieldMask & whichField))
338         _mfColorAttachments.syncWith(pFrom->_mfColorAttachments,
339                                 syncMode,
340                                 uiSyncInfo,
341                                 oOffsets);
343     if(FieldBits::NoField != (DrawBuffersFieldMask & whichField))
344         _mfDrawBuffers.syncWith(pFrom->_mfDrawBuffers,
345                                 syncMode,
346                                 uiSyncInfo,
347                                 oOffsets);
349     if(FieldBits::NoField != (DepthAttachmentFieldMask & whichField))
350         _sfDepthAttachment.syncWith(pFrom->_sfDepthAttachment);
352     if(FieldBits::NoField != (StencilAttachmentFieldMask & whichField))
353         _sfStencilAttachment.syncWith(pFrom->_sfStencilAttachment);
355     if(FieldBits::NoField != (WidthFieldMask & whichField))
356         _sfWidth.syncWith(pFrom->_sfWidth);
358     if(FieldBits::NoField != (HeightFieldMask & whichField))
359         _sfHeight.syncWith(pFrom->_sfHeight);
361     if(FieldBits::NoField != (PostProcessOnDeactivateFieldMask & whichField))
362         _sfPostProcessOnDeactivate.syncWith(pFrom->_sfPostProcessOnDeactivate);
364     if(FieldBits::NoField != (EnableMultiSampleFieldMask & whichField))
365         _sfEnableMultiSample.syncWith(pFrom->_sfEnableMultiSample);
367     if(FieldBits::NoField != (ColorSamplesFieldMask & whichField))
368         _sfColorSamples.syncWith(pFrom->_sfColorSamples);
370     if(FieldBits::NoField != (CoverageSamplesFieldMask & whichField))
371         _sfCoverageSamples.syncWith(pFrom->_sfCoverageSamples);
373     if(FieldBits::NoField != (FixedSampleLocationFieldMask & whichField))
374         _sfFixedSampleLocation.syncWith(pFrom->_sfFixedSampleLocation);
376     if(FieldBits::NoField != (MsaaColorAttachmentsFieldMask & whichField))
377         _mfMsaaColorAttachments.syncWith(pFrom->_mfMsaaColorAttachments,
378                                 syncMode,
379                                 uiSyncInfo,
380                                 oOffsets);
382     if(FieldBits::NoField != (MsaaDepthAttachmentFieldMask & whichField))
383         _sfMsaaDepthAttachment.syncWith(pFrom->_sfMsaaDepthAttachment);
385     if(FieldBits::NoField != (MsaaStencilAttachmentFieldMask & whichField))
386         _sfMsaaStencilAttachment.syncWith(pFrom->_sfMsaaStencilAttachment);
388 #endif
391 inline
392 const Char8 *FrameBufferObjectBase::getClassname(void)
394     return "FrameBufferObject";
396 OSG_GEN_CONTAINERPTR(FrameBufferObject);
398 OSG_END_NAMESPACE