changed: gcc8 base update
[opensg.git] / Source / System / NodeCores / Groups / Light / Shadow / Base / OSGShadowMapEngine.h
blobc307eacc9f3aaa6f11db17b21ea09ac20170f05f
1 /*---------------------------------------------------------------------------*\
2 * OpenSG *
3 * *
4 * *
5 * Copyright (C) 2000-2002 by the OpenSG Forum *
6 * *
7 * www.opensg.org *
8 * *
9 * contact: dirk@opensg.org, gerrit.voss@vossg.org, jbehr@zgdv.de *
10 * *
11 \*---------------------------------------------------------------------------*/
12 /*---------------------------------------------------------------------------*\
13 * License *
14 * *
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. *
18 * *
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. *
23 * *
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. *
27 * *
28 \*---------------------------------------------------------------------------*/
29 /*---------------------------------------------------------------------------*\
30 * Changes *
31 * *
32 * *
33 * *
34 * *
35 * *
36 * *
37 \*---------------------------------------------------------------------------*/
39 #ifndef _OSGSHADOWMAPENGINE_H_
40 #define _OSGSHADOWMAPENGINE_H_
41 #ifdef __sgi
42 #pragma once
43 #endif
45 #include "OSGShadowMapEngineBase.h"
46 #include "OSGChunkMaterialFields.h"
48 OSG_BEGIN_NAMESPACE
50 class RenderAction;
52 /*! \brief ShadowMapEngine is the basic NodeCore for inner nodes in the tree.
53 \ingroup GrpGroupLightShadowBaseObj
54 \ingroup GrpLibOSGGroup
55 \includebasedoc
58 class OSG_GROUP_DLLMAPPING ShadowMapEngine : public ShadowMapEngineBase
60 /*========================== PUBLIC =================================*/
62 public:
64 /*---------------------------------------------------------------------*/
65 /*! \name Sync */
66 /*! \{ */
68 virtual void changed(ConstFieldMaskArg whichField,
69 UInt32 origin,
70 BitVector detail);
72 /*! \} */
73 /*---------------------------------------------------------------------*/
74 /*! \name Render */
75 /*! \{ */
77 virtual Action::ResultE runOnEnter(Light *pLight,
78 LightTypeE eType,
79 RenderAction *pAction) = 0;
80 virtual Action::ResultE runOnLeave(Light *pLight,
81 LightTypeE eType,
82 RenderAction *pAction) = 0;
84 /*! \} */
85 /*---------------------------------------------------------------------*/
86 /*! \name Dump */
87 /*! \{ */
89 virtual void dump( UInt32 uiIndent = 0,
90 const BitVector bvFlags = 0) const;
92 /*! \} */
93 /*========================= PROTECTED ===============================*/
95 protected:
97 typedef ShadowMapEngineBase Inherited;
99 static ChunkMaterialUnrecPtr _pLightPassMat;
101 /*---------------------------------------------------------------------*/
102 /*! \name Constructors */
103 /*! \{ */
105 ShadowMapEngine(void);
106 ShadowMapEngine(const ShadowMapEngine &source);
108 /*! \} */
109 /*---------------------------------------------------------------------*/
110 /*! \name Destructors */
111 /*! \{ */
113 virtual ~ShadowMapEngine(void);
115 /*! \} */
116 /*---------------------------------------------------------------------*/
117 /*! \name Init */
118 /*! \{ */
120 static void initMethod(InitPhase ePhase);
121 static void exitMethod(InitPhase ePhase);
123 /*! \} */
124 /*---------------------------------------------------------------------*/
125 /*! \name Action Callbacks */
126 /*! \{ */
128 static BitVector bvLightPassMask;
129 static BitVector bvAmbientPassMask;
130 static BitVector bvDiffusePassMask;
132 /*! \} */
133 /*---------------------------------------------------------------------*/
134 /*! \name Draw */
135 /*! \{ */
137 /*! \} */
138 /*========================== PRIVATE ================================*/
140 private:
142 friend class FieldContainer;
143 friend class ShadowMapEngineBase;
145 /*---------------------------------------------------------------------*/
147 /*!\brief prohibit default function (move to 'public' if needed) */
148 void operator =(const ShadowMapEngine &source);
151 typedef ShadowMapEngine *ShadowMapEngineP;
153 OSG_END_NAMESPACE
155 #include "OSGShadowMapEngineBase.inl"
156 #include "OSGShadowMapEngine.inl"
158 #endif /* _OSGSHADOWMAPENGINE_H_ */