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 ShaderExecutableChunk!
48 *****************************************************************************
49 \*****************************************************************************/
55 //! access the type of the class
57 OSG::FieldContainerType &ShaderExecutableChunkBase::getClassType(void)
62 //! access the numerical type of the class
64 OSG::UInt32 ShaderExecutableChunkBase::getClassTypeId(void)
70 OSG::UInt16 ShaderExecutableChunkBase::getClassGroupId(void)
72 return _type.getGroupId();
75 /*------------------------------ get -----------------------------------*/
77 //! Get the value of the ShaderExecutableChunk::_sfGeometryVerticesOut field.
80 UInt32 &ShaderExecutableChunkBase::editGeometryVerticesOut(void)
82 editSField(GeometryVerticesOutFieldMask);
84 return _sfGeometryVerticesOut.getValue();
87 //! Get the value of the ShaderExecutableChunk::_sfGeometryVerticesOut field.
89 UInt32 ShaderExecutableChunkBase::getGeometryVerticesOut(void) const
91 return _sfGeometryVerticesOut.getValue();
94 //! Set the value of the ShaderExecutableChunk::_sfGeometryVerticesOut field.
96 void ShaderExecutableChunkBase::setGeometryVerticesOut(const UInt32 value)
98 editSField(GeometryVerticesOutFieldMask);
100 _sfGeometryVerticesOut.setValue(value);
102 //! Get the value of the ShaderExecutableChunk::_sfGeometryInputType field.
105 GLenum &ShaderExecutableChunkBase::editGeometryInputType(void)
107 editSField(GeometryInputTypeFieldMask);
109 return _sfGeometryInputType.getValue();
112 //! Get the value of the ShaderExecutableChunk::_sfGeometryInputType field.
114 const GLenum &ShaderExecutableChunkBase::getGeometryInputType(void) const
116 return _sfGeometryInputType.getValue();
119 //! Set the value of the ShaderExecutableChunk::_sfGeometryInputType field.
121 void ShaderExecutableChunkBase::setGeometryInputType(const GLenum &value)
123 editSField(GeometryInputTypeFieldMask);
125 _sfGeometryInputType.setValue(value);
127 //! Get the value of the ShaderExecutableChunk::_sfGeometryOutputType field.
130 GLenum &ShaderExecutableChunkBase::editGeometryOutputType(void)
132 editSField(GeometryOutputTypeFieldMask);
134 return _sfGeometryOutputType.getValue();
137 //! Get the value of the ShaderExecutableChunk::_sfGeometryOutputType field.
139 const GLenum &ShaderExecutableChunkBase::getGeometryOutputType(void) const
141 return _sfGeometryOutputType.getValue();
144 //! Set the value of the ShaderExecutableChunk::_sfGeometryOutputType field.
146 void ShaderExecutableChunkBase::setGeometryOutputType(const GLenum &value)
148 editSField(GeometryOutputTypeFieldMask);
150 _sfGeometryOutputType.setValue(value);
152 //! Get the value of the ShaderExecutableChunk::_sfGLId field.
155 UInt32 &ShaderExecutableChunkBase::editGLId(void)
157 editSField(GLIdFieldMask);
159 return _sfGLId.getValue();
162 //! Get the value of the ShaderExecutableChunk::_sfGLId field.
164 UInt32 ShaderExecutableChunkBase::getGLId(void) const
166 return _sfGLId.getValue();
169 //! Set the value of the ShaderExecutableChunk::_sfGLId field.
171 void ShaderExecutableChunkBase::setGLId(const UInt32 value)
173 editSField(GLIdFieldMask);
175 _sfGLId.setValue(value);
177 //! Get the value of the ShaderExecutableChunk::_sfPointSize field.
180 bool &ShaderExecutableChunkBase::editPointSize(void)
182 editSField(PointSizeFieldMask);
184 return _sfPointSize.getValue();
187 //! Get the value of the ShaderExecutableChunk::_sfPointSize field.
189 bool ShaderExecutableChunkBase::getPointSize(void) const
191 return _sfPointSize.getValue();
194 //! Set the value of the ShaderExecutableChunk::_sfPointSize field.
196 void ShaderExecutableChunkBase::setPointSize(const bool value)
198 editSField(PointSizeFieldMask);
200 _sfPointSize.setValue(value);
203 //! Get the value of the \a index element the ShaderExecutableChunk::_mfVariableLocations field.
205 Int32 ShaderExecutableChunkBase::getVariableLocations(const UInt32 index) const
207 return _mfVariableLocations[index];
211 MFInt32 ::reference ShaderExecutableChunkBase::editVariableLocations(const UInt32 index)
213 editMField(VariableLocationsFieldMask, _mfVariableLocations);
215 return _mfVariableLocations[index];
218 //! Get the value of the \a index element the ShaderExecutableChunk::_mfProceduralVariableLocations field.
220 Int32 ShaderExecutableChunkBase::getProceduralVariableLocations(const UInt32 index) const
222 return _mfProceduralVariableLocations[index];
226 MFInt32 ::reference ShaderExecutableChunkBase::editProceduralVariableLocations(const UInt32 index)
228 editMField(ProceduralVariableLocationsFieldMask, _mfProceduralVariableLocations);
230 return _mfProceduralVariableLocations[index];
233 //! Get the value of the \a index element the ShaderExecutableChunk::_mfAttributes field.
235 const ShaderAttribute &ShaderExecutableChunkBase::getAttributes(const UInt32 index) const
237 return _mfAttributes[index];
241 MFShaderAttribute ::reference ShaderExecutableChunkBase::editAttributes(const UInt32 index)
243 editMField(AttributesFieldMask, _mfAttributes);
245 return _mfAttributes[index];
249 #ifdef OSG_MT_CPTR_ASPECT
251 void ShaderExecutableChunkBase::execSync ( ShaderExecutableChunkBase *pFrom,
252 ConstFieldMaskArg whichField,
253 AspectOffsetStore &oOffsets,
254 ConstFieldMaskArg syncMode,
255 const UInt32 uiSyncInfo)
257 Inherited::execSync(pFrom, whichField, oOffsets, syncMode, uiSyncInfo);
259 if(FieldBits::NoField != (VertexShaderFieldMask & whichField))
260 _mfVertexShader.syncWith(pFrom->_mfVertexShader,
265 if(FieldBits::NoField != (TessControlShaderFieldMask & whichField))
266 _mfTessControlShader.syncWith(pFrom->_mfTessControlShader,
271 if(FieldBits::NoField != (TessEvaluationShaderFieldMask & whichField))
272 _mfTessEvaluationShader.syncWith(pFrom->_mfTessEvaluationShader,
277 if(FieldBits::NoField != (GeometryShaderFieldMask & whichField))
278 _mfGeometryShader.syncWith(pFrom->_mfGeometryShader,
283 if(FieldBits::NoField != (FragmentShaderFieldMask & whichField))
284 _mfFragmentShader.syncWith(pFrom->_mfFragmentShader,
289 if(FieldBits::NoField != (VariablesFieldMask & whichField))
290 _sfVariables.syncWith(pFrom->_sfVariables);
292 if(FieldBits::NoField != (VariableLocationsFieldMask & whichField))
293 _mfVariableLocations.syncWith(pFrom->_mfVariableLocations,
298 if(FieldBits::NoField != (ProceduralVariableLocationsFieldMask & whichField))
299 _mfProceduralVariableLocations.syncWith(pFrom->_mfProceduralVariableLocations,
304 if(FieldBits::NoField != (GeometryVerticesOutFieldMask & whichField))
305 _sfGeometryVerticesOut.syncWith(pFrom->_sfGeometryVerticesOut);
307 if(FieldBits::NoField != (GeometryInputTypeFieldMask & whichField))
308 _sfGeometryInputType.syncWith(pFrom->_sfGeometryInputType);
310 if(FieldBits::NoField != (GeometryOutputTypeFieldMask & whichField))
311 _sfGeometryOutputType.syncWith(pFrom->_sfGeometryOutputType);
313 if(FieldBits::NoField != (AttributesFieldMask & whichField))
314 _mfAttributes.syncWith(pFrom->_mfAttributes,
319 if(FieldBits::NoField != (GLIdFieldMask & whichField))
320 _sfGLId.syncWith(pFrom->_sfGLId);
322 if(FieldBits::NoField != (PointSizeFieldMask & whichField))
323 _sfPointSize.syncWith(pFrom->_sfPointSize);
329 const Char8 *ShaderExecutableChunkBase::getClassname(void)
331 return "ShaderExecutableChunk";
333 OSG_GEN_CONTAINERPTR(ShaderExecutableChunk);