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 MultiLightChunk!
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"
65 #include "OSGNode.h" // Beacon Class
67 #include "OSGMultiLightChunkBase.h"
68 #include "OSGMultiLightChunk.h"
70 #include <boost/bind.hpp>
74 /***************************************************************************\
76 \***************************************************************************/
78 /*! \class OSG::MultiLightChunk
79 See \ref PageSystemMultiLightChunk for a description.
81 This chunk represents a number of lights that are exposed to shader code
82 in form of a buffer in OpenGL std430 layout format.
83 A shader, binding a shader storage block to the very same binding point,
84 is expected to respect the corresponding block layout. The layout is regulated
85 by the hasXXX fields of the chunk. If one is set to false the corresponding
86 struct entry is omitted.
90 mat4 worldToLightSpaceMatrix;
91 mat4 lightToWorldSpaceMatrix;
92 mat4 eyeToLightSpaceMatrix;
93 mat4 lightToEyeSpaceMatrix;
94 mat4 lightPerspectiveMatrix;
95 mat4 invLightPerspectiveMatrix;
99 vec3 ambientIntensity;
100 vec3 diffuseIntensity;
101 vec3 specularIntensity;
103 float constantAttenuation;
104 float linearAttenuation;
105 float quadraticAttenuation;
110 float cosSpotlightAngle;
111 float spotlightAngle;
113 float innerSuperEllipsesWidth;
114 float innerSuperEllipsesHeight;
115 float outerSuperEllipsesWidth;
116 float outerSuperEllipsesHeight;
117 float superEllipsesRoundness;
118 float superEllipsesTwist;
123 layout (std430) buffer Lights
128 The chunk provides a convenient function that allows to adjust the struct layout
129 for standard OpenGL lights
135 vec3 ambientIntensity;
136 vec3 diffuseIntensity;
137 vec3 specularIntensity;
138 float constantAttenuation;
139 float linearAttenuation;
140 float quadraticAttenuation;
141 float cosSpotlightAngle;
147 or for simple range lights:
156 float cosSpotlightAngle;
162 /***************************************************************************\
163 * Field Documentation *
164 \***************************************************************************/
166 /*! \var bool MultiLightChunkBase::_sfHasWorldToLightSpaceMatrix
167 This flag determines if the worldToLightSpaceMatrix attribute is part of
168 the shader storage block, i.e. if the "mat4 worldToLightSpaceMatrix;"
169 entry is contained in the shader struct for the Light.
172 /*! \var bool MultiLightChunkBase::_sfHasLightToWorldSpaceMatrix
173 This flag determines if the lightToWorldSpaceMatrix attribute is part of
174 the shader storage block, i.e. if the "mat4 lightToWorldSpaceMatrix;"
175 entry is contained in the shader struct for the Light.
178 /*! \var bool MultiLightChunkBase::_sfHasEyeToLightSpaceMatrix
179 This flag determines if the eyeToLightSpaceMatrix attribute is part of
180 the shader storage block, i.e. if the "mat4 eyeToLightSpaceMatrix;"
181 entry is contained in the shader struct for the Light.
182 Attention: If this flag is set the light shader storage block has to
183 be updated with every redraw operation.
186 /*! \var bool MultiLightChunkBase::_sfHasLightToEyeSpaceMatrix
187 This flag determines if the lightToEyeSpaceMatrix attribute is part of
188 the shader storage block, i.e. if the "mat4 lightToEyeSpaceMatrix;"
189 entry is contained in the shader struct for the Light.
190 Attention: If this flag is set the light shader storage block has to
191 be updated with every redraw operation.
194 /*! \var bool MultiLightChunkBase::_sfHasLightPerspectiveMatrix
195 This flag determines if the lightPerspectiveMatrix attribute is part of
196 the shader storage block, i.e. if the "mat4 lightPerspectiveMatrix;"
197 entry is contained in the shader struct for the Light.
200 /*! \var bool MultiLightChunkBase::_sfHasInvLightPerspectiveMatrix
201 This flag determines if the lightToEyeSpaceMatrix attribute is part of
202 the shader storage block, i.e. if the "mat4 invLightToEyeSpaceMatrix;"
203 entry is contained in the shader struct for the Light.
206 /*! \var bool MultiLightChunkBase::_sfHasColor
207 This flag determines if the color attribute is part of the shader storage block, i.e.
208 if the "vec3 color;" entry is contained in the shader struct for the Light.
211 /*! \var bool MultiLightChunkBase::_sfHasIntensity
212 This flag determines if the intensity attribute is part of the shader storage block, i.e.
213 if the "float intensity;" entry is contained in the shader struct for the Light.
216 /*! \var bool MultiLightChunkBase::_sfHasSeparateIntensities
217 This flag determines if the color intensity attributes are part of the shader storage block, i.e.
218 if the "vec3 Ia;", "vec3 Id;" and "vec3 Is;" entries are contained in the shader struct for the Light.
221 /*! \var bool MultiLightChunkBase::_sfHasAttenuation
222 This flag determines if the attenuation attributes are part of the shader storage block, i.e.
223 if the "float constantAttenuation;", "float linearAttenuation;" and "float quadraticAttenuation;"
224 entries are contained in the shader struct for the Light.
227 /*! \var bool MultiLightChunkBase::_sfAutoCalcRanges
228 If this flag is active and the lights have attenuations, then the cut on and cut off ranges
229 are automatically calculated. They are, however, not provided automatically to the shader.
230 For that, you have to set the hasRangeCutOn and hasRangeCutOff flags, respectively.
233 /*! \var bool MultiLightChunkBase::_sfHasRangeCutOn
234 This flag determines if the rangeCutOn attribute is part of the shader storage block, i.e.
235 if the "float rangeCutOn;" entry is contained in the shader struct for the Light.
238 /*! \var bool MultiLightChunkBase::_sfHasRangeCutOff
239 This flag determines if the hasRangeCutOff attribute is part of the shader storage block, i.e.
240 if the "float hasRangeCutOff;" entry is contained in the shader struct for the Light.
243 /*! \var bool MultiLightChunkBase::_sfHasRangeNearZone
244 This flag determines if the hasRangeNearZone attribute is part of the shader storage block, i.e.
245 if the "float hasRangeNearZone;" entry is contained in the shader struct for the Light.
248 /*! \var bool MultiLightChunkBase::_sfHasRangeFarZone
249 This flag determines if the hasRangeFarZone attribute is part of the shader storage block, i.e.
250 if the "float hasRangeFarZone;" entry is contained in the shader struct for the Light.
253 /*! \var bool MultiLightChunkBase::_sfHasCosSpotlightAngle
254 This flag determines if the cosine of the spot light angle attribute is part of the shader storage block, i.e.
255 if the "float cosSpotlightAngle;" entry is contained in the shader struct for the Light. If neither this flag
256 nor the hasSpotlightAngle flag is true, then this flag is treated as if it has value true.
259 /*! \var bool MultiLightChunkBase::_sfHasSpotlightAngle
260 This flag determines if the spot light angle attribute is part of the shader storage block, i.e.
261 if the "float spotlightAngle;" entry is contained in the shader struct for the Light. If neither this flag
262 nor the hasCosSpotlightAngle flag is true, then the hasCosSpotlightAngle flag is treated as if it has value true.
265 /*! \var bool MultiLightChunkBase::_sfHasSpotExponent
266 This flag determines if the spot expenent attribute is part of the shader storage block, i.e.
267 if the "float spotExponent;" entry is contained in the shader struct for the Light.
270 /*! \var bool MultiLightChunkBase::_sfHasCinemaLight
271 This flag determines if the cinema light attributes are part of the shader storage block, i.e.
272 if the "float innerSuperEllipsesWidth;", ... entries are contained in the shader struct for the Light.
273 If true this flag overrides the hasRangeCutOn, hasRangeCutOff, hasRangeNearZone and hasRangeFarZone
274 flags, because cinema lights are described the corresponding attributes.
275 See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html
276 http://www.yaldex.com/open-gl/ch12lev1sec4.html
277 https://en.wikipedia.org/wiki/Superellipse
280 /*! \var Pnt3f MultiLightChunkBase::_mfPosition
281 The light's position for point and spotlights in beacon space.
284 /*! \var Vec3f MultiLightChunkBase::_mfDirection
285 The light's direction for directional and spotlights in beacon space.
288 /*! \var Color3f MultiLightChunkBase::_mfColor
292 /*! \var Real32 MultiLightChunkBase::_mfIntensity
293 The light's intensity.
296 /*! \var Vec3f MultiLightChunkBase::_mfAmbientIntensity
297 The light's ambient intensity.
300 /*! \var Vec3f MultiLightChunkBase::_mfDiffuseIntensity
301 The light's diffuse intensity.
304 /*! \var Vec3f MultiLightChunkBase::_mfSpecularIntensity
305 The light's specular intensity.
308 /*! \var Vec3f MultiLightChunkBase::_mfAttenuation
309 The light's attenuation consiting of the constant, linear and quadratic attenuation parts.
312 /*! \var Real32 MultiLightChunkBase::_mfSpotlightAngle
313 The spot angle in degree.
316 /*! \var Real32 MultiLightChunkBase::_mfSpotExponent
317 The spot angle in degree.
320 /*! \var Real32 MultiLightChunkBase::_mfInnerSuperEllipsesWidth
321 The cinema light is described among others by an inner ellipses. This is
322 the width of this ellipse.
323 See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html
324 http://www.yaldex.com/open-gl/ch12lev1sec4.html
325 https://en.wikipedia.org/wiki/Superellipse
328 /*! \var Real32 MultiLightChunkBase::_mfInnerSuperEllipsesHeight
329 The cinema light is described among others by an inner ellipses. This is
330 the height of this ellipse.
331 See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html
332 http://www.yaldex.com/open-gl/ch12lev1sec4.html
333 https://en.wikipedia.org/wiki/Superellipse
336 /*! \var Real32 MultiLightChunkBase::_mfOuterSuperEllipsesWidth
337 The cinema light is described among others by an outer ellipses. This is
338 the width of this ellipse.
339 See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html
340 http://www.yaldex.com/open-gl/ch12lev1sec4.html
341 https://en.wikipedia.org/wiki/Superellipse
344 /*! \var Real32 MultiLightChunkBase::_mfOuterSuperEllipsesHeight
345 The cinema light is described among others by an outer ellipses. This is
346 the height of this ellipse.
347 See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html
348 http://www.yaldex.com/open-gl/ch12lev1sec4.html
349 https://en.wikipedia.org/wiki/Superellipse
352 /*! \var Real32 MultiLightChunkBase::_mfSuperEllipsesRoundness
353 The cinema light is described among others by a roundness parameter.
354 See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html
355 http://www.yaldex.com/open-gl/ch12lev1sec4.html
356 https://en.wikipedia.org/wiki/Superellipse
359 /*! \var Real32 MultiLightChunkBase::_mfSuperEllipsesTwist
360 The twist angle in degree by which the superellipses is rotatet in the xy-plane.
363 /*! \var Real32 MultiLightChunkBase::_mfRangeCutOn
364 The cinema light is described among others by a rangeCutOn parameter.
365 In the interval rangeCutOn to rangeCutOff the lighted fragments are
367 See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html
368 http://www.yaldex.com/open-gl/ch12lev1sec4.html
369 https://en.wikipedia.org/wiki/Superellipse
372 /*! \var Real32 MultiLightChunkBase::_mfRangeCutOff
373 The cinema light is described among others by a rangeCutOff parameter.
374 In the interval rangeCutOn to rangeCutOff the lighted fragments are
376 See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html
377 http://www.yaldex.com/open-gl/ch12lev1sec4.html
378 https://en.wikipedia.org/wiki/Superellipse
381 /*! \var Real32 MultiLightChunkBase::_mfRangeNearZone
382 The cinema light is described among others by a rangeNearZone parameter.
383 In the interval rangeCutOn-rangeNearZone to rangeCutOn the lighted fragments are
385 See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html
386 http://www.yaldex.com/open-gl/ch12lev1sec4.html
387 https://en.wikipedia.org/wiki/Superellipse
390 /*! \var Real32 MultiLightChunkBase::_mfRangeFarZone
391 In the interval rangeCutOff to rangeCutOff+rangeFarZone the lighted fragments are
395 /*! \var UInt8 MultiLightChunkBase::_mfType
396 Stores the light's type. This can be any of the set {POINT_LIGHT, DIRECTIONAL_LIGHT, SPOT_LIGHT, CINEMA_LIGHT}.
399 /*! \var bool MultiLightChunkBase::_mfEnabled
400 The on/off state of the light.
403 /*! \var Node * MultiLightChunkBase::_mfBeacon
404 The light's beacon determining its position or direction.
407 /*! \var Matrix MultiLightChunkBase::_mfBeaconMatrix
408 The beacon matrices used for the last render pass.
411 /*! \var bool MultiLightChunkBase::_sfEyeSpace
412 The lights position and direction are transformed to eye space before loading into the shader.
413 On default they are provided in world space.
416 /*! \var Real32 MultiLightChunkBase::_sfLastCamNear
417 The camera last near value.
420 /*! \var Real32 MultiLightChunkBase::_sfLastCamFar
421 The camera last far value.
424 /*! \var Matrix MultiLightChunkBase::_sfLastCamToWorld
425 The camera last to world matrix.
428 /*! \var std::string MultiLightChunkBase::_sfLightBlockName
429 The shader storage buffer block name for the light buffer.
432 /*! \var std::string MultiLightChunkBase::_sfLightVariableName
433 The shader variable name for the light buffer.
437 /***************************************************************************\
438 * FieldType/FieldTrait Instantiation *
439 \***************************************************************************/
441 #if !defined(OSG_DO_DOC) || defined(OSG_DOC_DEV)
442 PointerType FieldTraits
<MultiLightChunk
*, nsOSG
>::_type(
443 "MultiLightChunkPtr",
444 "ShaderStorageBufferObjStdLayoutChunkPtr",
445 MultiLightChunk::getClassType(),
449 OSG_FIELDTRAITS_GETTYPE_NS(MultiLightChunk
*, nsOSG
)
451 OSG_EXPORT_PTR_SFIELD_FULL(PointerSField
,
455 OSG_EXPORT_PTR_MFIELD_FULL(PointerMField
,
459 /***************************************************************************\
460 * Field Description *
461 \***************************************************************************/
463 void MultiLightChunkBase::classDescInserter(TypeObject
&oType
)
465 FieldDescriptionBase
*pDesc
= NULL
;
468 pDesc
= new SFBool::Description(
469 SFBool::getClassType(),
470 "hasWorldToLightSpaceMatrix",
471 "This flag determines if the worldToLightSpaceMatrix attribute is part of \n"
472 "the shader storage block, i.e. if the \"mat4 worldToLightSpaceMatrix;\" \n"
473 "entry is contained in the shader struct for the Light.\n",
474 HasWorldToLightSpaceMatrixFieldId
, HasWorldToLightSpaceMatrixFieldMask
,
476 (Field::SFDefaultFlags
| Field::FStdAccess
),
477 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasWorldToLightSpaceMatrix
),
478 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasWorldToLightSpaceMatrix
));
480 oType
.addInitialDesc(pDesc
);
482 pDesc
= new SFBool::Description(
483 SFBool::getClassType(),
484 "hasLightToWorldSpaceMatrix",
485 "This flag determines if the lightToWorldSpaceMatrix attribute is part of \n"
486 "the shader storage block, i.e. if the \"mat4 lightToWorldSpaceMatrix;\" \n"
487 "entry is contained in the shader struct for the Light.\n",
488 HasLightToWorldSpaceMatrixFieldId
, HasLightToWorldSpaceMatrixFieldMask
,
490 (Field::SFDefaultFlags
| Field::FStdAccess
),
491 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasLightToWorldSpaceMatrix
),
492 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasLightToWorldSpaceMatrix
));
494 oType
.addInitialDesc(pDesc
);
496 pDesc
= new SFBool::Description(
497 SFBool::getClassType(),
498 "hasEyeToLightSpaceMatrix",
499 "This flag determines if the eyeToLightSpaceMatrix attribute is part of \n"
500 "the shader storage block, i.e. if the \"mat4 eyeToLightSpaceMatrix;\" \n"
501 "entry is contained in the shader struct for the Light.\n"
502 "Attention: If this flag is set the light shader storage block has to\n"
503 "be updated with every redraw operation.\n",
504 HasEyeToLightSpaceMatrixFieldId
, HasEyeToLightSpaceMatrixFieldMask
,
506 (Field::SFDefaultFlags
| Field::FStdAccess
),
507 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasEyeToLightSpaceMatrix
),
508 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasEyeToLightSpaceMatrix
));
510 oType
.addInitialDesc(pDesc
);
512 pDesc
= new SFBool::Description(
513 SFBool::getClassType(),
514 "hasLightToEyeSpaceMatrix",
515 "This flag determines if the lightToEyeSpaceMatrix attribute is part of \n"
516 "the shader storage block, i.e. if the \"mat4 lightToEyeSpaceMatrix;\" \n"
517 "entry is contained in the shader struct for the Light.\n"
518 "Attention: If this flag is set the light shader storage block has to\n"
519 "be updated with every redraw operation.\n",
520 HasLightToEyeSpaceMatrixFieldId
, HasLightToEyeSpaceMatrixFieldMask
,
522 (Field::SFDefaultFlags
| Field::FStdAccess
),
523 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasLightToEyeSpaceMatrix
),
524 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasLightToEyeSpaceMatrix
));
526 oType
.addInitialDesc(pDesc
);
528 pDesc
= new SFBool::Description(
529 SFBool::getClassType(),
530 "hasLightPerspectiveMatrix",
531 "This flag determines if the lightPerspectiveMatrix attribute is part of \n"
532 "the shader storage block, i.e. if the \"mat4 lightPerspectiveMatrix;\" \n"
533 "entry is contained in the shader struct for the Light.\n",
534 HasLightPerspectiveMatrixFieldId
, HasLightPerspectiveMatrixFieldMask
,
536 (Field::SFDefaultFlags
| Field::FStdAccess
),
537 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasLightPerspectiveMatrix
),
538 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasLightPerspectiveMatrix
));
540 oType
.addInitialDesc(pDesc
);
542 pDesc
= new SFBool::Description(
543 SFBool::getClassType(),
544 "hasInvLightPerspectiveMatrix",
545 "This flag determines if the lightToEyeSpaceMatrix attribute is part of \n"
546 "the shader storage block, i.e. if the \"mat4 invLightToEyeSpaceMatrix;\" \n"
547 "entry is contained in the shader struct for the Light.\n",
548 HasInvLightPerspectiveMatrixFieldId
, HasInvLightPerspectiveMatrixFieldMask
,
550 (Field::SFDefaultFlags
| Field::FStdAccess
),
551 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasInvLightPerspectiveMatrix
),
552 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasInvLightPerspectiveMatrix
));
554 oType
.addInitialDesc(pDesc
);
556 pDesc
= new SFBool::Description(
557 SFBool::getClassType(),
559 "This flag determines if the color attribute is part of the shader storage block, i.e.\n"
560 "if the \"vec3 color;\" entry is contained in the shader struct for the Light.\n",
561 HasColorFieldId
, HasColorFieldMask
,
563 (Field::SFDefaultFlags
| Field::FStdAccess
),
564 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasColor
),
565 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasColor
));
567 oType
.addInitialDesc(pDesc
);
569 pDesc
= new SFBool::Description(
570 SFBool::getClassType(),
572 "This flag determines if the intensity attribute is part of the shader storage block, i.e.\n"
573 "if the \"float intensity;\" entry is contained in the shader struct for the Light.\n",
574 HasIntensityFieldId
, HasIntensityFieldMask
,
576 (Field::SFDefaultFlags
| Field::FStdAccess
),
577 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasIntensity
),
578 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasIntensity
));
580 oType
.addInitialDesc(pDesc
);
582 pDesc
= new SFBool::Description(
583 SFBool::getClassType(),
584 "hasSeparateIntensities",
585 "This flag determines if the color intensity attributes are part of the shader storage block, i.e.\n"
586 "if the \"vec3 Ia;\", \"vec3 Id;\" and \"vec3 Is;\" entries are contained in the shader struct for the Light.\n",
587 HasSeparateIntensitiesFieldId
, HasSeparateIntensitiesFieldMask
,
589 (Field::SFDefaultFlags
| Field::FStdAccess
),
590 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasSeparateIntensities
),
591 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasSeparateIntensities
));
593 oType
.addInitialDesc(pDesc
);
595 pDesc
= new SFBool::Description(
596 SFBool::getClassType(),
598 "This flag determines if the attenuation attributes are part of the shader storage block, i.e.\n"
599 "if the \"float constantAttenuation;\", \"float linearAttenuation;\" and \"float quadraticAttenuation;\"\n"
600 "entries are contained in the shader struct for the Light.\n",
601 HasAttenuationFieldId
, HasAttenuationFieldMask
,
603 (Field::SFDefaultFlags
| Field::FStdAccess
),
604 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasAttenuation
),
605 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasAttenuation
));
607 oType
.addInitialDesc(pDesc
);
609 pDesc
= new SFBool::Description(
610 SFBool::getClassType(),
612 "If this flag is active and the lights have attenuations, then the cut on and cut off ranges\n"
613 "are automatically calculated. They are, however, not provided automatically to the shader.\n"
614 "For that, you have to set the hasRangeCutOn and hasRangeCutOff flags, respectively.\n",
615 AutoCalcRangesFieldId
, AutoCalcRangesFieldMask
,
617 (Field::SFDefaultFlags
| Field::FStdAccess
),
618 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleAutoCalcRanges
),
619 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleAutoCalcRanges
));
621 oType
.addInitialDesc(pDesc
);
623 pDesc
= new SFBool::Description(
624 SFBool::getClassType(),
626 "This flag determines if the rangeCutOn attribute is part of the shader storage block, i.e.\n"
627 "if the \"float rangeCutOn;\" entry is contained in the shader struct for the Light.\n",
628 HasRangeCutOnFieldId
, HasRangeCutOnFieldMask
,
630 (Field::SFDefaultFlags
| Field::FStdAccess
),
631 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasRangeCutOn
),
632 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasRangeCutOn
));
634 oType
.addInitialDesc(pDesc
);
636 pDesc
= new SFBool::Description(
637 SFBool::getClassType(),
639 "This flag determines if the hasRangeCutOff attribute is part of the shader storage block, i.e.\n"
640 "if the \"float hasRangeCutOff;\" entry is contained in the shader struct for the Light.\n",
641 HasRangeCutOffFieldId
, HasRangeCutOffFieldMask
,
643 (Field::SFDefaultFlags
| Field::FStdAccess
),
644 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasRangeCutOff
),
645 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasRangeCutOff
));
647 oType
.addInitialDesc(pDesc
);
649 pDesc
= new SFBool::Description(
650 SFBool::getClassType(),
652 "This flag determines if the hasRangeNearZone attribute is part of the shader storage block, i.e.\n"
653 "if the \"float hasRangeNearZone;\" entry is contained in the shader struct for the Light.\n",
654 HasRangeNearZoneFieldId
, HasRangeNearZoneFieldMask
,
656 (Field::SFDefaultFlags
| Field::FStdAccess
),
657 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasRangeNearZone
),
658 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasRangeNearZone
));
660 oType
.addInitialDesc(pDesc
);
662 pDesc
= new SFBool::Description(
663 SFBool::getClassType(),
665 "This flag determines if the hasRangeFarZone attribute is part of the shader storage block, i.e.\n"
666 "if the \"float hasRangeFarZone;\" entry is contained in the shader struct for the Light.\n",
667 HasRangeFarZoneFieldId
, HasRangeFarZoneFieldMask
,
669 (Field::SFDefaultFlags
| Field::FStdAccess
),
670 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasRangeFarZone
),
671 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasRangeFarZone
));
673 oType
.addInitialDesc(pDesc
);
675 pDesc
= new SFBool::Description(
676 SFBool::getClassType(),
677 "hasCosSpotlightAngle",
678 "This flag determines if the cosine of the spot light angle attribute is part of the shader storage block, i.e.\n"
679 "if the \"float cosSpotlightAngle;\" entry is contained in the shader struct for the Light. If neither this flag\n"
680 "nor the hasSpotlightAngle flag is true, then this flag is treated as if it has value true.\n",
681 HasCosSpotlightAngleFieldId
, HasCosSpotlightAngleFieldMask
,
683 (Field::SFDefaultFlags
| Field::FStdAccess
),
684 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasCosSpotlightAngle
),
685 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasCosSpotlightAngle
));
687 oType
.addInitialDesc(pDesc
);
689 pDesc
= new SFBool::Description(
690 SFBool::getClassType(),
692 "This flag determines if the spot light angle attribute is part of the shader storage block, i.e.\n"
693 "if the \"float spotlightAngle;\" entry is contained in the shader struct for the Light. If neither this flag\n"
694 "nor the hasCosSpotlightAngle flag is true, then the hasCosSpotlightAngle flag is treated as if it has value true.\n",
695 HasSpotlightAngleFieldId
, HasSpotlightAngleFieldMask
,
697 (Field::SFDefaultFlags
| Field::FStdAccess
),
698 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasSpotlightAngle
),
699 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasSpotlightAngle
));
701 oType
.addInitialDesc(pDesc
);
703 pDesc
= new SFBool::Description(
704 SFBool::getClassType(),
706 "This flag determines if the spot expenent attribute is part of the shader storage block, i.e.\n"
707 "if the \"float spotExponent;\" entry is contained in the shader struct for the Light.\n",
708 HasSpotExponentFieldId
, HasSpotExponentFieldMask
,
710 (Field::SFDefaultFlags
| Field::FStdAccess
),
711 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasSpotExponent
),
712 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasSpotExponent
));
714 oType
.addInitialDesc(pDesc
);
716 pDesc
= new SFBool::Description(
717 SFBool::getClassType(),
719 "This flag determines if the cinema light attributes are part of the shader storage block, i.e.\n"
720 "if the \"float innerSuperEllipsesWidth;\", ... entries are contained in the shader struct for the Light.\n"
721 "If true this flag overrides the hasRangeCutOn, hasRangeCutOff, hasRangeNearZone and hasRangeFarZone\n"
722 "flags, because cinema lights are described the corresponding attributes.\n"
723 "See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
724 "http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
725 "https://en.wikipedia.org/wiki/Superellipse\n",
726 HasCinemaLightFieldId
, HasCinemaLightFieldMask
,
728 (Field::SFDefaultFlags
| Field::FStdAccess
),
729 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleHasCinemaLight
),
730 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleHasCinemaLight
));
732 oType
.addInitialDesc(pDesc
);
734 pDesc
= new MFPnt3f::Description(
735 MFPnt3f::getClassType(),
737 "The light's position for point and spotlights in beacon space.\n",
738 PositionFieldId
, PositionFieldMask
,
740 (Field::MFDefaultFlags
| Field::FStdAccess
),
741 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandlePosition
),
742 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandlePosition
));
744 oType
.addInitialDesc(pDesc
);
746 pDesc
= new MFVec3f::Description(
747 MFVec3f::getClassType(),
749 "The light's direction for directional and spotlights in beacon space.\n",
750 DirectionFieldId
, DirectionFieldMask
,
752 (Field::MFDefaultFlags
| Field::FStdAccess
),
753 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleDirection
),
754 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleDirection
));
756 oType
.addInitialDesc(pDesc
);
758 pDesc
= new MFColor3f::Description(
759 MFColor3f::getClassType(),
761 "The light's color.\n",
762 ColorFieldId
, ColorFieldMask
,
764 (Field::MFDefaultFlags
| Field::FStdAccess
),
765 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleColor
),
766 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleColor
));
768 oType
.addInitialDesc(pDesc
);
770 pDesc
= new MFReal32::Description(
771 MFReal32::getClassType(),
773 "The light's intensity.\n",
774 IntensityFieldId
, IntensityFieldMask
,
776 (Field::MFDefaultFlags
| Field::FStdAccess
),
777 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleIntensity
),
778 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleIntensity
));
780 oType
.addInitialDesc(pDesc
);
782 pDesc
= new MFVec3f::Description(
783 MFVec3f::getClassType(),
785 "The light's ambient intensity.\n",
786 AmbientIntensityFieldId
, AmbientIntensityFieldMask
,
788 (Field::MFDefaultFlags
| Field::FStdAccess
),
789 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleAmbientIntensity
),
790 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleAmbientIntensity
));
792 oType
.addInitialDesc(pDesc
);
794 pDesc
= new MFVec3f::Description(
795 MFVec3f::getClassType(),
797 "The light's diffuse intensity.\n",
798 DiffuseIntensityFieldId
, DiffuseIntensityFieldMask
,
800 (Field::MFDefaultFlags
| Field::FStdAccess
),
801 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleDiffuseIntensity
),
802 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleDiffuseIntensity
));
804 oType
.addInitialDesc(pDesc
);
806 pDesc
= new MFVec3f::Description(
807 MFVec3f::getClassType(),
809 "The light's specular intensity.\n",
810 SpecularIntensityFieldId
, SpecularIntensityFieldMask
,
812 (Field::MFDefaultFlags
| Field::FStdAccess
),
813 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleSpecularIntensity
),
814 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleSpecularIntensity
));
816 oType
.addInitialDesc(pDesc
);
818 pDesc
= new MFVec3f::Description(
819 MFVec3f::getClassType(),
821 "The light's attenuation consiting of the constant, linear and quadratic attenuation parts.\n",
822 AttenuationFieldId
, AttenuationFieldMask
,
824 (Field::MFDefaultFlags
| Field::FStdAccess
),
825 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleAttenuation
),
826 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleAttenuation
));
828 oType
.addInitialDesc(pDesc
);
830 pDesc
= new MFReal32::Description(
831 MFReal32::getClassType(),
833 "The spot angle in degree.\n",
834 SpotlightAngleFieldId
, SpotlightAngleFieldMask
,
836 (Field::MFDefaultFlags
| Field::FStdAccess
),
837 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleSpotlightAngle
),
838 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleSpotlightAngle
));
840 oType
.addInitialDesc(pDesc
);
842 pDesc
= new MFReal32::Description(
843 MFReal32::getClassType(),
845 "The spot angle in degree.\n",
846 SpotExponentFieldId
, SpotExponentFieldMask
,
848 (Field::MFDefaultFlags
| Field::FStdAccess
),
849 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleSpotExponent
),
850 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleSpotExponent
));
852 oType
.addInitialDesc(pDesc
);
854 pDesc
= new MFReal32::Description(
855 MFReal32::getClassType(),
856 "innerSuperEllipsesWidth",
857 "The cinema light is described among others by an inner ellipses. This is\n"
858 "the width of this ellipse.\n"
859 "See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
860 "http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
861 "https://en.wikipedia.org/wiki/Superellipse\n",
862 InnerSuperEllipsesWidthFieldId
, InnerSuperEllipsesWidthFieldMask
,
864 (Field::MFDefaultFlags
| Field::FStdAccess
),
865 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleInnerSuperEllipsesWidth
),
866 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleInnerSuperEllipsesWidth
));
868 oType
.addInitialDesc(pDesc
);
870 pDesc
= new MFReal32::Description(
871 MFReal32::getClassType(),
872 "innerSuperEllipsesHeight",
873 "The cinema light is described among others by an inner ellipses. This is\n"
874 "the height of this ellipse.\n"
875 "See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
876 "http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
877 "https://en.wikipedia.org/wiki/Superellipse\n",
878 InnerSuperEllipsesHeightFieldId
, InnerSuperEllipsesHeightFieldMask
,
880 (Field::MFDefaultFlags
| Field::FStdAccess
),
881 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleInnerSuperEllipsesHeight
),
882 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleInnerSuperEllipsesHeight
));
884 oType
.addInitialDesc(pDesc
);
886 pDesc
= new MFReal32::Description(
887 MFReal32::getClassType(),
888 "outerSuperEllipsesWidth",
889 "The cinema light is described among others by an outer ellipses. This is\n"
890 "the width of this ellipse.\n"
891 "See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
892 "http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
893 "https://en.wikipedia.org/wiki/Superellipse\n",
894 OuterSuperEllipsesWidthFieldId
, OuterSuperEllipsesWidthFieldMask
,
896 (Field::MFDefaultFlags
| Field::FStdAccess
),
897 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleOuterSuperEllipsesWidth
),
898 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleOuterSuperEllipsesWidth
));
900 oType
.addInitialDesc(pDesc
);
902 pDesc
= new MFReal32::Description(
903 MFReal32::getClassType(),
904 "outerSuperEllipsesHeight",
905 "The cinema light is described among others by an outer ellipses. This is\n"
906 "the height of this ellipse.\n"
907 "See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
908 "http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
909 "https://en.wikipedia.org/wiki/Superellipse\n",
910 OuterSuperEllipsesHeightFieldId
, OuterSuperEllipsesHeightFieldMask
,
912 (Field::MFDefaultFlags
| Field::FStdAccess
),
913 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleOuterSuperEllipsesHeight
),
914 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleOuterSuperEllipsesHeight
));
916 oType
.addInitialDesc(pDesc
);
918 pDesc
= new MFReal32::Description(
919 MFReal32::getClassType(),
920 "superEllipsesRoundness",
921 "The cinema light is described among others by a roundness parameter. \n"
922 "See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
923 "http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
924 "https://en.wikipedia.org/wiki/Superellipse\n",
925 SuperEllipsesRoundnessFieldId
, SuperEllipsesRoundnessFieldMask
,
927 (Field::MFDefaultFlags
| Field::FStdAccess
),
928 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleSuperEllipsesRoundness
),
929 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleSuperEllipsesRoundness
));
931 oType
.addInitialDesc(pDesc
);
933 pDesc
= new MFReal32::Description(
934 MFReal32::getClassType(),
935 "superEllipsesTwist",
936 "The twist angle in degree by which the superellipses is rotatet in the xy-plane.\n",
937 SuperEllipsesTwistFieldId
, SuperEllipsesTwistFieldMask
,
939 (Field::MFDefaultFlags
| Field::FStdAccess
),
940 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleSuperEllipsesTwist
),
941 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleSuperEllipsesTwist
));
943 oType
.addInitialDesc(pDesc
);
945 pDesc
= new MFReal32::Description(
946 MFReal32::getClassType(),
948 "The cinema light is described among others by a rangeCutOn parameter.\n"
949 "In the interval rangeCutOn to rangeCutOff the lighted fragments are\n"
951 "See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
952 "http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
953 "https://en.wikipedia.org/wiki/Superellipse\n",
954 RangeCutOnFieldId
, RangeCutOnFieldMask
,
956 (Field::MFDefaultFlags
| Field::FStdAccess
),
957 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleRangeCutOn
),
958 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleRangeCutOn
));
960 oType
.addInitialDesc(pDesc
);
962 pDesc
= new MFReal32::Description(
963 MFReal32::getClassType(),
965 "The cinema light is described among others by a rangeCutOff parameter.\n"
966 "In the interval rangeCutOn to rangeCutOff the lighted fragments are\n"
968 "See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
969 "http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
970 "https://en.wikipedia.org/wiki/Superellipse\n",
971 RangeCutOffFieldId
, RangeCutOffFieldMask
,
973 (Field::MFDefaultFlags
| Field::FStdAccess
),
974 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleRangeCutOff
),
975 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleRangeCutOff
));
977 oType
.addInitialDesc(pDesc
);
979 pDesc
= new MFReal32::Description(
980 MFReal32::getClassType(),
982 "The cinema light is described among others by a rangeNearZone parameter.\n"
983 "In the interval rangeCutOn-rangeNearZone to rangeCutOn the lighted fragments are\n"
985 "See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
986 "http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
987 "https://en.wikipedia.org/wiki/Superellipse\n",
988 RangeNearZoneFieldId
, RangeNearZoneFieldMask
,
990 (Field::MFDefaultFlags
| Field::FStdAccess
),
991 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleRangeNearZone
),
992 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleRangeNearZone
));
994 oType
.addInitialDesc(pDesc
);
996 pDesc
= new MFReal32::Description(
997 MFReal32::getClassType(),
999 "In the interval rangeCutOff to rangeCutOff+rangeFarZone the lighted fragments are\n"
1001 RangeFarZoneFieldId
, RangeFarZoneFieldMask
,
1003 (Field::MFDefaultFlags
| Field::FStdAccess
),
1004 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleRangeFarZone
),
1005 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleRangeFarZone
));
1007 oType
.addInitialDesc(pDesc
);
1009 pDesc
= new MFUInt8::Description(
1010 MFUInt8::getClassType(),
1012 "Stores the light's type. This can be any of the set {POINT_LIGHT, DIRECTIONAL_LIGHT, SPOT_LIGHT, CINEMA_LIGHT}.\n",
1013 TypeFieldId
, TypeFieldMask
,
1015 (Field::MFDefaultFlags
| Field::FStdAccess
),
1016 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleType
),
1017 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleType
));
1019 oType
.addInitialDesc(pDesc
);
1021 pDesc
= new MFBool::Description(
1022 MFBool::getClassType(),
1024 "The on/off state of the light.\n",
1025 EnabledFieldId
, EnabledFieldMask
,
1027 (Field::MFDefaultFlags
| Field::FStdAccess
),
1028 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleEnabled
),
1029 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleEnabled
));
1031 oType
.addInitialDesc(pDesc
);
1033 pDesc
= new MFWeakNodePtr::Description(
1034 MFWeakNodePtr::getClassType(),
1036 "The light's beacon determining its position or direction.\n",
1037 BeaconFieldId
, BeaconFieldMask
,
1039 (Field::MFDefaultFlags
| Field::FStdAccess
),
1040 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleBeacon
),
1041 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleBeacon
));
1043 oType
.addInitialDesc(pDesc
);
1045 pDesc
= new MFMatrix::Description(
1046 MFMatrix::getClassType(),
1048 "The beacon matrices used for the last render pass.\n",
1049 BeaconMatrixFieldId
, BeaconMatrixFieldMask
,
1051 (Field::MFDefaultFlags
| Field::FStdAccess
),
1052 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleBeaconMatrix
),
1053 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleBeaconMatrix
));
1055 oType
.addInitialDesc(pDesc
);
1057 pDesc
= new SFBool::Description(
1058 SFBool::getClassType(),
1060 "The lights position and direction are transformed to eye space before loading into the shader. \n"
1061 "On default they are provided in world space.\n",
1062 EyeSpaceFieldId
, EyeSpaceFieldMask
,
1064 (Field::SFDefaultFlags
| Field::FStdAccess
),
1065 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleEyeSpace
),
1066 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleEyeSpace
));
1068 oType
.addInitialDesc(pDesc
);
1070 pDesc
= new SFReal32::Description(
1071 SFReal32::getClassType(),
1073 "The camera last near value.\n",
1074 LastCamNearFieldId
, LastCamNearFieldMask
,
1076 (Field::SFDefaultFlags
| Field::FStdAccess
),
1077 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleLastCamNear
),
1078 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleLastCamNear
));
1080 oType
.addInitialDesc(pDesc
);
1082 pDesc
= new SFReal32::Description(
1083 SFReal32::getClassType(),
1085 "The camera last far value.\n",
1086 LastCamFarFieldId
, LastCamFarFieldMask
,
1088 (Field::SFDefaultFlags
| Field::FStdAccess
),
1089 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleLastCamFar
),
1090 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleLastCamFar
));
1092 oType
.addInitialDesc(pDesc
);
1094 pDesc
= new SFMatrix::Description(
1095 SFMatrix::getClassType(),
1097 "The camera last to world matrix.\n",
1098 LastCamToWorldFieldId
, LastCamToWorldFieldMask
,
1100 (Field::SFDefaultFlags
| Field::FStdAccess
),
1101 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleLastCamToWorld
),
1102 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleLastCamToWorld
));
1104 oType
.addInitialDesc(pDesc
);
1106 pDesc
= new SFString::Description(
1107 SFString::getClassType(),
1109 "The shader storage buffer block name for the light buffer.\n",
1110 LightBlockNameFieldId
, LightBlockNameFieldMask
,
1112 (Field::SFDefaultFlags
| Field::FStdAccess
),
1113 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleLightBlockName
),
1114 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleLightBlockName
));
1116 oType
.addInitialDesc(pDesc
);
1118 pDesc
= new SFString::Description(
1119 SFString::getClassType(),
1120 "LightVariableName",
1121 "The shader variable name for the light buffer.\n",
1122 LightVariableNameFieldId
, LightVariableNameFieldMask
,
1124 (Field::SFDefaultFlags
| Field::FStdAccess
),
1125 static_cast<FieldEditMethodSig
>(&MultiLightChunk::editHandleLightVariableName
),
1126 static_cast<FieldGetMethodSig
>(&MultiLightChunk::getHandleLightVariableName
));
1128 oType
.addInitialDesc(pDesc
);
1132 MultiLightChunkBase::TypeObject
MultiLightChunkBase::_type(
1133 MultiLightChunkBase::getClassname(),
1134 Inherited::getClassname(),
1137 reinterpret_cast<PrototypeCreateF
>(&MultiLightChunkBase::createEmptyLocal
),
1138 reinterpret_cast<InitContainerF
>(&MultiLightChunk::initMethod
),
1139 reinterpret_cast<ExitContainerF
>(&MultiLightChunk::exitMethod
),
1140 reinterpret_cast<InitalInsertDescFunc
>(
1141 reinterpret_cast<void *>(&MultiLightChunk::classDescInserter
)),
1144 "<?xml version=\"1.0\"?>\n"
1147 " name=\"MultiLightChunk\"\n"
1148 " parent=\"ShaderStorageBufferObjStdLayoutChunk\"\n"
1149 " library=\"System\"\n"
1150 " pointerfieldtypes=\"both\"\n"
1151 " structure=\"concrete\"\n"
1152 " systemcomponent=\"true\"\n"
1153 " parentsystemcomponent=\"true\"\n"
1154 " decoratable=\"false\"\n"
1155 " useLocalIncludes=\"false\"\n"
1156 " docGroupBase=\"GrpSystemState\"\n"
1158 "See \\ref PageSystemMultiLightChunk for a description.\n"
1160 "This chunk represents a number of lights that are exposed to shader code\n"
1161 "in form of a buffer in OpenGL std430 layout format.\n"
1162 "A shader, binding a shader storage block to the very same binding point, \n"
1163 "is expected to respect the corresponding block layout. The layout is regulated\n"
1164 "by the hasXXX fields of the chunk. If one is set to false the corresponding\n"
1165 "struct entry is omitted.\n"
1169 " mat4 worldToLightSpaceMatrix;\n"
1170 " mat4 lightToWorldSpaceMatrix;\n"
1171 " mat4 eyeToLightSpaceMatrix;\n"
1172 " mat4 lightToEyeSpaceMatrix;\n"
1173 " mat4 lightPerspectiveMatrix;\n"
1174 " mat4 invLightPerspectiveMatrix;\n"
1176 " vec3 direction;\n"
1178 " vec3 ambientIntensity;\n"
1179 " vec3 diffuseIntensity;\n"
1180 " vec3 specularIntensity;\n"
1181 " float intensity;\n"
1182 " float constantAttenuation;\n"
1183 " float linearAttenuation;\n"
1184 " float quadraticAttenuation;\n"
1185 " float rangeCutOn;\n"
1186 " float rangeCutOff;\n"
1187 " float rangeNearZone;\n"
1188 " float rangeFarZone;\n"
1189 " float cosSpotlightAngle;\n"
1190 " float spotlightAngle;\n"
1191 " float spotExponent;\n"
1192 " float innerSuperEllipsesWidth;\n"
1193 " float innerSuperEllipsesHeight;\n"
1194 " float outerSuperEllipsesWidth;\n"
1195 " float outerSuperEllipsesHeight;\n"
1196 " float superEllipsesRoundness;\n"
1197 " float superEllipsesTwist;\n"
1202 " layout (std430) buffer Lights\n"
1207 "The chunk provides a convenient function that allows to adjust the struct layout\n"
1208 "for standard OpenGL lights \n"
1213 " vec3 direction;\n"
1214 " vec3 ambientIntensity;\n"
1215 " vec3 diffuseIntensity;\n"
1216 " vec3 specularIntensity;\n"
1217 " float constantAttenuation;\n"
1218 " float linearAttenuation;\n"
1219 " float quadraticAttenuation;\n"
1220 " float cosSpotlightAngle;\n"
1221 " float spotExponent;\n"
1226 "or for simple range lights:\n"
1231 " vec3 direction;\n"
1233 " float intensity;\n"
1234 " float rangeCutOff;\n"
1235 " float cosSpotlightAngle;\n"
1241 " name=\"hasWorldToLightSpaceMatrix\"\n"
1243 " cardinality=\"single\"\n"
1244 " visibility=\"external\"\n"
1245 " access=\"public\"\n"
1246 " defaultValue=\"false\"\n"
1248 " This flag determines if the worldToLightSpaceMatrix attribute is part of \n"
1249 " the shader storage block, i.e. if the \"mat4 worldToLightSpaceMatrix;\" \n"
1250 " entry is contained in the shader struct for the Light.\n"
1254 " name=\"hasLightToWorldSpaceMatrix\"\n"
1256 " cardinality=\"single\"\n"
1257 " visibility=\"external\"\n"
1258 " access=\"public\"\n"
1259 " defaultValue=\"false\"\n"
1261 " This flag determines if the lightToWorldSpaceMatrix attribute is part of \n"
1262 " the shader storage block, i.e. if the \"mat4 lightToWorldSpaceMatrix;\" \n"
1263 " entry is contained in the shader struct for the Light.\n"
1267 " name=\"hasEyeToLightSpaceMatrix\"\n"
1269 " cardinality=\"single\"\n"
1270 " visibility=\"external\"\n"
1271 " access=\"public\"\n"
1272 " defaultValue=\"false\"\n"
1274 " This flag determines if the eyeToLightSpaceMatrix attribute is part of \n"
1275 " the shader storage block, i.e. if the \"mat4 eyeToLightSpaceMatrix;\" \n"
1276 " entry is contained in the shader struct for the Light.\n"
1277 " Attention: If this flag is set the light shader storage block has to\n"
1278 " be updated with every redraw operation.\n"
1282 " name=\"hasLightToEyeSpaceMatrix\"\n"
1284 " cardinality=\"single\"\n"
1285 " visibility=\"external\"\n"
1286 " access=\"public\"\n"
1287 " defaultValue=\"false\"\n"
1289 " This flag determines if the lightToEyeSpaceMatrix attribute is part of \n"
1290 " the shader storage block, i.e. if the \"mat4 lightToEyeSpaceMatrix;\" \n"
1291 " entry is contained in the shader struct for the Light.\n"
1292 " Attention: If this flag is set the light shader storage block has to\n"
1293 " be updated with every redraw operation.\n"
1297 " name=\"hasLightPerspectiveMatrix\"\n"
1299 " cardinality=\"single\"\n"
1300 " visibility=\"external\"\n"
1301 " access=\"public\"\n"
1302 " defaultValue=\"false\"\n"
1304 " This flag determines if the lightPerspectiveMatrix attribute is part of \n"
1305 " the shader storage block, i.e. if the \"mat4 lightPerspectiveMatrix;\" \n"
1306 " entry is contained in the shader struct for the Light.\n"
1310 " name=\"hasInvLightPerspectiveMatrix\"\n"
1312 " cardinality=\"single\"\n"
1313 " visibility=\"external\"\n"
1314 " access=\"public\"\n"
1315 " defaultValue=\"false\"\n"
1317 " This flag determines if the lightToEyeSpaceMatrix attribute is part of \n"
1318 " the shader storage block, i.e. if the \"mat4 invLightToEyeSpaceMatrix;\" \n"
1319 " entry is contained in the shader struct for the Light.\n"
1323 " name=\"hasColor\"\n"
1325 " cardinality=\"single\"\n"
1326 " visibility=\"external\"\n"
1327 " access=\"public\"\n"
1328 " defaultValue=\"false\"\n"
1330 " This flag determines if the color attribute is part of the shader storage block, i.e.\n"
1331 " if the \"vec3 color;\" entry is contained in the shader struct for the Light.\n"
1335 " name=\"hasIntensity\"\n"
1337 " cardinality=\"single\"\n"
1338 " visibility=\"external\"\n"
1339 " access=\"public\"\n"
1340 " defaultValue=\"false\"\n"
1342 " This flag determines if the intensity attribute is part of the shader storage block, i.e.\n"
1343 " if the \"float intensity;\" entry is contained in the shader struct for the Light.\n"
1347 " name=\"hasSeparateIntensities\"\n"
1349 " cardinality=\"single\"\n"
1350 " visibility=\"external\"\n"
1351 " access=\"public\"\n"
1352 " defaultValue=\"true\"\n"
1354 " This flag determines if the color intensity attributes are part of the shader storage block, i.e.\n"
1355 " if the \"vec3 Ia;\", \"vec3 Id;\" and \"vec3 Is;\" entries are contained in the shader struct for the Light.\n"
1359 " name=\"hasAttenuation\"\n"
1361 " cardinality=\"single\"\n"
1362 " visibility=\"external\"\n"
1363 " access=\"public\"\n"
1364 " defaultValue=\"true\"\n"
1366 " This flag determines if the attenuation attributes are part of the shader storage block, i.e.\n"
1367 " if the \"float constantAttenuation;\", \"float linearAttenuation;\" and \"float quadraticAttenuation;\"\n"
1368 " entries are contained in the shader struct for the Light.\n"
1372 " name=\"autoCalcRanges\"\n"
1374 " cardinality=\"single\"\n"
1375 " visibility=\"external\"\n"
1376 " access=\"public\"\n"
1377 " defaultValue=\"true\"\n"
1379 " If this flag is active and the lights have attenuations, then the cut on and cut off ranges\n"
1380 " are automatically calculated. They are, however, not provided automatically to the shader.\n"
1381 " For that, you have to set the hasRangeCutOn and hasRangeCutOff flags, respectively.\n"
1385 " name=\"hasRangeCutOn\"\n"
1387 " cardinality=\"single\"\n"
1388 " visibility=\"external\"\n"
1389 " access=\"public\"\n"
1390 " defaultValue=\"false\"\n"
1392 " This flag determines if the rangeCutOn attribute is part of the shader storage block, i.e.\n"
1393 " if the \"float rangeCutOn;\" entry is contained in the shader struct for the Light.\n"
1397 " name=\"hasRangeCutOff\"\n"
1399 " cardinality=\"single\"\n"
1400 " visibility=\"external\"\n"
1401 " access=\"public\"\n"
1402 " defaultValue=\"false\"\n"
1404 " This flag determines if the hasRangeCutOff attribute is part of the shader storage block, i.e.\n"
1405 " if the \"float hasRangeCutOff;\" entry is contained in the shader struct for the Light.\n"
1409 " name=\"hasRangeNearZone\"\n"
1411 " cardinality=\"single\"\n"
1412 " visibility=\"external\"\n"
1413 " access=\"public\"\n"
1414 " defaultValue=\"false\"\n"
1416 " This flag determines if the hasRangeNearZone attribute is part of the shader storage block, i.e.\n"
1417 " if the \"float hasRangeNearZone;\" entry is contained in the shader struct for the Light.\n"
1421 " name=\"hasRangeFarZone\"\n"
1423 " cardinality=\"single\"\n"
1424 " visibility=\"external\"\n"
1425 " access=\"public\"\n"
1426 " defaultValue=\"false\"\n"
1428 " This flag determines if the hasRangeFarZone attribute is part of the shader storage block, i.e.\n"
1429 " if the \"float hasRangeFarZone;\" entry is contained in the shader struct for the Light.\n"
1433 " name=\"hasCosSpotlightAngle\"\n"
1435 " cardinality=\"single\"\n"
1436 " visibility=\"external\"\n"
1437 " access=\"public\"\n"
1438 " defaultValue=\"true\"\n"
1440 " This flag determines if the cosine of the spot light angle attribute is part of the shader storage block, i.e.\n"
1441 " if the \"float cosSpotlightAngle;\" entry is contained in the shader struct for the Light. If neither this flag\n"
1442 " nor the hasSpotlightAngle flag is true, then this flag is treated as if it has value true.\n"
1446 " name=\"hasSpotlightAngle\"\n"
1448 " cardinality=\"single\"\n"
1449 " visibility=\"external\"\n"
1450 " access=\"public\"\n"
1451 " defaultValue=\"false\"\n"
1453 " This flag determines if the spot light angle attribute is part of the shader storage block, i.e.\n"
1454 " if the \"float spotlightAngle;\" entry is contained in the shader struct for the Light. If neither this flag\n"
1455 " nor the hasCosSpotlightAngle flag is true, then the hasCosSpotlightAngle flag is treated as if it has value true.\n"
1459 " name=\"hasSpotExponent\"\n"
1461 " cardinality=\"single\"\n"
1462 " visibility=\"external\"\n"
1463 " access=\"public\"\n"
1464 " defaultValue=\"true\"\n"
1466 " This flag determines if the spot expenent attribute is part of the shader storage block, i.e.\n"
1467 " if the \"float spotExponent;\" entry is contained in the shader struct for the Light.\n"
1471 " name=\"hasCinemaLight\"\n"
1473 " cardinality=\"single\"\n"
1474 " visibility=\"external\"\n"
1475 " access=\"public\"\n"
1476 " defaultValue=\"false\"\n"
1478 " This flag determines if the cinema light attributes are part of the shader storage block, i.e.\n"
1479 " if the \"float innerSuperEllipsesWidth;\", ... entries are contained in the shader struct for the Light.\n"
1480 " If true this flag overrides the hasRangeCutOn, hasRangeCutOff, hasRangeNearZone and hasRangeFarZone\n"
1481 " flags, because cinema lights are described the corresponding attributes.\n"
1482 " See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
1483 " http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
1484 " https://en.wikipedia.org/wiki/Superellipse\n"
1488 " name=\"position\"\n"
1490 " cardinality=\"multi\"\n"
1491 " visibility=\"external\"\n"
1492 " access=\"protected\"\n"
1494 " The light's position for point and spotlights in beacon space.\n"
1498 " name=\"direction\"\n"
1500 " cardinality=\"multi\"\n"
1501 " visibility=\"external\"\n"
1502 " access=\"protected\"\n"
1504 " The light's direction for directional and spotlights in beacon space.\n"
1509 " type=\"Color3f\"\n"
1510 " cardinality=\"multi\"\n"
1511 " visibility=\"external\"\n"
1512 " access=\"protected\"\n"
1514 " The light's color.\n"
1518 " name=\"intensity\"\n"
1519 " type=\"Real32\"\n"
1520 " cardinality=\"multi\"\n"
1521 " visibility=\"external\"\n"
1522 " access=\"protected\"\n"
1524 " The light's intensity.\n"
1528 " name=\"ambientIntensity\"\n"
1530 " cardinality=\"multi\"\n"
1531 " visibility=\"external\"\n"
1532 " access=\"protected\"\n"
1534 " The light's ambient intensity.\n"
1538 " name=\"diffuseIntensity\"\n"
1540 " cardinality=\"multi\"\n"
1541 " visibility=\"external\"\n"
1542 " access=\"protected\"\n"
1544 " The light's diffuse intensity.\n"
1548 " name=\"specularIntensity\"\n"
1550 " cardinality=\"multi\"\n"
1551 " visibility=\"external\"\n"
1552 " access=\"protected\"\n"
1554 " The light's specular intensity.\n"
1558 " name=\"attenuation\"\n"
1560 " cardinality=\"multi\"\n"
1561 " visibility=\"external\"\n"
1562 " access=\"protected\"\n"
1564 " The light's attenuation consiting of the constant, linear and quadratic attenuation parts.\n"
1568 " name=\"spotlightAngle\"\n"
1569 " type=\"Real32\"\n"
1570 " cardinality=\"multi\"\n"
1571 " visibility=\"external\"\n"
1572 " access=\"protected\"\n"
1574 " The spot angle in degree.\n"
1578 " name=\"spotExponent\"\n"
1579 " type=\"Real32\"\n"
1580 " cardinality=\"multi\"\n"
1581 " visibility=\"external\"\n"
1582 " access=\"protected\"\n"
1584 " The spot angle in degree.\n"
1588 " name=\"innerSuperEllipsesWidth\"\n"
1589 " type=\"Real32\"\n"
1590 " cardinality=\"multi\"\n"
1591 " visibility=\"external\"\n"
1592 " access=\"protected\"\n"
1594 " The cinema light is described among others by an inner ellipses. This is\n"
1595 " the width of this ellipse.\n"
1596 " See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
1597 " http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
1598 " https://en.wikipedia.org/wiki/Superellipse\n"
1602 " name=\"innerSuperEllipsesHeight\"\n"
1603 " type=\"Real32\"\n"
1604 " cardinality=\"multi\"\n"
1605 " visibility=\"external\"\n"
1606 " access=\"protected\"\n"
1608 " The cinema light is described among others by an inner ellipses. This is\n"
1609 " the height of this ellipse.\n"
1610 " See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
1611 " http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
1612 " https://en.wikipedia.org/wiki/Superellipse\n"
1616 " name=\"outerSuperEllipsesWidth\"\n"
1617 " type=\"Real32\"\n"
1618 " cardinality=\"multi\"\n"
1619 " visibility=\"external\"\n"
1620 " access=\"protected\"\n"
1622 " The cinema light is described among others by an outer ellipses. This is\n"
1623 " the width of this ellipse.\n"
1624 " See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
1625 " http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
1626 " https://en.wikipedia.org/wiki/Superellipse\n"
1630 " name=\"outerSuperEllipsesHeight\"\n"
1631 " type=\"Real32\"\n"
1632 " cardinality=\"multi\"\n"
1633 " visibility=\"external\"\n"
1634 " access=\"protected\"\n"
1636 " The cinema light is described among others by an outer ellipses. This is\n"
1637 " the height of this ellipse.\n"
1638 " See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
1639 " http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
1640 " https://en.wikipedia.org/wiki/Superellipse\n"
1644 " name=\"superEllipsesRoundness\"\n"
1645 " type=\"Real32\"\n"
1646 " cardinality=\"multi\"\n"
1647 " visibility=\"external\"\n"
1648 " access=\"protected\"\n"
1650 " The cinema light is described among others by a roundness parameter. \n"
1651 " See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
1652 " http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
1653 " https://en.wikipedia.org/wiki/Superellipse\n"
1657 " name=\"superEllipsesTwist\"\n"
1658 " type=\"Real32\"\n"
1659 " cardinality=\"multi\"\n"
1660 " visibility=\"external\"\n"
1661 " access=\"protected\"\n"
1663 " The twist angle in degree by which the superellipses is rotatet in the xy-plane.\n"
1667 " name=\"rangeCutOn\"\n"
1668 " type=\"Real32\"\n"
1669 " cardinality=\"multi\"\n"
1670 " visibility=\"external\"\n"
1671 " access=\"protected\"\n"
1673 " The cinema light is described among others by a rangeCutOn parameter.\n"
1674 " In the interval rangeCutOn to rangeCutOff the lighted fragments are\n"
1676 " See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
1677 " http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
1678 " https://en.wikipedia.org/wiki/Superellipse\n"
1682 " name=\"rangeCutOff\"\n"
1683 " type=\"Real32\"\n"
1684 " cardinality=\"multi\"\n"
1685 " visibility=\"external\"\n"
1686 " access=\"protected\"\n"
1688 " The cinema light is described among others by a rangeCutOff parameter.\n"
1689 " In the interval rangeCutOn to rangeCutOff the lighted fragments are\n"
1691 " See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
1692 " http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
1693 " https://en.wikipedia.org/wiki/Superellipse\n"
1697 " name=\"rangeNearZone\"\n"
1698 " type=\"Real32\"\n"
1699 " cardinality=\"multi\"\n"
1700 " visibility=\"external\"\n"
1701 " access=\"protected\"\n"
1703 " The cinema light is described among others by a rangeNearZone parameter.\n"
1704 " In the interval rangeCutOn-rangeNearZone to rangeCutOn the lighted fragments are\n"
1706 " See: http://http.developer.nvidia.com/GPUGems/gpugems_ch10.html\n"
1707 " http://www.yaldex.com/open-gl/ch12lev1sec4.html\n"
1708 " https://en.wikipedia.org/wiki/Superellipse\n"
1712 " name=\"rangeFarZone\"\n"
1713 " type=\"Real32\"\n"
1714 " cardinality=\"multi\"\n"
1715 " visibility=\"external\"\n"
1716 " access=\"protected\"\n"
1718 " In the interval rangeCutOff to rangeCutOff+rangeFarZone the lighted fragments are\n"
1725 " cardinality=\"multi\"\n"
1726 " visibility=\"external\"\n"
1727 " access=\"protected\"\n"
1729 " Stores the light's type. This can be any of the set {POINT_LIGHT, DIRECTIONAL_LIGHT, SPOT_LIGHT, CINEMA_LIGHT}.\n"
1733 " name=\"enabled\"\n"
1735 " cardinality=\"multi\"\n"
1736 " visibility=\"external\"\n"
1737 " access=\"protected\"\n"
1739 " The on/off state of the light.\n"
1743 " name=\"beacon\"\n"
1745 " category=\"weakpointer\"\n"
1746 " cardinality=\"multi\"\n"
1747 " visibility=\"external\"\n"
1748 " access=\"protected\"\n"
1750 " The light's beacon determining its position or direction.\n"
1754 " name=\"beaconMatrix\"\n"
1755 " type=\"Matrix\"\n"
1756 " cardinality=\"multi\"\n"
1757 " visibility=\"internal\"\n"
1758 " access=\"protected\"\n"
1760 " The beacon matrices used for the last render pass.\n"
1764 " name=\"eyeSpace\"\n"
1766 " cardinality=\"single\"\n"
1767 " visibility=\"external\"\n"
1768 " access=\"public\"\n"
1769 " defaultValue=\"false\"\n"
1771 " The lights position and direction are transformed to eye space before loading into the shader. \n"
1772 " On default they are provided in world space.\n"
1776 " name=\"lastCamNear\"\n"
1777 " type=\"Real32\"\n"
1778 " cardinality=\"single\"\n"
1779 " visibility=\"internal\"\n"
1780 " access=\"protected\"\n"
1781 " defaultValue=\"0.f\"\n"
1783 " The camera last near value.\n"
1787 " name=\"lastCamFar\"\n"
1788 " type=\"Real32\"\n"
1789 " cardinality=\"single\"\n"
1790 " visibility=\"internal\"\n"
1791 " access=\"protected\"\n"
1792 " defaultValue=\"0.f\"\n"
1794 " The camera last far value.\n"
1798 " name=\"lastCamToWorld\"\n"
1799 " type=\"Matrix\"\n"
1800 " cardinality=\"single\"\n"
1801 " visibility=\"internal\"\n"
1802 " access=\"protected\"\n"
1804 " The camera last to world matrix.\n"
1808 " name=\"LightBlockName\"\n"
1809 " type=\"std::string\"\n"
1810 " cardinality=\"single\"\n"
1811 " visibility=\"external\"\n"
1812 " access=\"public\"\n"
1813 " defaultValue='\"Lights\"'\n"
1815 " The shader storage buffer block name for the light buffer.\n"
1819 " name=\"LightVariableName\"\n"
1820 " type=\"std::string\"\n"
1821 " cardinality=\"single\"\n"
1822 " visibility=\"external\"\n"
1823 " access=\"public\"\n"
1824 " defaultValue='\"lights\"'\n"
1826 " The shader variable name for the light buffer.\n"
1829 "</FieldContainer>\n",
1830 "See \\ref PageSystemMultiLightChunk for a description.\n"
1832 "This chunk represents a number of lights that are exposed to shader code\n"
1833 "in form of a buffer in OpenGL std430 layout format.\n"
1834 "A shader, binding a shader storage block to the very same binding point, \n"
1835 "is expected to respect the corresponding block layout. The layout is regulated\n"
1836 "by the hasXXX fields of the chunk. If one is set to false the corresponding\n"
1837 "struct entry is omitted.\n"
1841 "mat4 worldToLightSpaceMatrix;\n"
1842 "mat4 lightToWorldSpaceMatrix;\n"
1843 "mat4 eyeToLightSpaceMatrix;\n"
1844 "mat4 lightToEyeSpaceMatrix;\n"
1845 "mat4 lightPerspectiveMatrix;\n"
1846 "mat4 invLightPerspectiveMatrix;\n"
1850 "vec3 ambientIntensity;\n"
1851 "vec3 diffuseIntensity;\n"
1852 "vec3 specularIntensity;\n"
1853 "float intensity;\n"
1854 "float constantAttenuation;\n"
1855 "float linearAttenuation;\n"
1856 "float quadraticAttenuation;\n"
1857 "float rangeCutOn;\n"
1858 "float rangeCutOff;\n"
1859 "float rangeNearZone;\n"
1860 "float rangeFarZone;\n"
1861 "float cosSpotlightAngle;\n"
1862 "float spotlightAngle;\n"
1863 "float spotExponent;\n"
1864 "float innerSuperEllipsesWidth;\n"
1865 "float innerSuperEllipsesHeight;\n"
1866 "float outerSuperEllipsesWidth;\n"
1867 "float outerSuperEllipsesHeight;\n"
1868 "float superEllipsesRoundness;\n"
1869 "float superEllipsesTwist;\n"
1874 "layout (std430) buffer Lights\n"
1879 "The chunk provides a convenient function that allows to adjust the struct layout\n"
1880 "for standard OpenGL lights \n"
1886 "vec3 ambientIntensity;\n"
1887 "vec3 diffuseIntensity;\n"
1888 "vec3 specularIntensity;\n"
1889 "float constantAttenuation;\n"
1890 "float linearAttenuation;\n"
1891 "float quadraticAttenuation;\n"
1892 "float cosSpotlightAngle;\n"
1893 "float spotExponent;\n"
1898 "or for simple range lights:\n"
1905 "float intensity;\n"
1906 "float rangeCutOff;\n"
1907 "float cosSpotlightAngle;\n"
1913 /*------------------------------ get -----------------------------------*/
1915 FieldContainerType
&MultiLightChunkBase::getType(void)
1920 const FieldContainerType
&MultiLightChunkBase::getType(void) const
1925 UInt32
MultiLightChunkBase::getContainerSize(void) const
1927 return sizeof(MultiLightChunk
);
1930 /*------------------------- decorator get ------------------------------*/
1933 SFBool
*MultiLightChunkBase::editSFHasWorldToLightSpaceMatrix(void)
1935 editSField(HasWorldToLightSpaceMatrixFieldMask
);
1937 return &_sfHasWorldToLightSpaceMatrix
;
1940 const SFBool
*MultiLightChunkBase::getSFHasWorldToLightSpaceMatrix(void) const
1942 return &_sfHasWorldToLightSpaceMatrix
;
1946 SFBool
*MultiLightChunkBase::editSFHasLightToWorldSpaceMatrix(void)
1948 editSField(HasLightToWorldSpaceMatrixFieldMask
);
1950 return &_sfHasLightToWorldSpaceMatrix
;
1953 const SFBool
*MultiLightChunkBase::getSFHasLightToWorldSpaceMatrix(void) const
1955 return &_sfHasLightToWorldSpaceMatrix
;
1959 SFBool
*MultiLightChunkBase::editSFHasEyeToLightSpaceMatrix(void)
1961 editSField(HasEyeToLightSpaceMatrixFieldMask
);
1963 return &_sfHasEyeToLightSpaceMatrix
;
1966 const SFBool
*MultiLightChunkBase::getSFHasEyeToLightSpaceMatrix(void) const
1968 return &_sfHasEyeToLightSpaceMatrix
;
1972 SFBool
*MultiLightChunkBase::editSFHasLightToEyeSpaceMatrix(void)
1974 editSField(HasLightToEyeSpaceMatrixFieldMask
);
1976 return &_sfHasLightToEyeSpaceMatrix
;
1979 const SFBool
*MultiLightChunkBase::getSFHasLightToEyeSpaceMatrix(void) const
1981 return &_sfHasLightToEyeSpaceMatrix
;
1985 SFBool
*MultiLightChunkBase::editSFHasLightPerspectiveMatrix(void)
1987 editSField(HasLightPerspectiveMatrixFieldMask
);
1989 return &_sfHasLightPerspectiveMatrix
;
1992 const SFBool
*MultiLightChunkBase::getSFHasLightPerspectiveMatrix(void) const
1994 return &_sfHasLightPerspectiveMatrix
;
1998 SFBool
*MultiLightChunkBase::editSFHasInvLightPerspectiveMatrix(void)
2000 editSField(HasInvLightPerspectiveMatrixFieldMask
);
2002 return &_sfHasInvLightPerspectiveMatrix
;
2005 const SFBool
*MultiLightChunkBase::getSFHasInvLightPerspectiveMatrix(void) const
2007 return &_sfHasInvLightPerspectiveMatrix
;
2011 SFBool
*MultiLightChunkBase::editSFHasColor(void)
2013 editSField(HasColorFieldMask
);
2015 return &_sfHasColor
;
2018 const SFBool
*MultiLightChunkBase::getSFHasColor(void) const
2020 return &_sfHasColor
;
2024 SFBool
*MultiLightChunkBase::editSFHasIntensity(void)
2026 editSField(HasIntensityFieldMask
);
2028 return &_sfHasIntensity
;
2031 const SFBool
*MultiLightChunkBase::getSFHasIntensity(void) const
2033 return &_sfHasIntensity
;
2037 SFBool
*MultiLightChunkBase::editSFHasSeparateIntensities(void)
2039 editSField(HasSeparateIntensitiesFieldMask
);
2041 return &_sfHasSeparateIntensities
;
2044 const SFBool
*MultiLightChunkBase::getSFHasSeparateIntensities(void) const
2046 return &_sfHasSeparateIntensities
;
2050 SFBool
*MultiLightChunkBase::editSFHasAttenuation(void)
2052 editSField(HasAttenuationFieldMask
);
2054 return &_sfHasAttenuation
;
2057 const SFBool
*MultiLightChunkBase::getSFHasAttenuation(void) const
2059 return &_sfHasAttenuation
;
2063 SFBool
*MultiLightChunkBase::editSFAutoCalcRanges(void)
2065 editSField(AutoCalcRangesFieldMask
);
2067 return &_sfAutoCalcRanges
;
2070 const SFBool
*MultiLightChunkBase::getSFAutoCalcRanges(void) const
2072 return &_sfAutoCalcRanges
;
2076 SFBool
*MultiLightChunkBase::editSFHasRangeCutOn(void)
2078 editSField(HasRangeCutOnFieldMask
);
2080 return &_sfHasRangeCutOn
;
2083 const SFBool
*MultiLightChunkBase::getSFHasRangeCutOn(void) const
2085 return &_sfHasRangeCutOn
;
2089 SFBool
*MultiLightChunkBase::editSFHasRangeCutOff(void)
2091 editSField(HasRangeCutOffFieldMask
);
2093 return &_sfHasRangeCutOff
;
2096 const SFBool
*MultiLightChunkBase::getSFHasRangeCutOff(void) const
2098 return &_sfHasRangeCutOff
;
2102 SFBool
*MultiLightChunkBase::editSFHasRangeNearZone(void)
2104 editSField(HasRangeNearZoneFieldMask
);
2106 return &_sfHasRangeNearZone
;
2109 const SFBool
*MultiLightChunkBase::getSFHasRangeNearZone(void) const
2111 return &_sfHasRangeNearZone
;
2115 SFBool
*MultiLightChunkBase::editSFHasRangeFarZone(void)
2117 editSField(HasRangeFarZoneFieldMask
);
2119 return &_sfHasRangeFarZone
;
2122 const SFBool
*MultiLightChunkBase::getSFHasRangeFarZone(void) const
2124 return &_sfHasRangeFarZone
;
2128 SFBool
*MultiLightChunkBase::editSFHasCosSpotlightAngle(void)
2130 editSField(HasCosSpotlightAngleFieldMask
);
2132 return &_sfHasCosSpotlightAngle
;
2135 const SFBool
*MultiLightChunkBase::getSFHasCosSpotlightAngle(void) const
2137 return &_sfHasCosSpotlightAngle
;
2141 SFBool
*MultiLightChunkBase::editSFHasSpotlightAngle(void)
2143 editSField(HasSpotlightAngleFieldMask
);
2145 return &_sfHasSpotlightAngle
;
2148 const SFBool
*MultiLightChunkBase::getSFHasSpotlightAngle(void) const
2150 return &_sfHasSpotlightAngle
;
2154 SFBool
*MultiLightChunkBase::editSFHasSpotExponent(void)
2156 editSField(HasSpotExponentFieldMask
);
2158 return &_sfHasSpotExponent
;
2161 const SFBool
*MultiLightChunkBase::getSFHasSpotExponent(void) const
2163 return &_sfHasSpotExponent
;
2167 SFBool
*MultiLightChunkBase::editSFHasCinemaLight(void)
2169 editSField(HasCinemaLightFieldMask
);
2171 return &_sfHasCinemaLight
;
2174 const SFBool
*MultiLightChunkBase::getSFHasCinemaLight(void) const
2176 return &_sfHasCinemaLight
;
2180 MFPnt3f
*MultiLightChunkBase::editMFPosition(void)
2182 editMField(PositionFieldMask
, _mfPosition
);
2184 return &_mfPosition
;
2187 const MFPnt3f
*MultiLightChunkBase::getMFPosition(void) const
2189 return &_mfPosition
;
2193 MFVec3f
*MultiLightChunkBase::editMFDirection(void)
2195 editMField(DirectionFieldMask
, _mfDirection
);
2197 return &_mfDirection
;
2200 const MFVec3f
*MultiLightChunkBase::getMFDirection(void) const
2202 return &_mfDirection
;
2206 MFColor3f
*MultiLightChunkBase::editMFColor(void)
2208 editMField(ColorFieldMask
, _mfColor
);
2213 const MFColor3f
*MultiLightChunkBase::getMFColor(void) const
2219 MFReal32
*MultiLightChunkBase::editMFIntensity(void)
2221 editMField(IntensityFieldMask
, _mfIntensity
);
2223 return &_mfIntensity
;
2226 const MFReal32
*MultiLightChunkBase::getMFIntensity(void) const
2228 return &_mfIntensity
;
2232 MFVec3f
*MultiLightChunkBase::editMFAmbientIntensity(void)
2234 editMField(AmbientIntensityFieldMask
, _mfAmbientIntensity
);
2236 return &_mfAmbientIntensity
;
2239 const MFVec3f
*MultiLightChunkBase::getMFAmbientIntensity(void) const
2241 return &_mfAmbientIntensity
;
2245 MFVec3f
*MultiLightChunkBase::editMFDiffuseIntensity(void)
2247 editMField(DiffuseIntensityFieldMask
, _mfDiffuseIntensity
);
2249 return &_mfDiffuseIntensity
;
2252 const MFVec3f
*MultiLightChunkBase::getMFDiffuseIntensity(void) const
2254 return &_mfDiffuseIntensity
;
2258 MFVec3f
*MultiLightChunkBase::editMFSpecularIntensity(void)
2260 editMField(SpecularIntensityFieldMask
, _mfSpecularIntensity
);
2262 return &_mfSpecularIntensity
;
2265 const MFVec3f
*MultiLightChunkBase::getMFSpecularIntensity(void) const
2267 return &_mfSpecularIntensity
;
2271 MFVec3f
*MultiLightChunkBase::editMFAttenuation(void)
2273 editMField(AttenuationFieldMask
, _mfAttenuation
);
2275 return &_mfAttenuation
;
2278 const MFVec3f
*MultiLightChunkBase::getMFAttenuation(void) const
2280 return &_mfAttenuation
;
2284 MFReal32
*MultiLightChunkBase::editMFSpotlightAngle(void)
2286 editMField(SpotlightAngleFieldMask
, _mfSpotlightAngle
);
2288 return &_mfSpotlightAngle
;
2291 const MFReal32
*MultiLightChunkBase::getMFSpotlightAngle(void) const
2293 return &_mfSpotlightAngle
;
2297 MFReal32
*MultiLightChunkBase::editMFSpotExponent(void)
2299 editMField(SpotExponentFieldMask
, _mfSpotExponent
);
2301 return &_mfSpotExponent
;
2304 const MFReal32
*MultiLightChunkBase::getMFSpotExponent(void) const
2306 return &_mfSpotExponent
;
2310 MFReal32
*MultiLightChunkBase::editMFInnerSuperEllipsesWidth(void)
2312 editMField(InnerSuperEllipsesWidthFieldMask
, _mfInnerSuperEllipsesWidth
);
2314 return &_mfInnerSuperEllipsesWidth
;
2317 const MFReal32
*MultiLightChunkBase::getMFInnerSuperEllipsesWidth(void) const
2319 return &_mfInnerSuperEllipsesWidth
;
2323 MFReal32
*MultiLightChunkBase::editMFInnerSuperEllipsesHeight(void)
2325 editMField(InnerSuperEllipsesHeightFieldMask
, _mfInnerSuperEllipsesHeight
);
2327 return &_mfInnerSuperEllipsesHeight
;
2330 const MFReal32
*MultiLightChunkBase::getMFInnerSuperEllipsesHeight(void) const
2332 return &_mfInnerSuperEllipsesHeight
;
2336 MFReal32
*MultiLightChunkBase::editMFOuterSuperEllipsesWidth(void)
2338 editMField(OuterSuperEllipsesWidthFieldMask
, _mfOuterSuperEllipsesWidth
);
2340 return &_mfOuterSuperEllipsesWidth
;
2343 const MFReal32
*MultiLightChunkBase::getMFOuterSuperEllipsesWidth(void) const
2345 return &_mfOuterSuperEllipsesWidth
;
2349 MFReal32
*MultiLightChunkBase::editMFOuterSuperEllipsesHeight(void)
2351 editMField(OuterSuperEllipsesHeightFieldMask
, _mfOuterSuperEllipsesHeight
);
2353 return &_mfOuterSuperEllipsesHeight
;
2356 const MFReal32
*MultiLightChunkBase::getMFOuterSuperEllipsesHeight(void) const
2358 return &_mfOuterSuperEllipsesHeight
;
2362 MFReal32
*MultiLightChunkBase::editMFSuperEllipsesRoundness(void)
2364 editMField(SuperEllipsesRoundnessFieldMask
, _mfSuperEllipsesRoundness
);
2366 return &_mfSuperEllipsesRoundness
;
2369 const MFReal32
*MultiLightChunkBase::getMFSuperEllipsesRoundness(void) const
2371 return &_mfSuperEllipsesRoundness
;
2375 MFReal32
*MultiLightChunkBase::editMFSuperEllipsesTwist(void)
2377 editMField(SuperEllipsesTwistFieldMask
, _mfSuperEllipsesTwist
);
2379 return &_mfSuperEllipsesTwist
;
2382 const MFReal32
*MultiLightChunkBase::getMFSuperEllipsesTwist(void) const
2384 return &_mfSuperEllipsesTwist
;
2388 MFReal32
*MultiLightChunkBase::editMFRangeCutOn(void)
2390 editMField(RangeCutOnFieldMask
, _mfRangeCutOn
);
2392 return &_mfRangeCutOn
;
2395 const MFReal32
*MultiLightChunkBase::getMFRangeCutOn(void) const
2397 return &_mfRangeCutOn
;
2401 MFReal32
*MultiLightChunkBase::editMFRangeCutOff(void)
2403 editMField(RangeCutOffFieldMask
, _mfRangeCutOff
);
2405 return &_mfRangeCutOff
;
2408 const MFReal32
*MultiLightChunkBase::getMFRangeCutOff(void) const
2410 return &_mfRangeCutOff
;
2414 MFReal32
*MultiLightChunkBase::editMFRangeNearZone(void)
2416 editMField(RangeNearZoneFieldMask
, _mfRangeNearZone
);
2418 return &_mfRangeNearZone
;
2421 const MFReal32
*MultiLightChunkBase::getMFRangeNearZone(void) const
2423 return &_mfRangeNearZone
;
2427 MFReal32
*MultiLightChunkBase::editMFRangeFarZone(void)
2429 editMField(RangeFarZoneFieldMask
, _mfRangeFarZone
);
2431 return &_mfRangeFarZone
;
2434 const MFReal32
*MultiLightChunkBase::getMFRangeFarZone(void) const
2436 return &_mfRangeFarZone
;
2440 MFUInt8
*MultiLightChunkBase::editMFType(void)
2442 editMField(TypeFieldMask
, _mfType
);
2447 const MFUInt8
*MultiLightChunkBase::getMFType(void) const
2453 MFBool
*MultiLightChunkBase::editMFEnabled(void)
2455 editMField(EnabledFieldMask
, _mfEnabled
);
2460 const MFBool
*MultiLightChunkBase::getMFEnabled(void) const
2466 //! Get the MultiLightChunk::_mfBeacon field.
2467 const MFWeakNodePtr
*MultiLightChunkBase::getMFBeacon(void) const
2472 MFWeakNodePtr
*MultiLightChunkBase::editMFBeacon (void)
2474 editMField(BeaconFieldMask
, _mfBeacon
);
2478 Node
* MultiLightChunkBase::getBeacon(const UInt32 index
) const
2480 return _mfBeacon
[index
];
2483 MFMatrix
*MultiLightChunkBase::editMFBeaconMatrix(void)
2485 editMField(BeaconMatrixFieldMask
, _mfBeaconMatrix
);
2487 return &_mfBeaconMatrix
;
2490 const MFMatrix
*MultiLightChunkBase::getMFBeaconMatrix(void) const
2492 return &_mfBeaconMatrix
;
2496 SFBool
*MultiLightChunkBase::editSFEyeSpace(void)
2498 editSField(EyeSpaceFieldMask
);
2500 return &_sfEyeSpace
;
2503 const SFBool
*MultiLightChunkBase::getSFEyeSpace(void) const
2505 return &_sfEyeSpace
;
2509 SFReal32
*MultiLightChunkBase::editSFLastCamNear(void)
2511 editSField(LastCamNearFieldMask
);
2513 return &_sfLastCamNear
;
2516 const SFReal32
*MultiLightChunkBase::getSFLastCamNear(void) const
2518 return &_sfLastCamNear
;
2522 SFReal32
*MultiLightChunkBase::editSFLastCamFar(void)
2524 editSField(LastCamFarFieldMask
);
2526 return &_sfLastCamFar
;
2529 const SFReal32
*MultiLightChunkBase::getSFLastCamFar(void) const
2531 return &_sfLastCamFar
;
2535 SFMatrix
*MultiLightChunkBase::editSFLastCamToWorld(void)
2537 editSField(LastCamToWorldFieldMask
);
2539 return &_sfLastCamToWorld
;
2542 const SFMatrix
*MultiLightChunkBase::getSFLastCamToWorld(void) const
2544 return &_sfLastCamToWorld
;
2548 SFString
*MultiLightChunkBase::editSFLightBlockName(void)
2550 editSField(LightBlockNameFieldMask
);
2552 return &_sfLightBlockName
;
2555 const SFString
*MultiLightChunkBase::getSFLightBlockName(void) const
2557 return &_sfLightBlockName
;
2561 SFString
*MultiLightChunkBase::editSFLightVariableName(void)
2563 editSField(LightVariableNameFieldMask
);
2565 return &_sfLightVariableName
;
2568 const SFString
*MultiLightChunkBase::getSFLightVariableName(void) const
2570 return &_sfLightVariableName
;
2576 void MultiLightChunkBase::pushToBeacon(Node
* const value
)
2578 editMField(BeaconFieldMask
, _mfBeacon
);
2580 _mfBeacon
.push_back(value
);
2583 void MultiLightChunkBase::assignBeacon (const MFWeakNodePtr
&value
)
2585 MFWeakNodePtr ::const_iterator elemIt
=
2587 MFWeakNodePtr ::const_iterator elemEnd
=
2590 static_cast<MultiLightChunk
*>(this)->clearBeacon();
2592 while(elemIt
!= elemEnd
)
2594 this->pushToBeacon(*elemIt
);
2600 void MultiLightChunkBase::removeFromBeacon(UInt32 uiIndex
)
2602 if(uiIndex
< _mfBeacon
.size())
2604 editMField(BeaconFieldMask
, _mfBeacon
);
2606 _mfBeacon
.erase(uiIndex
);
2610 void MultiLightChunkBase::removeObjFromBeacon(Node
* const value
)
2612 Int32 iElemIdx
= _mfBeacon
.findIndex(value
);
2616 editMField(BeaconFieldMask
, _mfBeacon
);
2618 _mfBeacon
.erase(iElemIdx
);
2621 void MultiLightChunkBase::clearBeacon(void)
2623 editMField(BeaconFieldMask
, _mfBeacon
);
2631 /*------------------------------ access -----------------------------------*/
2633 SizeT
MultiLightChunkBase::getBinSize(ConstFieldMaskArg whichField
)
2635 SizeT returnValue
= Inherited::getBinSize(whichField
);
2637 if(FieldBits::NoField
!= (HasWorldToLightSpaceMatrixFieldMask
& whichField
))
2639 returnValue
+= _sfHasWorldToLightSpaceMatrix
.getBinSize();
2641 if(FieldBits::NoField
!= (HasLightToWorldSpaceMatrixFieldMask
& whichField
))
2643 returnValue
+= _sfHasLightToWorldSpaceMatrix
.getBinSize();
2645 if(FieldBits::NoField
!= (HasEyeToLightSpaceMatrixFieldMask
& whichField
))
2647 returnValue
+= _sfHasEyeToLightSpaceMatrix
.getBinSize();
2649 if(FieldBits::NoField
!= (HasLightToEyeSpaceMatrixFieldMask
& whichField
))
2651 returnValue
+= _sfHasLightToEyeSpaceMatrix
.getBinSize();
2653 if(FieldBits::NoField
!= (HasLightPerspectiveMatrixFieldMask
& whichField
))
2655 returnValue
+= _sfHasLightPerspectiveMatrix
.getBinSize();
2657 if(FieldBits::NoField
!= (HasInvLightPerspectiveMatrixFieldMask
& whichField
))
2659 returnValue
+= _sfHasInvLightPerspectiveMatrix
.getBinSize();
2661 if(FieldBits::NoField
!= (HasColorFieldMask
& whichField
))
2663 returnValue
+= _sfHasColor
.getBinSize();
2665 if(FieldBits::NoField
!= (HasIntensityFieldMask
& whichField
))
2667 returnValue
+= _sfHasIntensity
.getBinSize();
2669 if(FieldBits::NoField
!= (HasSeparateIntensitiesFieldMask
& whichField
))
2671 returnValue
+= _sfHasSeparateIntensities
.getBinSize();
2673 if(FieldBits::NoField
!= (HasAttenuationFieldMask
& whichField
))
2675 returnValue
+= _sfHasAttenuation
.getBinSize();
2677 if(FieldBits::NoField
!= (AutoCalcRangesFieldMask
& whichField
))
2679 returnValue
+= _sfAutoCalcRanges
.getBinSize();
2681 if(FieldBits::NoField
!= (HasRangeCutOnFieldMask
& whichField
))
2683 returnValue
+= _sfHasRangeCutOn
.getBinSize();
2685 if(FieldBits::NoField
!= (HasRangeCutOffFieldMask
& whichField
))
2687 returnValue
+= _sfHasRangeCutOff
.getBinSize();
2689 if(FieldBits::NoField
!= (HasRangeNearZoneFieldMask
& whichField
))
2691 returnValue
+= _sfHasRangeNearZone
.getBinSize();
2693 if(FieldBits::NoField
!= (HasRangeFarZoneFieldMask
& whichField
))
2695 returnValue
+= _sfHasRangeFarZone
.getBinSize();
2697 if(FieldBits::NoField
!= (HasCosSpotlightAngleFieldMask
& whichField
))
2699 returnValue
+= _sfHasCosSpotlightAngle
.getBinSize();
2701 if(FieldBits::NoField
!= (HasSpotlightAngleFieldMask
& whichField
))
2703 returnValue
+= _sfHasSpotlightAngle
.getBinSize();
2705 if(FieldBits::NoField
!= (HasSpotExponentFieldMask
& whichField
))
2707 returnValue
+= _sfHasSpotExponent
.getBinSize();
2709 if(FieldBits::NoField
!= (HasCinemaLightFieldMask
& whichField
))
2711 returnValue
+= _sfHasCinemaLight
.getBinSize();
2713 if(FieldBits::NoField
!= (PositionFieldMask
& whichField
))
2715 returnValue
+= _mfPosition
.getBinSize();
2717 if(FieldBits::NoField
!= (DirectionFieldMask
& whichField
))
2719 returnValue
+= _mfDirection
.getBinSize();
2721 if(FieldBits::NoField
!= (ColorFieldMask
& whichField
))
2723 returnValue
+= _mfColor
.getBinSize();
2725 if(FieldBits::NoField
!= (IntensityFieldMask
& whichField
))
2727 returnValue
+= _mfIntensity
.getBinSize();
2729 if(FieldBits::NoField
!= (AmbientIntensityFieldMask
& whichField
))
2731 returnValue
+= _mfAmbientIntensity
.getBinSize();
2733 if(FieldBits::NoField
!= (DiffuseIntensityFieldMask
& whichField
))
2735 returnValue
+= _mfDiffuseIntensity
.getBinSize();
2737 if(FieldBits::NoField
!= (SpecularIntensityFieldMask
& whichField
))
2739 returnValue
+= _mfSpecularIntensity
.getBinSize();
2741 if(FieldBits::NoField
!= (AttenuationFieldMask
& whichField
))
2743 returnValue
+= _mfAttenuation
.getBinSize();
2745 if(FieldBits::NoField
!= (SpotlightAngleFieldMask
& whichField
))
2747 returnValue
+= _mfSpotlightAngle
.getBinSize();
2749 if(FieldBits::NoField
!= (SpotExponentFieldMask
& whichField
))
2751 returnValue
+= _mfSpotExponent
.getBinSize();
2753 if(FieldBits::NoField
!= (InnerSuperEllipsesWidthFieldMask
& whichField
))
2755 returnValue
+= _mfInnerSuperEllipsesWidth
.getBinSize();
2757 if(FieldBits::NoField
!= (InnerSuperEllipsesHeightFieldMask
& whichField
))
2759 returnValue
+= _mfInnerSuperEllipsesHeight
.getBinSize();
2761 if(FieldBits::NoField
!= (OuterSuperEllipsesWidthFieldMask
& whichField
))
2763 returnValue
+= _mfOuterSuperEllipsesWidth
.getBinSize();
2765 if(FieldBits::NoField
!= (OuterSuperEllipsesHeightFieldMask
& whichField
))
2767 returnValue
+= _mfOuterSuperEllipsesHeight
.getBinSize();
2769 if(FieldBits::NoField
!= (SuperEllipsesRoundnessFieldMask
& whichField
))
2771 returnValue
+= _mfSuperEllipsesRoundness
.getBinSize();
2773 if(FieldBits::NoField
!= (SuperEllipsesTwistFieldMask
& whichField
))
2775 returnValue
+= _mfSuperEllipsesTwist
.getBinSize();
2777 if(FieldBits::NoField
!= (RangeCutOnFieldMask
& whichField
))
2779 returnValue
+= _mfRangeCutOn
.getBinSize();
2781 if(FieldBits::NoField
!= (RangeCutOffFieldMask
& whichField
))
2783 returnValue
+= _mfRangeCutOff
.getBinSize();
2785 if(FieldBits::NoField
!= (RangeNearZoneFieldMask
& whichField
))
2787 returnValue
+= _mfRangeNearZone
.getBinSize();
2789 if(FieldBits::NoField
!= (RangeFarZoneFieldMask
& whichField
))
2791 returnValue
+= _mfRangeFarZone
.getBinSize();
2793 if(FieldBits::NoField
!= (TypeFieldMask
& whichField
))
2795 returnValue
+= _mfType
.getBinSize();
2797 if(FieldBits::NoField
!= (EnabledFieldMask
& whichField
))
2799 returnValue
+= _mfEnabled
.getBinSize();
2801 if(FieldBits::NoField
!= (BeaconFieldMask
& whichField
))
2803 returnValue
+= _mfBeacon
.getBinSize();
2805 if(FieldBits::NoField
!= (BeaconMatrixFieldMask
& whichField
))
2807 returnValue
+= _mfBeaconMatrix
.getBinSize();
2809 if(FieldBits::NoField
!= (EyeSpaceFieldMask
& whichField
))
2811 returnValue
+= _sfEyeSpace
.getBinSize();
2813 if(FieldBits::NoField
!= (LastCamNearFieldMask
& whichField
))
2815 returnValue
+= _sfLastCamNear
.getBinSize();
2817 if(FieldBits::NoField
!= (LastCamFarFieldMask
& whichField
))
2819 returnValue
+= _sfLastCamFar
.getBinSize();
2821 if(FieldBits::NoField
!= (LastCamToWorldFieldMask
& whichField
))
2823 returnValue
+= _sfLastCamToWorld
.getBinSize();
2825 if(FieldBits::NoField
!= (LightBlockNameFieldMask
& whichField
))
2827 returnValue
+= _sfLightBlockName
.getBinSize();
2829 if(FieldBits::NoField
!= (LightVariableNameFieldMask
& whichField
))
2831 returnValue
+= _sfLightVariableName
.getBinSize();
2837 void MultiLightChunkBase::copyToBin(BinaryDataHandler
&pMem
,
2838 ConstFieldMaskArg whichField
)
2840 Inherited::copyToBin(pMem
, whichField
);
2842 if(FieldBits::NoField
!= (HasWorldToLightSpaceMatrixFieldMask
& whichField
))
2844 _sfHasWorldToLightSpaceMatrix
.copyToBin(pMem
);
2846 if(FieldBits::NoField
!= (HasLightToWorldSpaceMatrixFieldMask
& whichField
))
2848 _sfHasLightToWorldSpaceMatrix
.copyToBin(pMem
);
2850 if(FieldBits::NoField
!= (HasEyeToLightSpaceMatrixFieldMask
& whichField
))
2852 _sfHasEyeToLightSpaceMatrix
.copyToBin(pMem
);
2854 if(FieldBits::NoField
!= (HasLightToEyeSpaceMatrixFieldMask
& whichField
))
2856 _sfHasLightToEyeSpaceMatrix
.copyToBin(pMem
);
2858 if(FieldBits::NoField
!= (HasLightPerspectiveMatrixFieldMask
& whichField
))
2860 _sfHasLightPerspectiveMatrix
.copyToBin(pMem
);
2862 if(FieldBits::NoField
!= (HasInvLightPerspectiveMatrixFieldMask
& whichField
))
2864 _sfHasInvLightPerspectiveMatrix
.copyToBin(pMem
);
2866 if(FieldBits::NoField
!= (HasColorFieldMask
& whichField
))
2868 _sfHasColor
.copyToBin(pMem
);
2870 if(FieldBits::NoField
!= (HasIntensityFieldMask
& whichField
))
2872 _sfHasIntensity
.copyToBin(pMem
);
2874 if(FieldBits::NoField
!= (HasSeparateIntensitiesFieldMask
& whichField
))
2876 _sfHasSeparateIntensities
.copyToBin(pMem
);
2878 if(FieldBits::NoField
!= (HasAttenuationFieldMask
& whichField
))
2880 _sfHasAttenuation
.copyToBin(pMem
);
2882 if(FieldBits::NoField
!= (AutoCalcRangesFieldMask
& whichField
))
2884 _sfAutoCalcRanges
.copyToBin(pMem
);
2886 if(FieldBits::NoField
!= (HasRangeCutOnFieldMask
& whichField
))
2888 _sfHasRangeCutOn
.copyToBin(pMem
);
2890 if(FieldBits::NoField
!= (HasRangeCutOffFieldMask
& whichField
))
2892 _sfHasRangeCutOff
.copyToBin(pMem
);
2894 if(FieldBits::NoField
!= (HasRangeNearZoneFieldMask
& whichField
))
2896 _sfHasRangeNearZone
.copyToBin(pMem
);
2898 if(FieldBits::NoField
!= (HasRangeFarZoneFieldMask
& whichField
))
2900 _sfHasRangeFarZone
.copyToBin(pMem
);
2902 if(FieldBits::NoField
!= (HasCosSpotlightAngleFieldMask
& whichField
))
2904 _sfHasCosSpotlightAngle
.copyToBin(pMem
);
2906 if(FieldBits::NoField
!= (HasSpotlightAngleFieldMask
& whichField
))
2908 _sfHasSpotlightAngle
.copyToBin(pMem
);
2910 if(FieldBits::NoField
!= (HasSpotExponentFieldMask
& whichField
))
2912 _sfHasSpotExponent
.copyToBin(pMem
);
2914 if(FieldBits::NoField
!= (HasCinemaLightFieldMask
& whichField
))
2916 _sfHasCinemaLight
.copyToBin(pMem
);
2918 if(FieldBits::NoField
!= (PositionFieldMask
& whichField
))
2920 _mfPosition
.copyToBin(pMem
);
2922 if(FieldBits::NoField
!= (DirectionFieldMask
& whichField
))
2924 _mfDirection
.copyToBin(pMem
);
2926 if(FieldBits::NoField
!= (ColorFieldMask
& whichField
))
2928 _mfColor
.copyToBin(pMem
);
2930 if(FieldBits::NoField
!= (IntensityFieldMask
& whichField
))
2932 _mfIntensity
.copyToBin(pMem
);
2934 if(FieldBits::NoField
!= (AmbientIntensityFieldMask
& whichField
))
2936 _mfAmbientIntensity
.copyToBin(pMem
);
2938 if(FieldBits::NoField
!= (DiffuseIntensityFieldMask
& whichField
))
2940 _mfDiffuseIntensity
.copyToBin(pMem
);
2942 if(FieldBits::NoField
!= (SpecularIntensityFieldMask
& whichField
))
2944 _mfSpecularIntensity
.copyToBin(pMem
);
2946 if(FieldBits::NoField
!= (AttenuationFieldMask
& whichField
))
2948 _mfAttenuation
.copyToBin(pMem
);
2950 if(FieldBits::NoField
!= (SpotlightAngleFieldMask
& whichField
))
2952 _mfSpotlightAngle
.copyToBin(pMem
);
2954 if(FieldBits::NoField
!= (SpotExponentFieldMask
& whichField
))
2956 _mfSpotExponent
.copyToBin(pMem
);
2958 if(FieldBits::NoField
!= (InnerSuperEllipsesWidthFieldMask
& whichField
))
2960 _mfInnerSuperEllipsesWidth
.copyToBin(pMem
);
2962 if(FieldBits::NoField
!= (InnerSuperEllipsesHeightFieldMask
& whichField
))
2964 _mfInnerSuperEllipsesHeight
.copyToBin(pMem
);
2966 if(FieldBits::NoField
!= (OuterSuperEllipsesWidthFieldMask
& whichField
))
2968 _mfOuterSuperEllipsesWidth
.copyToBin(pMem
);
2970 if(FieldBits::NoField
!= (OuterSuperEllipsesHeightFieldMask
& whichField
))
2972 _mfOuterSuperEllipsesHeight
.copyToBin(pMem
);
2974 if(FieldBits::NoField
!= (SuperEllipsesRoundnessFieldMask
& whichField
))
2976 _mfSuperEllipsesRoundness
.copyToBin(pMem
);
2978 if(FieldBits::NoField
!= (SuperEllipsesTwistFieldMask
& whichField
))
2980 _mfSuperEllipsesTwist
.copyToBin(pMem
);
2982 if(FieldBits::NoField
!= (RangeCutOnFieldMask
& whichField
))
2984 _mfRangeCutOn
.copyToBin(pMem
);
2986 if(FieldBits::NoField
!= (RangeCutOffFieldMask
& whichField
))
2988 _mfRangeCutOff
.copyToBin(pMem
);
2990 if(FieldBits::NoField
!= (RangeNearZoneFieldMask
& whichField
))
2992 _mfRangeNearZone
.copyToBin(pMem
);
2994 if(FieldBits::NoField
!= (RangeFarZoneFieldMask
& whichField
))
2996 _mfRangeFarZone
.copyToBin(pMem
);
2998 if(FieldBits::NoField
!= (TypeFieldMask
& whichField
))
3000 _mfType
.copyToBin(pMem
);
3002 if(FieldBits::NoField
!= (EnabledFieldMask
& whichField
))
3004 _mfEnabled
.copyToBin(pMem
);
3006 if(FieldBits::NoField
!= (BeaconFieldMask
& whichField
))
3008 _mfBeacon
.copyToBin(pMem
);
3010 if(FieldBits::NoField
!= (BeaconMatrixFieldMask
& whichField
))
3012 _mfBeaconMatrix
.copyToBin(pMem
);
3014 if(FieldBits::NoField
!= (EyeSpaceFieldMask
& whichField
))
3016 _sfEyeSpace
.copyToBin(pMem
);
3018 if(FieldBits::NoField
!= (LastCamNearFieldMask
& whichField
))
3020 _sfLastCamNear
.copyToBin(pMem
);
3022 if(FieldBits::NoField
!= (LastCamFarFieldMask
& whichField
))
3024 _sfLastCamFar
.copyToBin(pMem
);
3026 if(FieldBits::NoField
!= (LastCamToWorldFieldMask
& whichField
))
3028 _sfLastCamToWorld
.copyToBin(pMem
);
3030 if(FieldBits::NoField
!= (LightBlockNameFieldMask
& whichField
))
3032 _sfLightBlockName
.copyToBin(pMem
);
3034 if(FieldBits::NoField
!= (LightVariableNameFieldMask
& whichField
))
3036 _sfLightVariableName
.copyToBin(pMem
);
3040 void MultiLightChunkBase::copyFromBin(BinaryDataHandler
&pMem
,
3041 ConstFieldMaskArg whichField
)
3043 Inherited::copyFromBin(pMem
, whichField
);
3045 if(FieldBits::NoField
!= (HasWorldToLightSpaceMatrixFieldMask
& whichField
))
3047 editSField(HasWorldToLightSpaceMatrixFieldMask
);
3048 _sfHasWorldToLightSpaceMatrix
.copyFromBin(pMem
);
3050 if(FieldBits::NoField
!= (HasLightToWorldSpaceMatrixFieldMask
& whichField
))
3052 editSField(HasLightToWorldSpaceMatrixFieldMask
);
3053 _sfHasLightToWorldSpaceMatrix
.copyFromBin(pMem
);
3055 if(FieldBits::NoField
!= (HasEyeToLightSpaceMatrixFieldMask
& whichField
))
3057 editSField(HasEyeToLightSpaceMatrixFieldMask
);
3058 _sfHasEyeToLightSpaceMatrix
.copyFromBin(pMem
);
3060 if(FieldBits::NoField
!= (HasLightToEyeSpaceMatrixFieldMask
& whichField
))
3062 editSField(HasLightToEyeSpaceMatrixFieldMask
);
3063 _sfHasLightToEyeSpaceMatrix
.copyFromBin(pMem
);
3065 if(FieldBits::NoField
!= (HasLightPerspectiveMatrixFieldMask
& whichField
))
3067 editSField(HasLightPerspectiveMatrixFieldMask
);
3068 _sfHasLightPerspectiveMatrix
.copyFromBin(pMem
);
3070 if(FieldBits::NoField
!= (HasInvLightPerspectiveMatrixFieldMask
& whichField
))
3072 editSField(HasInvLightPerspectiveMatrixFieldMask
);
3073 _sfHasInvLightPerspectiveMatrix
.copyFromBin(pMem
);
3075 if(FieldBits::NoField
!= (HasColorFieldMask
& whichField
))
3077 editSField(HasColorFieldMask
);
3078 _sfHasColor
.copyFromBin(pMem
);
3080 if(FieldBits::NoField
!= (HasIntensityFieldMask
& whichField
))
3082 editSField(HasIntensityFieldMask
);
3083 _sfHasIntensity
.copyFromBin(pMem
);
3085 if(FieldBits::NoField
!= (HasSeparateIntensitiesFieldMask
& whichField
))
3087 editSField(HasSeparateIntensitiesFieldMask
);
3088 _sfHasSeparateIntensities
.copyFromBin(pMem
);
3090 if(FieldBits::NoField
!= (HasAttenuationFieldMask
& whichField
))
3092 editSField(HasAttenuationFieldMask
);
3093 _sfHasAttenuation
.copyFromBin(pMem
);
3095 if(FieldBits::NoField
!= (AutoCalcRangesFieldMask
& whichField
))
3097 editSField(AutoCalcRangesFieldMask
);
3098 _sfAutoCalcRanges
.copyFromBin(pMem
);
3100 if(FieldBits::NoField
!= (HasRangeCutOnFieldMask
& whichField
))
3102 editSField(HasRangeCutOnFieldMask
);
3103 _sfHasRangeCutOn
.copyFromBin(pMem
);
3105 if(FieldBits::NoField
!= (HasRangeCutOffFieldMask
& whichField
))
3107 editSField(HasRangeCutOffFieldMask
);
3108 _sfHasRangeCutOff
.copyFromBin(pMem
);
3110 if(FieldBits::NoField
!= (HasRangeNearZoneFieldMask
& whichField
))
3112 editSField(HasRangeNearZoneFieldMask
);
3113 _sfHasRangeNearZone
.copyFromBin(pMem
);
3115 if(FieldBits::NoField
!= (HasRangeFarZoneFieldMask
& whichField
))
3117 editSField(HasRangeFarZoneFieldMask
);
3118 _sfHasRangeFarZone
.copyFromBin(pMem
);
3120 if(FieldBits::NoField
!= (HasCosSpotlightAngleFieldMask
& whichField
))
3122 editSField(HasCosSpotlightAngleFieldMask
);
3123 _sfHasCosSpotlightAngle
.copyFromBin(pMem
);
3125 if(FieldBits::NoField
!= (HasSpotlightAngleFieldMask
& whichField
))
3127 editSField(HasSpotlightAngleFieldMask
);
3128 _sfHasSpotlightAngle
.copyFromBin(pMem
);
3130 if(FieldBits::NoField
!= (HasSpotExponentFieldMask
& whichField
))
3132 editSField(HasSpotExponentFieldMask
);
3133 _sfHasSpotExponent
.copyFromBin(pMem
);
3135 if(FieldBits::NoField
!= (HasCinemaLightFieldMask
& whichField
))
3137 editSField(HasCinemaLightFieldMask
);
3138 _sfHasCinemaLight
.copyFromBin(pMem
);
3140 if(FieldBits::NoField
!= (PositionFieldMask
& whichField
))
3142 editMField(PositionFieldMask
, _mfPosition
);
3143 _mfPosition
.copyFromBin(pMem
);
3145 if(FieldBits::NoField
!= (DirectionFieldMask
& whichField
))
3147 editMField(DirectionFieldMask
, _mfDirection
);
3148 _mfDirection
.copyFromBin(pMem
);
3150 if(FieldBits::NoField
!= (ColorFieldMask
& whichField
))
3152 editMField(ColorFieldMask
, _mfColor
);
3153 _mfColor
.copyFromBin(pMem
);
3155 if(FieldBits::NoField
!= (IntensityFieldMask
& whichField
))
3157 editMField(IntensityFieldMask
, _mfIntensity
);
3158 _mfIntensity
.copyFromBin(pMem
);
3160 if(FieldBits::NoField
!= (AmbientIntensityFieldMask
& whichField
))
3162 editMField(AmbientIntensityFieldMask
, _mfAmbientIntensity
);
3163 _mfAmbientIntensity
.copyFromBin(pMem
);
3165 if(FieldBits::NoField
!= (DiffuseIntensityFieldMask
& whichField
))
3167 editMField(DiffuseIntensityFieldMask
, _mfDiffuseIntensity
);
3168 _mfDiffuseIntensity
.copyFromBin(pMem
);
3170 if(FieldBits::NoField
!= (SpecularIntensityFieldMask
& whichField
))
3172 editMField(SpecularIntensityFieldMask
, _mfSpecularIntensity
);
3173 _mfSpecularIntensity
.copyFromBin(pMem
);
3175 if(FieldBits::NoField
!= (AttenuationFieldMask
& whichField
))
3177 editMField(AttenuationFieldMask
, _mfAttenuation
);
3178 _mfAttenuation
.copyFromBin(pMem
);
3180 if(FieldBits::NoField
!= (SpotlightAngleFieldMask
& whichField
))
3182 editMField(SpotlightAngleFieldMask
, _mfSpotlightAngle
);
3183 _mfSpotlightAngle
.copyFromBin(pMem
);
3185 if(FieldBits::NoField
!= (SpotExponentFieldMask
& whichField
))
3187 editMField(SpotExponentFieldMask
, _mfSpotExponent
);
3188 _mfSpotExponent
.copyFromBin(pMem
);
3190 if(FieldBits::NoField
!= (InnerSuperEllipsesWidthFieldMask
& whichField
))
3192 editMField(InnerSuperEllipsesWidthFieldMask
, _mfInnerSuperEllipsesWidth
);
3193 _mfInnerSuperEllipsesWidth
.copyFromBin(pMem
);
3195 if(FieldBits::NoField
!= (InnerSuperEllipsesHeightFieldMask
& whichField
))
3197 editMField(InnerSuperEllipsesHeightFieldMask
, _mfInnerSuperEllipsesHeight
);
3198 _mfInnerSuperEllipsesHeight
.copyFromBin(pMem
);
3200 if(FieldBits::NoField
!= (OuterSuperEllipsesWidthFieldMask
& whichField
))
3202 editMField(OuterSuperEllipsesWidthFieldMask
, _mfOuterSuperEllipsesWidth
);
3203 _mfOuterSuperEllipsesWidth
.copyFromBin(pMem
);
3205 if(FieldBits::NoField
!= (OuterSuperEllipsesHeightFieldMask
& whichField
))
3207 editMField(OuterSuperEllipsesHeightFieldMask
, _mfOuterSuperEllipsesHeight
);
3208 _mfOuterSuperEllipsesHeight
.copyFromBin(pMem
);
3210 if(FieldBits::NoField
!= (SuperEllipsesRoundnessFieldMask
& whichField
))
3212 editMField(SuperEllipsesRoundnessFieldMask
, _mfSuperEllipsesRoundness
);
3213 _mfSuperEllipsesRoundness
.copyFromBin(pMem
);
3215 if(FieldBits::NoField
!= (SuperEllipsesTwistFieldMask
& whichField
))
3217 editMField(SuperEllipsesTwistFieldMask
, _mfSuperEllipsesTwist
);
3218 _mfSuperEllipsesTwist
.copyFromBin(pMem
);
3220 if(FieldBits::NoField
!= (RangeCutOnFieldMask
& whichField
))
3222 editMField(RangeCutOnFieldMask
, _mfRangeCutOn
);
3223 _mfRangeCutOn
.copyFromBin(pMem
);
3225 if(FieldBits::NoField
!= (RangeCutOffFieldMask
& whichField
))
3227 editMField(RangeCutOffFieldMask
, _mfRangeCutOff
);
3228 _mfRangeCutOff
.copyFromBin(pMem
);
3230 if(FieldBits::NoField
!= (RangeNearZoneFieldMask
& whichField
))
3232 editMField(RangeNearZoneFieldMask
, _mfRangeNearZone
);
3233 _mfRangeNearZone
.copyFromBin(pMem
);
3235 if(FieldBits::NoField
!= (RangeFarZoneFieldMask
& whichField
))
3237 editMField(RangeFarZoneFieldMask
, _mfRangeFarZone
);
3238 _mfRangeFarZone
.copyFromBin(pMem
);
3240 if(FieldBits::NoField
!= (TypeFieldMask
& whichField
))
3242 editMField(TypeFieldMask
, _mfType
);
3243 _mfType
.copyFromBin(pMem
);
3245 if(FieldBits::NoField
!= (EnabledFieldMask
& whichField
))
3247 editMField(EnabledFieldMask
, _mfEnabled
);
3248 _mfEnabled
.copyFromBin(pMem
);
3250 if(FieldBits::NoField
!= (BeaconFieldMask
& whichField
))
3252 editMField(BeaconFieldMask
, _mfBeacon
);
3253 _mfBeacon
.copyFromBin(pMem
);
3255 if(FieldBits::NoField
!= (BeaconMatrixFieldMask
& whichField
))
3257 editMField(BeaconMatrixFieldMask
, _mfBeaconMatrix
);
3258 _mfBeaconMatrix
.copyFromBin(pMem
);
3260 if(FieldBits::NoField
!= (EyeSpaceFieldMask
& whichField
))
3262 editSField(EyeSpaceFieldMask
);
3263 _sfEyeSpace
.copyFromBin(pMem
);
3265 if(FieldBits::NoField
!= (LastCamNearFieldMask
& whichField
))
3267 editSField(LastCamNearFieldMask
);
3268 _sfLastCamNear
.copyFromBin(pMem
);
3270 if(FieldBits::NoField
!= (LastCamFarFieldMask
& whichField
))
3272 editSField(LastCamFarFieldMask
);
3273 _sfLastCamFar
.copyFromBin(pMem
);
3275 if(FieldBits::NoField
!= (LastCamToWorldFieldMask
& whichField
))
3277 editSField(LastCamToWorldFieldMask
);
3278 _sfLastCamToWorld
.copyFromBin(pMem
);
3280 if(FieldBits::NoField
!= (LightBlockNameFieldMask
& whichField
))
3282 editSField(LightBlockNameFieldMask
);
3283 _sfLightBlockName
.copyFromBin(pMem
);
3285 if(FieldBits::NoField
!= (LightVariableNameFieldMask
& whichField
))
3287 editSField(LightVariableNameFieldMask
);
3288 _sfLightVariableName
.copyFromBin(pMem
);
3292 //! create a new instance of the class
3293 MultiLightChunkTransitPtr
MultiLightChunkBase::createLocal(BitVector bFlags
)
3295 MultiLightChunkTransitPtr fc
;
3297 if(getClassType().getPrototype() != NULL
)
3299 FieldContainerTransitPtr tmpPtr
=
3300 getClassType().getPrototype()-> shallowCopyLocal(bFlags
);
3302 fc
= dynamic_pointer_cast
<MultiLightChunk
>(tmpPtr
);
3308 //! create a new instance of the class, copy the container flags
3309 MultiLightChunkTransitPtr
MultiLightChunkBase::createDependent(BitVector bFlags
)
3311 MultiLightChunkTransitPtr fc
;
3313 if(getClassType().getPrototype() != NULL
)
3315 FieldContainerTransitPtr tmpPtr
=
3316 getClassType().getPrototype()-> shallowCopyDependent(bFlags
);
3318 fc
= dynamic_pointer_cast
<MultiLightChunk
>(tmpPtr
);
3324 //! create a new instance of the class
3325 MultiLightChunkTransitPtr
MultiLightChunkBase::create(void)
3327 MultiLightChunkTransitPtr fc
;
3329 if(getClassType().getPrototype() != NULL
)
3331 FieldContainerTransitPtr tmpPtr
=
3332 getClassType().getPrototype()-> shallowCopy();
3334 fc
= dynamic_pointer_cast
<MultiLightChunk
>(tmpPtr
);
3340 MultiLightChunk
*MultiLightChunkBase::createEmptyLocal(BitVector bFlags
)
3342 MultiLightChunk
*returnValue
;
3344 newPtr
<MultiLightChunk
>(returnValue
, bFlags
);
3346 returnValue
->_pFieldFlags
->_bNamespaceMask
&= ~bFlags
;
3351 //! create an empty new instance of the class, do not copy the prototype
3352 MultiLightChunk
*MultiLightChunkBase::createEmpty(void)
3354 MultiLightChunk
*returnValue
;
3356 newPtr
<MultiLightChunk
>(returnValue
, Thread::getCurrentLocalFlags());
3358 returnValue
->_pFieldFlags
->_bNamespaceMask
&=
3359 ~Thread::getCurrentLocalFlags();
3365 FieldContainerTransitPtr
MultiLightChunkBase::shallowCopyLocal(
3366 BitVector bFlags
) const
3368 MultiLightChunk
*tmpPtr
;
3370 newPtr(tmpPtr
, dynamic_cast<const MultiLightChunk
*>(this), bFlags
);
3372 FieldContainerTransitPtr
returnValue(tmpPtr
);
3374 tmpPtr
->_pFieldFlags
->_bNamespaceMask
&= ~bFlags
;
3379 FieldContainerTransitPtr
MultiLightChunkBase::shallowCopyDependent(
3380 BitVector bFlags
) const
3382 MultiLightChunk
*tmpPtr
;
3384 newPtr(tmpPtr
, dynamic_cast<const MultiLightChunk
*>(this), ~bFlags
);
3386 FieldContainerTransitPtr
returnValue(tmpPtr
);
3388 tmpPtr
->_pFieldFlags
->_bNamespaceMask
= bFlags
;
3393 FieldContainerTransitPtr
MultiLightChunkBase::shallowCopy(void) const
3395 MultiLightChunk
*tmpPtr
;
3398 dynamic_cast<const MultiLightChunk
*>(this),
3399 Thread::getCurrentLocalFlags());
3401 tmpPtr
->_pFieldFlags
->_bNamespaceMask
&= ~Thread::getCurrentLocalFlags();
3403 FieldContainerTransitPtr
returnValue(tmpPtr
);
3411 /*------------------------- constructors ----------------------------------*/
3413 MultiLightChunkBase::MultiLightChunkBase(void) :
3415 _sfHasWorldToLightSpaceMatrix(bool(false)),
3416 _sfHasLightToWorldSpaceMatrix(bool(false)),
3417 _sfHasEyeToLightSpaceMatrix(bool(false)),
3418 _sfHasLightToEyeSpaceMatrix(bool(false)),
3419 _sfHasLightPerspectiveMatrix(bool(false)),
3420 _sfHasInvLightPerspectiveMatrix(bool(false)),
3421 _sfHasColor (bool(false)),
3422 _sfHasIntensity (bool(false)),
3423 _sfHasSeparateIntensities (bool(true)),
3424 _sfHasAttenuation (bool(true)),
3425 _sfAutoCalcRanges (bool(true)),
3426 _sfHasRangeCutOn (bool(false)),
3427 _sfHasRangeCutOff (bool(false)),
3428 _sfHasRangeNearZone (bool(false)),
3429 _sfHasRangeFarZone (bool(false)),
3430 _sfHasCosSpotlightAngle (bool(true)),
3431 _sfHasSpotlightAngle (bool(false)),
3432 _sfHasSpotExponent (bool(true)),
3433 _sfHasCinemaLight (bool(false)),
3438 _mfAmbientIntensity (),
3439 _mfDiffuseIntensity (),
3440 _mfSpecularIntensity (),
3442 _mfSpotlightAngle (),
3444 _mfInnerSuperEllipsesWidth(),
3445 _mfInnerSuperEllipsesHeight(),
3446 _mfOuterSuperEllipsesWidth(),
3447 _mfOuterSuperEllipsesHeight(),
3448 _mfSuperEllipsesRoundness (),
3449 _mfSuperEllipsesTwist (),
3452 _mfRangeNearZone (),
3458 _sfEyeSpace (bool(false)),
3459 _sfLastCamNear (Real32(0.f
)),
3460 _sfLastCamFar (Real32(0.f
)),
3461 _sfLastCamToWorld (),
3462 _sfLightBlockName (std::string("Lights")),
3463 _sfLightVariableName (std::string("lights"))
3467 MultiLightChunkBase::MultiLightChunkBase(const MultiLightChunkBase
&source
) :
3469 _sfHasWorldToLightSpaceMatrix(source
._sfHasWorldToLightSpaceMatrix
),
3470 _sfHasLightToWorldSpaceMatrix(source
._sfHasLightToWorldSpaceMatrix
),
3471 _sfHasEyeToLightSpaceMatrix(source
._sfHasEyeToLightSpaceMatrix
),
3472 _sfHasLightToEyeSpaceMatrix(source
._sfHasLightToEyeSpaceMatrix
),
3473 _sfHasLightPerspectiveMatrix(source
._sfHasLightPerspectiveMatrix
),
3474 _sfHasInvLightPerspectiveMatrix(source
._sfHasInvLightPerspectiveMatrix
),
3475 _sfHasColor (source
._sfHasColor
),
3476 _sfHasIntensity (source
._sfHasIntensity
),
3477 _sfHasSeparateIntensities (source
._sfHasSeparateIntensities
),
3478 _sfHasAttenuation (source
._sfHasAttenuation
),
3479 _sfAutoCalcRanges (source
._sfAutoCalcRanges
),
3480 _sfHasRangeCutOn (source
._sfHasRangeCutOn
),
3481 _sfHasRangeCutOff (source
._sfHasRangeCutOff
),
3482 _sfHasRangeNearZone (source
._sfHasRangeNearZone
),
3483 _sfHasRangeFarZone (source
._sfHasRangeFarZone
),
3484 _sfHasCosSpotlightAngle (source
._sfHasCosSpotlightAngle
),
3485 _sfHasSpotlightAngle (source
._sfHasSpotlightAngle
),
3486 _sfHasSpotExponent (source
._sfHasSpotExponent
),
3487 _sfHasCinemaLight (source
._sfHasCinemaLight
),
3488 _mfPosition (source
._mfPosition
),
3489 _mfDirection (source
._mfDirection
),
3490 _mfColor (source
._mfColor
),
3491 _mfIntensity (source
._mfIntensity
),
3492 _mfAmbientIntensity (source
._mfAmbientIntensity
),
3493 _mfDiffuseIntensity (source
._mfDiffuseIntensity
),
3494 _mfSpecularIntensity (source
._mfSpecularIntensity
),
3495 _mfAttenuation (source
._mfAttenuation
),
3496 _mfSpotlightAngle (source
._mfSpotlightAngle
),
3497 _mfSpotExponent (source
._mfSpotExponent
),
3498 _mfInnerSuperEllipsesWidth(source
._mfInnerSuperEllipsesWidth
),
3499 _mfInnerSuperEllipsesHeight(source
._mfInnerSuperEllipsesHeight
),
3500 _mfOuterSuperEllipsesWidth(source
._mfOuterSuperEllipsesWidth
),
3501 _mfOuterSuperEllipsesHeight(source
._mfOuterSuperEllipsesHeight
),
3502 _mfSuperEllipsesRoundness (source
._mfSuperEllipsesRoundness
),
3503 _mfSuperEllipsesTwist (source
._mfSuperEllipsesTwist
),
3504 _mfRangeCutOn (source
._mfRangeCutOn
),
3505 _mfRangeCutOff (source
._mfRangeCutOff
),
3506 _mfRangeNearZone (source
._mfRangeNearZone
),
3507 _mfRangeFarZone (source
._mfRangeFarZone
),
3508 _mfType (source
._mfType
),
3509 _mfEnabled (source
._mfEnabled
),
3511 _mfBeaconMatrix (source
._mfBeaconMatrix
),
3512 _sfEyeSpace (source
._sfEyeSpace
),
3513 _sfLastCamNear (source
._sfLastCamNear
),
3514 _sfLastCamFar (source
._sfLastCamFar
),
3515 _sfLastCamToWorld (source
._sfLastCamToWorld
),
3516 _sfLightBlockName (source
._sfLightBlockName
),
3517 _sfLightVariableName (source
._sfLightVariableName
)
3522 /*-------------------------- destructors ----------------------------------*/
3524 MultiLightChunkBase::~MultiLightChunkBase(void)
3528 void MultiLightChunkBase::onCreate(const MultiLightChunk
*source
)
3530 Inherited::onCreate(source
);
3534 MultiLightChunk
*pThis
= static_cast<MultiLightChunk
*>(this);
3536 MFWeakNodePtr::const_iterator BeaconIt
=
3537 source
->_mfBeacon
.begin();
3538 MFWeakNodePtr::const_iterator BeaconEnd
=
3539 source
->_mfBeacon
.end ();
3541 while(BeaconIt
!= BeaconEnd
)
3543 pThis
->pushToBeacon(*BeaconIt
);
3550 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasWorldToLightSpaceMatrix (void) const
3552 SFBool::GetHandlePtr
returnValue(
3553 new SFBool::GetHandle(
3554 &_sfHasWorldToLightSpaceMatrix
,
3555 this->getType().getFieldDesc(HasWorldToLightSpaceMatrixFieldId
),
3556 const_cast<MultiLightChunkBase
*>(this)));
3561 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasWorldToLightSpaceMatrix(void)
3563 SFBool::EditHandlePtr
returnValue(
3564 new SFBool::EditHandle(
3565 &_sfHasWorldToLightSpaceMatrix
,
3566 this->getType().getFieldDesc(HasWorldToLightSpaceMatrixFieldId
),
3570 editSField(HasWorldToLightSpaceMatrixFieldMask
);
3575 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasLightToWorldSpaceMatrix (void) const
3577 SFBool::GetHandlePtr
returnValue(
3578 new SFBool::GetHandle(
3579 &_sfHasLightToWorldSpaceMatrix
,
3580 this->getType().getFieldDesc(HasLightToWorldSpaceMatrixFieldId
),
3581 const_cast<MultiLightChunkBase
*>(this)));
3586 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasLightToWorldSpaceMatrix(void)
3588 SFBool::EditHandlePtr
returnValue(
3589 new SFBool::EditHandle(
3590 &_sfHasLightToWorldSpaceMatrix
,
3591 this->getType().getFieldDesc(HasLightToWorldSpaceMatrixFieldId
),
3595 editSField(HasLightToWorldSpaceMatrixFieldMask
);
3600 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasEyeToLightSpaceMatrix (void) const
3602 SFBool::GetHandlePtr
returnValue(
3603 new SFBool::GetHandle(
3604 &_sfHasEyeToLightSpaceMatrix
,
3605 this->getType().getFieldDesc(HasEyeToLightSpaceMatrixFieldId
),
3606 const_cast<MultiLightChunkBase
*>(this)));
3611 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasEyeToLightSpaceMatrix(void)
3613 SFBool::EditHandlePtr
returnValue(
3614 new SFBool::EditHandle(
3615 &_sfHasEyeToLightSpaceMatrix
,
3616 this->getType().getFieldDesc(HasEyeToLightSpaceMatrixFieldId
),
3620 editSField(HasEyeToLightSpaceMatrixFieldMask
);
3625 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasLightToEyeSpaceMatrix (void) const
3627 SFBool::GetHandlePtr
returnValue(
3628 new SFBool::GetHandle(
3629 &_sfHasLightToEyeSpaceMatrix
,
3630 this->getType().getFieldDesc(HasLightToEyeSpaceMatrixFieldId
),
3631 const_cast<MultiLightChunkBase
*>(this)));
3636 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasLightToEyeSpaceMatrix(void)
3638 SFBool::EditHandlePtr
returnValue(
3639 new SFBool::EditHandle(
3640 &_sfHasLightToEyeSpaceMatrix
,
3641 this->getType().getFieldDesc(HasLightToEyeSpaceMatrixFieldId
),
3645 editSField(HasLightToEyeSpaceMatrixFieldMask
);
3650 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasLightPerspectiveMatrix (void) const
3652 SFBool::GetHandlePtr
returnValue(
3653 new SFBool::GetHandle(
3654 &_sfHasLightPerspectiveMatrix
,
3655 this->getType().getFieldDesc(HasLightPerspectiveMatrixFieldId
),
3656 const_cast<MultiLightChunkBase
*>(this)));
3661 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasLightPerspectiveMatrix(void)
3663 SFBool::EditHandlePtr
returnValue(
3664 new SFBool::EditHandle(
3665 &_sfHasLightPerspectiveMatrix
,
3666 this->getType().getFieldDesc(HasLightPerspectiveMatrixFieldId
),
3670 editSField(HasLightPerspectiveMatrixFieldMask
);
3675 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasInvLightPerspectiveMatrix (void) const
3677 SFBool::GetHandlePtr
returnValue(
3678 new SFBool::GetHandle(
3679 &_sfHasInvLightPerspectiveMatrix
,
3680 this->getType().getFieldDesc(HasInvLightPerspectiveMatrixFieldId
),
3681 const_cast<MultiLightChunkBase
*>(this)));
3686 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasInvLightPerspectiveMatrix(void)
3688 SFBool::EditHandlePtr
returnValue(
3689 new SFBool::EditHandle(
3690 &_sfHasInvLightPerspectiveMatrix
,
3691 this->getType().getFieldDesc(HasInvLightPerspectiveMatrixFieldId
),
3695 editSField(HasInvLightPerspectiveMatrixFieldMask
);
3700 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasColor (void) const
3702 SFBool::GetHandlePtr
returnValue(
3703 new SFBool::GetHandle(
3705 this->getType().getFieldDesc(HasColorFieldId
),
3706 const_cast<MultiLightChunkBase
*>(this)));
3711 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasColor (void)
3713 SFBool::EditHandlePtr
returnValue(
3714 new SFBool::EditHandle(
3716 this->getType().getFieldDesc(HasColorFieldId
),
3720 editSField(HasColorFieldMask
);
3725 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasIntensity (void) const
3727 SFBool::GetHandlePtr
returnValue(
3728 new SFBool::GetHandle(
3730 this->getType().getFieldDesc(HasIntensityFieldId
),
3731 const_cast<MultiLightChunkBase
*>(this)));
3736 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasIntensity (void)
3738 SFBool::EditHandlePtr
returnValue(
3739 new SFBool::EditHandle(
3741 this->getType().getFieldDesc(HasIntensityFieldId
),
3745 editSField(HasIntensityFieldMask
);
3750 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasSeparateIntensities (void) const
3752 SFBool::GetHandlePtr
returnValue(
3753 new SFBool::GetHandle(
3754 &_sfHasSeparateIntensities
,
3755 this->getType().getFieldDesc(HasSeparateIntensitiesFieldId
),
3756 const_cast<MultiLightChunkBase
*>(this)));
3761 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasSeparateIntensities(void)
3763 SFBool::EditHandlePtr
returnValue(
3764 new SFBool::EditHandle(
3765 &_sfHasSeparateIntensities
,
3766 this->getType().getFieldDesc(HasSeparateIntensitiesFieldId
),
3770 editSField(HasSeparateIntensitiesFieldMask
);
3775 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasAttenuation (void) const
3777 SFBool::GetHandlePtr
returnValue(
3778 new SFBool::GetHandle(
3780 this->getType().getFieldDesc(HasAttenuationFieldId
),
3781 const_cast<MultiLightChunkBase
*>(this)));
3786 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasAttenuation (void)
3788 SFBool::EditHandlePtr
returnValue(
3789 new SFBool::EditHandle(
3791 this->getType().getFieldDesc(HasAttenuationFieldId
),
3795 editSField(HasAttenuationFieldMask
);
3800 GetFieldHandlePtr
MultiLightChunkBase::getHandleAutoCalcRanges (void) const
3802 SFBool::GetHandlePtr
returnValue(
3803 new SFBool::GetHandle(
3805 this->getType().getFieldDesc(AutoCalcRangesFieldId
),
3806 const_cast<MultiLightChunkBase
*>(this)));
3811 EditFieldHandlePtr
MultiLightChunkBase::editHandleAutoCalcRanges (void)
3813 SFBool::EditHandlePtr
returnValue(
3814 new SFBool::EditHandle(
3816 this->getType().getFieldDesc(AutoCalcRangesFieldId
),
3820 editSField(AutoCalcRangesFieldMask
);
3825 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasRangeCutOn (void) const
3827 SFBool::GetHandlePtr
returnValue(
3828 new SFBool::GetHandle(
3830 this->getType().getFieldDesc(HasRangeCutOnFieldId
),
3831 const_cast<MultiLightChunkBase
*>(this)));
3836 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasRangeCutOn (void)
3838 SFBool::EditHandlePtr
returnValue(
3839 new SFBool::EditHandle(
3841 this->getType().getFieldDesc(HasRangeCutOnFieldId
),
3845 editSField(HasRangeCutOnFieldMask
);
3850 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasRangeCutOff (void) const
3852 SFBool::GetHandlePtr
returnValue(
3853 new SFBool::GetHandle(
3855 this->getType().getFieldDesc(HasRangeCutOffFieldId
),
3856 const_cast<MultiLightChunkBase
*>(this)));
3861 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasRangeCutOff (void)
3863 SFBool::EditHandlePtr
returnValue(
3864 new SFBool::EditHandle(
3866 this->getType().getFieldDesc(HasRangeCutOffFieldId
),
3870 editSField(HasRangeCutOffFieldMask
);
3875 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasRangeNearZone (void) const
3877 SFBool::GetHandlePtr
returnValue(
3878 new SFBool::GetHandle(
3879 &_sfHasRangeNearZone
,
3880 this->getType().getFieldDesc(HasRangeNearZoneFieldId
),
3881 const_cast<MultiLightChunkBase
*>(this)));
3886 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasRangeNearZone(void)
3888 SFBool::EditHandlePtr
returnValue(
3889 new SFBool::EditHandle(
3890 &_sfHasRangeNearZone
,
3891 this->getType().getFieldDesc(HasRangeNearZoneFieldId
),
3895 editSField(HasRangeNearZoneFieldMask
);
3900 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasRangeFarZone (void) const
3902 SFBool::GetHandlePtr
returnValue(
3903 new SFBool::GetHandle(
3904 &_sfHasRangeFarZone
,
3905 this->getType().getFieldDesc(HasRangeFarZoneFieldId
),
3906 const_cast<MultiLightChunkBase
*>(this)));
3911 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasRangeFarZone(void)
3913 SFBool::EditHandlePtr
returnValue(
3914 new SFBool::EditHandle(
3915 &_sfHasRangeFarZone
,
3916 this->getType().getFieldDesc(HasRangeFarZoneFieldId
),
3920 editSField(HasRangeFarZoneFieldMask
);
3925 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasCosSpotlightAngle (void) const
3927 SFBool::GetHandlePtr
returnValue(
3928 new SFBool::GetHandle(
3929 &_sfHasCosSpotlightAngle
,
3930 this->getType().getFieldDesc(HasCosSpotlightAngleFieldId
),
3931 const_cast<MultiLightChunkBase
*>(this)));
3936 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasCosSpotlightAngle(void)
3938 SFBool::EditHandlePtr
returnValue(
3939 new SFBool::EditHandle(
3940 &_sfHasCosSpotlightAngle
,
3941 this->getType().getFieldDesc(HasCosSpotlightAngleFieldId
),
3945 editSField(HasCosSpotlightAngleFieldMask
);
3950 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasSpotlightAngle (void) const
3952 SFBool::GetHandlePtr
returnValue(
3953 new SFBool::GetHandle(
3954 &_sfHasSpotlightAngle
,
3955 this->getType().getFieldDesc(HasSpotlightAngleFieldId
),
3956 const_cast<MultiLightChunkBase
*>(this)));
3961 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasSpotlightAngle(void)
3963 SFBool::EditHandlePtr
returnValue(
3964 new SFBool::EditHandle(
3965 &_sfHasSpotlightAngle
,
3966 this->getType().getFieldDesc(HasSpotlightAngleFieldId
),
3970 editSField(HasSpotlightAngleFieldMask
);
3975 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasSpotExponent (void) const
3977 SFBool::GetHandlePtr
returnValue(
3978 new SFBool::GetHandle(
3979 &_sfHasSpotExponent
,
3980 this->getType().getFieldDesc(HasSpotExponentFieldId
),
3981 const_cast<MultiLightChunkBase
*>(this)));
3986 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasSpotExponent(void)
3988 SFBool::EditHandlePtr
returnValue(
3989 new SFBool::EditHandle(
3990 &_sfHasSpotExponent
,
3991 this->getType().getFieldDesc(HasSpotExponentFieldId
),
3995 editSField(HasSpotExponentFieldMask
);
4000 GetFieldHandlePtr
MultiLightChunkBase::getHandleHasCinemaLight (void) const
4002 SFBool::GetHandlePtr
returnValue(
4003 new SFBool::GetHandle(
4005 this->getType().getFieldDesc(HasCinemaLightFieldId
),
4006 const_cast<MultiLightChunkBase
*>(this)));
4011 EditFieldHandlePtr
MultiLightChunkBase::editHandleHasCinemaLight (void)
4013 SFBool::EditHandlePtr
returnValue(
4014 new SFBool::EditHandle(
4016 this->getType().getFieldDesc(HasCinemaLightFieldId
),
4020 editSField(HasCinemaLightFieldMask
);
4025 GetFieldHandlePtr
MultiLightChunkBase::getHandlePosition (void) const
4027 MFPnt3f::GetHandlePtr
returnValue(
4028 new MFPnt3f::GetHandle(
4030 this->getType().getFieldDesc(PositionFieldId
),
4031 const_cast<MultiLightChunkBase
*>(this)));
4036 EditFieldHandlePtr
MultiLightChunkBase::editHandlePosition (void)
4038 MFPnt3f::EditHandlePtr
returnValue(
4039 new MFPnt3f::EditHandle(
4041 this->getType().getFieldDesc(PositionFieldId
),
4045 editMField(PositionFieldMask
, _mfPosition
);
4050 GetFieldHandlePtr
MultiLightChunkBase::getHandleDirection (void) const
4052 MFVec3f::GetHandlePtr
returnValue(
4053 new MFVec3f::GetHandle(
4055 this->getType().getFieldDesc(DirectionFieldId
),
4056 const_cast<MultiLightChunkBase
*>(this)));
4061 EditFieldHandlePtr
MultiLightChunkBase::editHandleDirection (void)
4063 MFVec3f::EditHandlePtr
returnValue(
4064 new MFVec3f::EditHandle(
4066 this->getType().getFieldDesc(DirectionFieldId
),
4070 editMField(DirectionFieldMask
, _mfDirection
);
4075 GetFieldHandlePtr
MultiLightChunkBase::getHandleColor (void) const
4077 MFColor3f::GetHandlePtr
returnValue(
4078 new MFColor3f::GetHandle(
4080 this->getType().getFieldDesc(ColorFieldId
),
4081 const_cast<MultiLightChunkBase
*>(this)));
4086 EditFieldHandlePtr
MultiLightChunkBase::editHandleColor (void)
4088 MFColor3f::EditHandlePtr
returnValue(
4089 new MFColor3f::EditHandle(
4091 this->getType().getFieldDesc(ColorFieldId
),
4095 editMField(ColorFieldMask
, _mfColor
);
4100 GetFieldHandlePtr
MultiLightChunkBase::getHandleIntensity (void) const
4102 MFReal32::GetHandlePtr
returnValue(
4103 new MFReal32::GetHandle(
4105 this->getType().getFieldDesc(IntensityFieldId
),
4106 const_cast<MultiLightChunkBase
*>(this)));
4111 EditFieldHandlePtr
MultiLightChunkBase::editHandleIntensity (void)
4113 MFReal32::EditHandlePtr
returnValue(
4114 new MFReal32::EditHandle(
4116 this->getType().getFieldDesc(IntensityFieldId
),
4120 editMField(IntensityFieldMask
, _mfIntensity
);
4125 GetFieldHandlePtr
MultiLightChunkBase::getHandleAmbientIntensity (void) const
4127 MFVec3f::GetHandlePtr
returnValue(
4128 new MFVec3f::GetHandle(
4129 &_mfAmbientIntensity
,
4130 this->getType().getFieldDesc(AmbientIntensityFieldId
),
4131 const_cast<MultiLightChunkBase
*>(this)));
4136 EditFieldHandlePtr
MultiLightChunkBase::editHandleAmbientIntensity(void)
4138 MFVec3f::EditHandlePtr
returnValue(
4139 new MFVec3f::EditHandle(
4140 &_mfAmbientIntensity
,
4141 this->getType().getFieldDesc(AmbientIntensityFieldId
),
4145 editMField(AmbientIntensityFieldMask
, _mfAmbientIntensity
);
4150 GetFieldHandlePtr
MultiLightChunkBase::getHandleDiffuseIntensity (void) const
4152 MFVec3f::GetHandlePtr
returnValue(
4153 new MFVec3f::GetHandle(
4154 &_mfDiffuseIntensity
,
4155 this->getType().getFieldDesc(DiffuseIntensityFieldId
),
4156 const_cast<MultiLightChunkBase
*>(this)));
4161 EditFieldHandlePtr
MultiLightChunkBase::editHandleDiffuseIntensity(void)
4163 MFVec3f::EditHandlePtr
returnValue(
4164 new MFVec3f::EditHandle(
4165 &_mfDiffuseIntensity
,
4166 this->getType().getFieldDesc(DiffuseIntensityFieldId
),
4170 editMField(DiffuseIntensityFieldMask
, _mfDiffuseIntensity
);
4175 GetFieldHandlePtr
MultiLightChunkBase::getHandleSpecularIntensity (void) const
4177 MFVec3f::GetHandlePtr
returnValue(
4178 new MFVec3f::GetHandle(
4179 &_mfSpecularIntensity
,
4180 this->getType().getFieldDesc(SpecularIntensityFieldId
),
4181 const_cast<MultiLightChunkBase
*>(this)));
4186 EditFieldHandlePtr
MultiLightChunkBase::editHandleSpecularIntensity(void)
4188 MFVec3f::EditHandlePtr
returnValue(
4189 new MFVec3f::EditHandle(
4190 &_mfSpecularIntensity
,
4191 this->getType().getFieldDesc(SpecularIntensityFieldId
),
4195 editMField(SpecularIntensityFieldMask
, _mfSpecularIntensity
);
4200 GetFieldHandlePtr
MultiLightChunkBase::getHandleAttenuation (void) const
4202 MFVec3f::GetHandlePtr
returnValue(
4203 new MFVec3f::GetHandle(
4205 this->getType().getFieldDesc(AttenuationFieldId
),
4206 const_cast<MultiLightChunkBase
*>(this)));
4211 EditFieldHandlePtr
MultiLightChunkBase::editHandleAttenuation (void)
4213 MFVec3f::EditHandlePtr
returnValue(
4214 new MFVec3f::EditHandle(
4216 this->getType().getFieldDesc(AttenuationFieldId
),
4220 editMField(AttenuationFieldMask
, _mfAttenuation
);
4225 GetFieldHandlePtr
MultiLightChunkBase::getHandleSpotlightAngle (void) const
4227 MFReal32::GetHandlePtr
returnValue(
4228 new MFReal32::GetHandle(
4230 this->getType().getFieldDesc(SpotlightAngleFieldId
),
4231 const_cast<MultiLightChunkBase
*>(this)));
4236 EditFieldHandlePtr
MultiLightChunkBase::editHandleSpotlightAngle (void)
4238 MFReal32::EditHandlePtr
returnValue(
4239 new MFReal32::EditHandle(
4241 this->getType().getFieldDesc(SpotlightAngleFieldId
),
4245 editMField(SpotlightAngleFieldMask
, _mfSpotlightAngle
);
4250 GetFieldHandlePtr
MultiLightChunkBase::getHandleSpotExponent (void) const
4252 MFReal32::GetHandlePtr
returnValue(
4253 new MFReal32::GetHandle(
4255 this->getType().getFieldDesc(SpotExponentFieldId
),
4256 const_cast<MultiLightChunkBase
*>(this)));
4261 EditFieldHandlePtr
MultiLightChunkBase::editHandleSpotExponent (void)
4263 MFReal32::EditHandlePtr
returnValue(
4264 new MFReal32::EditHandle(
4266 this->getType().getFieldDesc(SpotExponentFieldId
),
4270 editMField(SpotExponentFieldMask
, _mfSpotExponent
);
4275 GetFieldHandlePtr
MultiLightChunkBase::getHandleInnerSuperEllipsesWidth (void) const
4277 MFReal32::GetHandlePtr
returnValue(
4278 new MFReal32::GetHandle(
4279 &_mfInnerSuperEllipsesWidth
,
4280 this->getType().getFieldDesc(InnerSuperEllipsesWidthFieldId
),
4281 const_cast<MultiLightChunkBase
*>(this)));
4286 EditFieldHandlePtr
MultiLightChunkBase::editHandleInnerSuperEllipsesWidth(void)
4288 MFReal32::EditHandlePtr
returnValue(
4289 new MFReal32::EditHandle(
4290 &_mfInnerSuperEllipsesWidth
,
4291 this->getType().getFieldDesc(InnerSuperEllipsesWidthFieldId
),
4295 editMField(InnerSuperEllipsesWidthFieldMask
, _mfInnerSuperEllipsesWidth
);
4300 GetFieldHandlePtr
MultiLightChunkBase::getHandleInnerSuperEllipsesHeight (void) const
4302 MFReal32::GetHandlePtr
returnValue(
4303 new MFReal32::GetHandle(
4304 &_mfInnerSuperEllipsesHeight
,
4305 this->getType().getFieldDesc(InnerSuperEllipsesHeightFieldId
),
4306 const_cast<MultiLightChunkBase
*>(this)));
4311 EditFieldHandlePtr
MultiLightChunkBase::editHandleInnerSuperEllipsesHeight(void)
4313 MFReal32::EditHandlePtr
returnValue(
4314 new MFReal32::EditHandle(
4315 &_mfInnerSuperEllipsesHeight
,
4316 this->getType().getFieldDesc(InnerSuperEllipsesHeightFieldId
),
4320 editMField(InnerSuperEllipsesHeightFieldMask
, _mfInnerSuperEllipsesHeight
);
4325 GetFieldHandlePtr
MultiLightChunkBase::getHandleOuterSuperEllipsesWidth (void) const
4327 MFReal32::GetHandlePtr
returnValue(
4328 new MFReal32::GetHandle(
4329 &_mfOuterSuperEllipsesWidth
,
4330 this->getType().getFieldDesc(OuterSuperEllipsesWidthFieldId
),
4331 const_cast<MultiLightChunkBase
*>(this)));
4336 EditFieldHandlePtr
MultiLightChunkBase::editHandleOuterSuperEllipsesWidth(void)
4338 MFReal32::EditHandlePtr
returnValue(
4339 new MFReal32::EditHandle(
4340 &_mfOuterSuperEllipsesWidth
,
4341 this->getType().getFieldDesc(OuterSuperEllipsesWidthFieldId
),
4345 editMField(OuterSuperEllipsesWidthFieldMask
, _mfOuterSuperEllipsesWidth
);
4350 GetFieldHandlePtr
MultiLightChunkBase::getHandleOuterSuperEllipsesHeight (void) const
4352 MFReal32::GetHandlePtr
returnValue(
4353 new MFReal32::GetHandle(
4354 &_mfOuterSuperEllipsesHeight
,
4355 this->getType().getFieldDesc(OuterSuperEllipsesHeightFieldId
),
4356 const_cast<MultiLightChunkBase
*>(this)));
4361 EditFieldHandlePtr
MultiLightChunkBase::editHandleOuterSuperEllipsesHeight(void)
4363 MFReal32::EditHandlePtr
returnValue(
4364 new MFReal32::EditHandle(
4365 &_mfOuterSuperEllipsesHeight
,
4366 this->getType().getFieldDesc(OuterSuperEllipsesHeightFieldId
),
4370 editMField(OuterSuperEllipsesHeightFieldMask
, _mfOuterSuperEllipsesHeight
);
4375 GetFieldHandlePtr
MultiLightChunkBase::getHandleSuperEllipsesRoundness (void) const
4377 MFReal32::GetHandlePtr
returnValue(
4378 new MFReal32::GetHandle(
4379 &_mfSuperEllipsesRoundness
,
4380 this->getType().getFieldDesc(SuperEllipsesRoundnessFieldId
),
4381 const_cast<MultiLightChunkBase
*>(this)));
4386 EditFieldHandlePtr
MultiLightChunkBase::editHandleSuperEllipsesRoundness(void)
4388 MFReal32::EditHandlePtr
returnValue(
4389 new MFReal32::EditHandle(
4390 &_mfSuperEllipsesRoundness
,
4391 this->getType().getFieldDesc(SuperEllipsesRoundnessFieldId
),
4395 editMField(SuperEllipsesRoundnessFieldMask
, _mfSuperEllipsesRoundness
);
4400 GetFieldHandlePtr
MultiLightChunkBase::getHandleSuperEllipsesTwist (void) const
4402 MFReal32::GetHandlePtr
returnValue(
4403 new MFReal32::GetHandle(
4404 &_mfSuperEllipsesTwist
,
4405 this->getType().getFieldDesc(SuperEllipsesTwistFieldId
),
4406 const_cast<MultiLightChunkBase
*>(this)));
4411 EditFieldHandlePtr
MultiLightChunkBase::editHandleSuperEllipsesTwist(void)
4413 MFReal32::EditHandlePtr
returnValue(
4414 new MFReal32::EditHandle(
4415 &_mfSuperEllipsesTwist
,
4416 this->getType().getFieldDesc(SuperEllipsesTwistFieldId
),
4420 editMField(SuperEllipsesTwistFieldMask
, _mfSuperEllipsesTwist
);
4425 GetFieldHandlePtr
MultiLightChunkBase::getHandleRangeCutOn (void) const
4427 MFReal32::GetHandlePtr
returnValue(
4428 new MFReal32::GetHandle(
4430 this->getType().getFieldDesc(RangeCutOnFieldId
),
4431 const_cast<MultiLightChunkBase
*>(this)));
4436 EditFieldHandlePtr
MultiLightChunkBase::editHandleRangeCutOn (void)
4438 MFReal32::EditHandlePtr
returnValue(
4439 new MFReal32::EditHandle(
4441 this->getType().getFieldDesc(RangeCutOnFieldId
),
4445 editMField(RangeCutOnFieldMask
, _mfRangeCutOn
);
4450 GetFieldHandlePtr
MultiLightChunkBase::getHandleRangeCutOff (void) const
4452 MFReal32::GetHandlePtr
returnValue(
4453 new MFReal32::GetHandle(
4455 this->getType().getFieldDesc(RangeCutOffFieldId
),
4456 const_cast<MultiLightChunkBase
*>(this)));
4461 EditFieldHandlePtr
MultiLightChunkBase::editHandleRangeCutOff (void)
4463 MFReal32::EditHandlePtr
returnValue(
4464 new MFReal32::EditHandle(
4466 this->getType().getFieldDesc(RangeCutOffFieldId
),
4470 editMField(RangeCutOffFieldMask
, _mfRangeCutOff
);
4475 GetFieldHandlePtr
MultiLightChunkBase::getHandleRangeNearZone (void) const
4477 MFReal32::GetHandlePtr
returnValue(
4478 new MFReal32::GetHandle(
4480 this->getType().getFieldDesc(RangeNearZoneFieldId
),
4481 const_cast<MultiLightChunkBase
*>(this)));
4486 EditFieldHandlePtr
MultiLightChunkBase::editHandleRangeNearZone (void)
4488 MFReal32::EditHandlePtr
returnValue(
4489 new MFReal32::EditHandle(
4491 this->getType().getFieldDesc(RangeNearZoneFieldId
),
4495 editMField(RangeNearZoneFieldMask
, _mfRangeNearZone
);
4500 GetFieldHandlePtr
MultiLightChunkBase::getHandleRangeFarZone (void) const
4502 MFReal32::GetHandlePtr
returnValue(
4503 new MFReal32::GetHandle(
4505 this->getType().getFieldDesc(RangeFarZoneFieldId
),
4506 const_cast<MultiLightChunkBase
*>(this)));
4511 EditFieldHandlePtr
MultiLightChunkBase::editHandleRangeFarZone (void)
4513 MFReal32::EditHandlePtr
returnValue(
4514 new MFReal32::EditHandle(
4516 this->getType().getFieldDesc(RangeFarZoneFieldId
),
4520 editMField(RangeFarZoneFieldMask
, _mfRangeFarZone
);
4525 GetFieldHandlePtr
MultiLightChunkBase::getHandleType (void) const
4527 MFUInt8::GetHandlePtr
returnValue(
4528 new MFUInt8::GetHandle(
4530 this->getType().getFieldDesc(TypeFieldId
),
4531 const_cast<MultiLightChunkBase
*>(this)));
4536 EditFieldHandlePtr
MultiLightChunkBase::editHandleType (void)
4538 MFUInt8::EditHandlePtr
returnValue(
4539 new MFUInt8::EditHandle(
4541 this->getType().getFieldDesc(TypeFieldId
),
4545 editMField(TypeFieldMask
, _mfType
);
4550 GetFieldHandlePtr
MultiLightChunkBase::getHandleEnabled (void) const
4552 MFBool::GetHandlePtr
returnValue(
4553 new MFBool::GetHandle(
4555 this->getType().getFieldDesc(EnabledFieldId
),
4556 const_cast<MultiLightChunkBase
*>(this)));
4561 EditFieldHandlePtr
MultiLightChunkBase::editHandleEnabled (void)
4563 MFBool::EditHandlePtr
returnValue(
4564 new MFBool::EditHandle(
4566 this->getType().getFieldDesc(EnabledFieldId
),
4570 editMField(EnabledFieldMask
, _mfEnabled
);
4575 GetFieldHandlePtr
MultiLightChunkBase::getHandleBeacon (void) const
4577 MFWeakNodePtr::GetHandlePtr
returnValue(
4578 new MFWeakNodePtr::GetHandle(
4580 this->getType().getFieldDesc(BeaconFieldId
),
4581 const_cast<MultiLightChunkBase
*>(this)));
4586 EditFieldHandlePtr
MultiLightChunkBase::editHandleBeacon (void)
4588 MFWeakNodePtr::EditHandlePtr
returnValue(
4589 new MFWeakNodePtr::EditHandle(
4591 this->getType().getFieldDesc(BeaconFieldId
),
4594 returnValue
->setAddMethod(
4595 boost::bind(&MultiLightChunk::pushToBeacon
,
4596 static_cast<MultiLightChunk
*>(this), _1
));
4597 returnValue
->setRemoveMethod(
4598 boost::bind(&MultiLightChunk::removeFromBeacon
,
4599 static_cast<MultiLightChunk
*>(this), _1
));
4600 returnValue
->setRemoveObjMethod(
4601 boost::bind(&MultiLightChunk::removeObjFromBeacon
,
4602 static_cast<MultiLightChunk
*>(this), _1
));
4603 returnValue
->setClearMethod(
4604 boost::bind(&MultiLightChunk::clearBeacon
,
4605 static_cast<MultiLightChunk
*>(this)));
4607 editMField(BeaconFieldMask
, _mfBeacon
);
4612 GetFieldHandlePtr
MultiLightChunkBase::getHandleBeaconMatrix (void) const
4614 MFMatrix::GetHandlePtr
returnValue(
4615 new MFMatrix::GetHandle(
4617 this->getType().getFieldDesc(BeaconMatrixFieldId
),
4618 const_cast<MultiLightChunkBase
*>(this)));
4623 EditFieldHandlePtr
MultiLightChunkBase::editHandleBeaconMatrix (void)
4625 MFMatrix::EditHandlePtr
returnValue(
4626 new MFMatrix::EditHandle(
4628 this->getType().getFieldDesc(BeaconMatrixFieldId
),
4632 editMField(BeaconMatrixFieldMask
, _mfBeaconMatrix
);
4637 GetFieldHandlePtr
MultiLightChunkBase::getHandleEyeSpace (void) const
4639 SFBool::GetHandlePtr
returnValue(
4640 new SFBool::GetHandle(
4642 this->getType().getFieldDesc(EyeSpaceFieldId
),
4643 const_cast<MultiLightChunkBase
*>(this)));
4648 EditFieldHandlePtr
MultiLightChunkBase::editHandleEyeSpace (void)
4650 SFBool::EditHandlePtr
returnValue(
4651 new SFBool::EditHandle(
4653 this->getType().getFieldDesc(EyeSpaceFieldId
),
4657 editSField(EyeSpaceFieldMask
);
4662 GetFieldHandlePtr
MultiLightChunkBase::getHandleLastCamNear (void) const
4664 SFReal32::GetHandlePtr
returnValue(
4665 new SFReal32::GetHandle(
4667 this->getType().getFieldDesc(LastCamNearFieldId
),
4668 const_cast<MultiLightChunkBase
*>(this)));
4673 EditFieldHandlePtr
MultiLightChunkBase::editHandleLastCamNear (void)
4675 SFReal32::EditHandlePtr
returnValue(
4676 new SFReal32::EditHandle(
4678 this->getType().getFieldDesc(LastCamNearFieldId
),
4682 editSField(LastCamNearFieldMask
);
4687 GetFieldHandlePtr
MultiLightChunkBase::getHandleLastCamFar (void) const
4689 SFReal32::GetHandlePtr
returnValue(
4690 new SFReal32::GetHandle(
4692 this->getType().getFieldDesc(LastCamFarFieldId
),
4693 const_cast<MultiLightChunkBase
*>(this)));
4698 EditFieldHandlePtr
MultiLightChunkBase::editHandleLastCamFar (void)
4700 SFReal32::EditHandlePtr
returnValue(
4701 new SFReal32::EditHandle(
4703 this->getType().getFieldDesc(LastCamFarFieldId
),
4707 editSField(LastCamFarFieldMask
);
4712 GetFieldHandlePtr
MultiLightChunkBase::getHandleLastCamToWorld (void) const
4714 SFMatrix::GetHandlePtr
returnValue(
4715 new SFMatrix::GetHandle(
4717 this->getType().getFieldDesc(LastCamToWorldFieldId
),
4718 const_cast<MultiLightChunkBase
*>(this)));
4723 EditFieldHandlePtr
MultiLightChunkBase::editHandleLastCamToWorld (void)
4725 SFMatrix::EditHandlePtr
returnValue(
4726 new SFMatrix::EditHandle(
4728 this->getType().getFieldDesc(LastCamToWorldFieldId
),
4732 editSField(LastCamToWorldFieldMask
);
4737 GetFieldHandlePtr
MultiLightChunkBase::getHandleLightBlockName (void) const
4739 SFString::GetHandlePtr
returnValue(
4740 new SFString::GetHandle(
4742 this->getType().getFieldDesc(LightBlockNameFieldId
),
4743 const_cast<MultiLightChunkBase
*>(this)));
4748 EditFieldHandlePtr
MultiLightChunkBase::editHandleLightBlockName (void)
4750 SFString::EditHandlePtr
returnValue(
4751 new SFString::EditHandle(
4753 this->getType().getFieldDesc(LightBlockNameFieldId
),
4757 editSField(LightBlockNameFieldMask
);
4762 GetFieldHandlePtr
MultiLightChunkBase::getHandleLightVariableName (void) const
4764 SFString::GetHandlePtr
returnValue(
4765 new SFString::GetHandle(
4766 &_sfLightVariableName
,
4767 this->getType().getFieldDesc(LightVariableNameFieldId
),
4768 const_cast<MultiLightChunkBase
*>(this)));
4773 EditFieldHandlePtr
MultiLightChunkBase::editHandleLightVariableName(void)
4775 SFString::EditHandlePtr
returnValue(
4776 new SFString::EditHandle(
4777 &_sfLightVariableName
,
4778 this->getType().getFieldDesc(LightVariableNameFieldId
),
4782 editSField(LightVariableNameFieldMask
);
4788 #ifdef OSG_MT_CPTR_ASPECT
4789 void MultiLightChunkBase::execSyncV( FieldContainer
&oFrom
,
4790 ConstFieldMaskArg whichField
,
4791 AspectOffsetStore
&oOffsets
,
4792 ConstFieldMaskArg syncMode
,
4793 const UInt32 uiSyncInfo
)
4795 MultiLightChunk
*pThis
= static_cast<MultiLightChunk
*>(this);
4797 pThis
->execSync(static_cast<MultiLightChunk
*>(&oFrom
),
4806 #ifdef OSG_MT_CPTR_ASPECT
4807 FieldContainer
*MultiLightChunkBase::createAspectCopy(
4808 const FieldContainer
*pRefAspect
) const
4810 MultiLightChunk
*returnValue
;
4812 newAspectCopy(returnValue
,
4813 dynamic_cast<const MultiLightChunk
*>(pRefAspect
),
4814 dynamic_cast<const MultiLightChunk
*>(this));
4820 void MultiLightChunkBase::resolveLinks(void)
4822 Inherited::resolveLinks();
4824 static_cast<MultiLightChunk
*>(this)->clearBeacon();
4826 #ifdef OSG_MT_CPTR_ASPECT
4827 AspectOffsetStore oOffsets
;
4829 _pAspectStore
->fillOffsetArray(oOffsets
, this);
4832 #ifdef OSG_MT_CPTR_ASPECT
4833 _mfPosition
.terminateShare(Thread::getCurrentAspect(),
4836 #ifdef OSG_MT_CPTR_ASPECT
4837 _mfDirection
.terminateShare(Thread::getCurrentAspect(),
4840 #ifdef OSG_MT_CPTR_ASPECT
4841 _mfColor
.terminateShare(Thread::getCurrentAspect(),
4844 #ifdef OSG_MT_CPTR_ASPECT
4845 _mfIntensity
.terminateShare(Thread::getCurrentAspect(),
4848 #ifdef OSG_MT_CPTR_ASPECT
4849 _mfAmbientIntensity
.terminateShare(Thread::getCurrentAspect(),
4852 #ifdef OSG_MT_CPTR_ASPECT
4853 _mfDiffuseIntensity
.terminateShare(Thread::getCurrentAspect(),
4856 #ifdef OSG_MT_CPTR_ASPECT
4857 _mfSpecularIntensity
.terminateShare(Thread::getCurrentAspect(),
4860 #ifdef OSG_MT_CPTR_ASPECT
4861 _mfAttenuation
.terminateShare(Thread::getCurrentAspect(),
4864 #ifdef OSG_MT_CPTR_ASPECT
4865 _mfSpotlightAngle
.terminateShare(Thread::getCurrentAspect(),
4868 #ifdef OSG_MT_CPTR_ASPECT
4869 _mfSpotExponent
.terminateShare(Thread::getCurrentAspect(),
4872 #ifdef OSG_MT_CPTR_ASPECT
4873 _mfInnerSuperEllipsesWidth
.terminateShare(Thread::getCurrentAspect(),
4876 #ifdef OSG_MT_CPTR_ASPECT
4877 _mfInnerSuperEllipsesHeight
.terminateShare(Thread::getCurrentAspect(),
4880 #ifdef OSG_MT_CPTR_ASPECT
4881 _mfOuterSuperEllipsesWidth
.terminateShare(Thread::getCurrentAspect(),
4884 #ifdef OSG_MT_CPTR_ASPECT
4885 _mfOuterSuperEllipsesHeight
.terminateShare(Thread::getCurrentAspect(),
4888 #ifdef OSG_MT_CPTR_ASPECT
4889 _mfSuperEllipsesRoundness
.terminateShare(Thread::getCurrentAspect(),
4892 #ifdef OSG_MT_CPTR_ASPECT
4893 _mfSuperEllipsesTwist
.terminateShare(Thread::getCurrentAspect(),
4896 #ifdef OSG_MT_CPTR_ASPECT
4897 _mfRangeCutOn
.terminateShare(Thread::getCurrentAspect(),
4900 #ifdef OSG_MT_CPTR_ASPECT
4901 _mfRangeCutOff
.terminateShare(Thread::getCurrentAspect(),
4904 #ifdef OSG_MT_CPTR_ASPECT
4905 _mfRangeNearZone
.terminateShare(Thread::getCurrentAspect(),
4908 #ifdef OSG_MT_CPTR_ASPECT
4909 _mfRangeFarZone
.terminateShare(Thread::getCurrentAspect(),
4912 #ifdef OSG_MT_CPTR_ASPECT
4913 _mfType
.terminateShare(Thread::getCurrentAspect(),
4916 #ifdef OSG_MT_CPTR_ASPECT
4917 _mfEnabled
.terminateShare(Thread::getCurrentAspect(),
4920 #ifdef OSG_MT_CPTR_ASPECT
4921 _mfBeaconMatrix
.terminateShare(Thread::getCurrentAspect(),