23#ifndef _SO_SHADOW_GROUP_
24#define _SO_SHADOW_GROUP_
27#include <Inventor/nodes/SoGroup.h>
28#include <Inventor/fields/SoSFBool.h>
29#include <Inventor/fields/SoSFEnum.h>
30#include <Inventor/fields/SoSFFloat.h>
31#include <Inventor/fields/SoSFInt32.h>
32#include <Inventor/SbMatrix.h>
33#include <Inventor/SbPImpl.h>
35class SoGLShadowMapping ;
228 #ifndef HIDDEN_FROM_DOC
362 typedef std::vector<int> StackIndexVector;
364 static void initClass() ;
365 static void exitClass() ;
367 const std::vector<SbMatrix>& getLightViewMatrices()
const;
369 const std::vector<SbMatrix>& getLightViewProjectionMatrices()
const;
371 const std::vector<SbVec2f>& getLightsNearFar()
const;
373 const std::vector<SbVec2i32>& getLightMatricesOffsetsAndNums()
const;
375 const std::vector<float>& getLightShadowIntensities()
const;
377 int getLightMatrixIndex()
const;
383 void invalidateLightCaches();
387 bool isCacheValid(
SoState* state, SoCache* &cache,
const StackIndexVector& elemsToCheck);
391 bool isShadowActive(
SoState* state)
const;
394 float getQuality(
SoState* state)
const;
399 virtual void notify(SoNotList *list);
410 void destroy()
override;
424 void addElementsToCache(
SoState* state, SoCache* cache)
const;
427 void chooseShadowingMethod();
430 inventor::impl::SoShadowGroupImpl* createImplementation()
const;
435 static int s_defaultTextureUnit;
Renders a scene graph using Open Inventor's Render Engine.
SoGroup()
Creates an empty group node.
Field containing a single Boolean value.
Field containing an enumerated value.
Field containing a floating-point value.
Field containing a int32_t integer.
<a href="IconLegend.html"><img src="extTGS.gif" alt="VSG extension" border="0"></a> Shadow casting g...
SoSFFloat visibilityRadius
Shadows are only computed within "visibility radius" distance from the camera position.
SoSFFloat precision
Specifies the precision of the shadow.
SoSFEnum visibilityFlag
Specifies how visibilityRadius is interpreted.
SoShadowGroup()
Default constructor.
SoSFFloat quality
Specifies the quality of the shadow.
SoShadowGroup(int nChildren)
Constructor that takes approximate number of children.
SoSFFloat lightBleedingReduction
In some cases, a halo may appear around shadows intersecting each other.
SoSFInt32 smoothFactor
Set the smoothness of shadows.
SoSFBool isActive
Activates/deactivates the shadowing.
SoSFEnum method
Specifies the shadowing technique to use.
static SbBool isSupported(SoShadowGroup::ShadowingMethod method=SoShadowGroup::VARIANCE_SHADOW_MAP)
Indicates if shadow casting is supported by your graphic board.
SoSFBool shadowCachingEnabled
Indicates if a cache should be used for computing the shadows.
VisibilityFlag
visibilityRadius interpretation
@ ABSOLUTE_RADIUS
visibilityRadius is interpreted as an absolute value.
@ LONGEST_BBOX_EDGE_FACTOR
The longest edge of the scene bounding box will be multiplied by the value of visibilityRadius.
SoSFFloat intensity
Specifies the intensity of the shadow.
ShadowingMethod
Shadowing techniques.
@ VARIANCE_SHADOW_MAP
Shadows with soft edges.
SoSFFloat minVariance
Increasing this value will decrease possible self-shadowing artifacts but will make shadows fade away...