1 /*---------------------------------------------------------------------------*\
5 * Copyright (C) 2000-2013 by the OpenSG Forum *
7 * contact: dirk@opensg.org, gerrit.voss@vossg.org, carsten_neumann@gmx.net *
9 \*---------------------------------------------------------------------------*/
10 /*---------------------------------------------------------------------------*\
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. *
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. *
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. *
26 \*---------------------------------------------------------------------------*/
27 /*---------------------------------------------------------------------------*\
35 \*---------------------------------------------------------------------------*/
37 /*****************************************************************************\
38 *****************************************************************************
40 ** This file is automatically generated. **
42 ** Any changes made to this file WILL be lost when it is **
43 ** regenerated, which can become necessary at any time. **
45 ** Do not change this file, changes should be done in the derived **
46 ** class ComputeShaderAlgorithm!
48 *****************************************************************************
49 \*****************************************************************************/
55 //! access the type of the class
57 OSG::FieldContainerType &ComputeShaderAlgorithmBase::getClassType(void)
62 //! access the numerical type of the class
64 OSG::UInt32 ComputeShaderAlgorithmBase::getClassTypeId(void)
70 OSG::UInt16 ComputeShaderAlgorithmBase::getClassGroupId(void)
72 return _type.getGroupId();
75 /*------------------------------ get -----------------------------------*/
77 //! Get the value of the ComputeShaderAlgorithm::_sfDispatchConfig field.
80 Vec3i &ComputeShaderAlgorithmBase::editDispatchConfig(void)
82 editSField(DispatchConfigFieldMask);
84 return _sfDispatchConfig.getValue();
87 //! Get the value of the ComputeShaderAlgorithm::_sfDispatchConfig field.
89 const Vec3i &ComputeShaderAlgorithmBase::getDispatchConfig(void) const
91 return _sfDispatchConfig.getValue();
94 //! Set the value of the ComputeShaderAlgorithm::_sfDispatchConfig field.
96 void ComputeShaderAlgorithmBase::setDispatchConfig(const Vec3i &value)
98 editSField(DispatchConfigFieldMask);
100 _sfDispatchConfig.setValue(value);
102 //! Get the value of the ComputeShaderAlgorithm::_sfWorkGroupSize field.
105 Vec3i &ComputeShaderAlgorithmBase::editWorkGroupSize(void)
107 editSField(WorkGroupSizeFieldMask);
109 return _sfWorkGroupSize.getValue();
112 //! Get the value of the ComputeShaderAlgorithm::_sfWorkGroupSize field.
114 const Vec3i &ComputeShaderAlgorithmBase::getWorkGroupSize(void) const
116 return _sfWorkGroupSize.getValue();
119 //! Set the value of the ComputeShaderAlgorithm::_sfWorkGroupSize field.
121 void ComputeShaderAlgorithmBase::setWorkGroupSize(const Vec3i &value)
123 editSField(WorkGroupSizeFieldMask);
125 _sfWorkGroupSize.setValue(value);
127 //! Get the value of the ComputeShaderAlgorithm::_sfUseMemoryBarrier field.
130 bool &ComputeShaderAlgorithmBase::editUseMemoryBarrier(void)
132 editSField(UseMemoryBarrierFieldMask);
134 return _sfUseMemoryBarrier.getValue();
137 //! Get the value of the ComputeShaderAlgorithm::_sfUseMemoryBarrier field.
139 bool ComputeShaderAlgorithmBase::getUseMemoryBarrier(void) const
141 return _sfUseMemoryBarrier.getValue();
144 //! Set the value of the ComputeShaderAlgorithm::_sfUseMemoryBarrier field.
146 void ComputeShaderAlgorithmBase::setUseMemoryBarrier(const bool value)
148 editSField(UseMemoryBarrierFieldMask);
150 _sfUseMemoryBarrier.setValue(value);
152 //! Get the value of the ComputeShaderAlgorithm::_sfUseVariableWorkGroupSize field.
155 bool &ComputeShaderAlgorithmBase::editUseVariableWorkGroupSize(void)
157 editSField(UseVariableWorkGroupSizeFieldMask);
159 return _sfUseVariableWorkGroupSize.getValue();
162 //! Get the value of the ComputeShaderAlgorithm::_sfUseVariableWorkGroupSize field.
164 bool ComputeShaderAlgorithmBase::getUseVariableWorkGroupSize(void) const
166 return _sfUseVariableWorkGroupSize.getValue();
169 //! Set the value of the ComputeShaderAlgorithm::_sfUseVariableWorkGroupSize field.
171 void ComputeShaderAlgorithmBase::setUseVariableWorkGroupSize(const bool value)
173 editSField(UseVariableWorkGroupSizeFieldMask);
175 _sfUseVariableWorkGroupSize.setValue(value);
177 //! Get the value of the ComputeShaderAlgorithm::_sfMemoryBarrier field.
180 GLenum &ComputeShaderAlgorithmBase::editMemoryBarrier(void)
182 editSField(MemoryBarrierFieldMask);
184 return _sfMemoryBarrier.getValue();
187 //! Get the value of the ComputeShaderAlgorithm::_sfMemoryBarrier field.
189 const GLenum &ComputeShaderAlgorithmBase::getMemoryBarrier(void) const
191 return _sfMemoryBarrier.getValue();
194 //! Set the value of the ComputeShaderAlgorithm::_sfMemoryBarrier field.
196 void ComputeShaderAlgorithmBase::setMemoryBarrier(const GLenum &value)
198 editSField(MemoryBarrierFieldMask);
200 _sfMemoryBarrier.setValue(value);
205 #ifdef OSG_MT_CPTR_ASPECT
207 void ComputeShaderAlgorithmBase::execSync ( ComputeShaderAlgorithmBase *pFrom,
208 ConstFieldMaskArg whichField,
209 AspectOffsetStore &oOffsets,
210 ConstFieldMaskArg syncMode,
211 const UInt32 uiSyncInfo)
213 Inherited::execSync(pFrom, whichField, oOffsets, syncMode, uiSyncInfo);
215 if(FieldBits::NoField != (TextureImagesFieldMask & whichField))
216 _mfTextureImages.syncWith(pFrom->_mfTextureImages,
221 if(FieldBits::NoField != (ChunkMaterialFieldMask & whichField))
222 _sfChunkMaterial.syncWith(pFrom->_sfChunkMaterial);
224 if(FieldBits::NoField != (ComputeShaderFieldMask & whichField))
225 _sfComputeShader.syncWith(pFrom->_sfComputeShader);
227 if(FieldBits::NoField != (DispatchConfigFieldMask & whichField))
228 _sfDispatchConfig.syncWith(pFrom->_sfDispatchConfig);
230 if(FieldBits::NoField != (WorkGroupSizeFieldMask & whichField))
231 _sfWorkGroupSize.syncWith(pFrom->_sfWorkGroupSize);
233 if(FieldBits::NoField != (UseMemoryBarrierFieldMask & whichField))
234 _sfUseMemoryBarrier.syncWith(pFrom->_sfUseMemoryBarrier);
236 if(FieldBits::NoField != (UseVariableWorkGroupSizeFieldMask & whichField))
237 _sfUseVariableWorkGroupSize.syncWith(pFrom->_sfUseVariableWorkGroupSize);
239 if(FieldBits::NoField != (MemoryBarrierFieldMask & whichField))
240 _sfMemoryBarrier.syncWith(pFrom->_sfMemoryBarrier);
246 const Char8 *ComputeShaderAlgorithmBase::getClassname(void)
248 return "ComputeShaderAlgorithm";
250 OSG_GEN_CONTAINERPTR(ComputeShaderAlgorithm);