1 /*---------------------------------------------------------------------------*\
5 * Copyright (C) 2003 by the OpenSG Forum *
9 * contact: dirk@opensg.org, gerrit.voss@vossg.org, jbehr@zgdv.de *
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 #ifndef _OSGCOMPUTEELEMENTHANDLERMIXIN_H_
40 #define _OSGCOMPUTEELEMENTHANDLERMIXIN_H_
45 #include "OSGTraversalDataHandlerMixin.h"
47 //#include "OSGMemoryObject.h"
48 #include "OSGHardwareContext.h"
52 /*! \ingroup GrpBaseFieldContainerMixins
53 \ingroup GrpLibOSGBase
55 template <class ParentT
>
56 class ComputeElementHandlerMixin
:
57 public TraversalDataHandlerMixin
<ParentT
>
59 /*========================== PRIVATE ================================*/
63 typedef TraversalDataHandlerMixin
<ParentT
> Inherited
;
65 /*========================== PUBLIC =================================*/
69 typedef ComputeElementHandlerMixin
<ParentT
> Self
;
71 typedef typename
ParentT::Desc Desc
;
72 typedef typename
Desc::TypeObject TypeObject
;
74 typedef typename
Desc::ContextDataSlotHandler ContextDataSlotHandler
;
77 typedef StageValidator::ValidationStatus ValidationStatus
;
81 /*---------------------------------------------------------------------*/
86 /*---------------------------------------------------------------------*/
87 /*! \name General Fieldcontainer Declaration */
91 /*---------------------------------------------------------------------*/
92 /*! \name Constructors */
96 /*---------------------------------------------------------------------*/
97 /*! \name Destructor */
100 bool requestRun(void);
103 /*---------------------------------------------------------------------*/
107 void changed(ConstFieldMaskArg whichField
,
112 /*---------------------------------------------------------------------*/
117 ValidationStatus
validateOnEnter(RenderActionBase
*pAction
);
118 ValidationStatus
validateOnLeave(RenderActionBase
*pAction
);
122 /*---------------------------------------------------------------------*/
127 /*---------------------------------------------------------------------*/
128 /*! \name your_category */
132 /*---------------------------------------------------------------------*/
133 /*! \name Container Access */
137 /*---------------------------------------------------------------------*/
138 /*! \name Binary Access */
142 /*---------------------------------------------------------------------*/
143 /*! \name your_operators */
147 using Inherited::setData
;
149 void setData(TraversalData
*pData
,
151 RenderActionBase
*pAction
);
154 void setData(HardwareContextData
*pData
,
156 HardwareContext
*pContext
);
159 /*---------------------------------------------------------------------*/
160 /*! \name Assignment */
164 /*---------------------------------------------------------------------*/
165 /*! \name Comparison */
169 /*---------------------------------------------------------------------*/
173 virtual void dump( UInt32 uiIndent
= 0,
174 const BitVector bvFlags
= 0) const;
177 /*========================= PROTECTED ===============================*/
182 StageValidator::ValidationStatus _tmpStatus
;
185 /*---------------------------------------------------------------------*/
186 /*! \name Type information */
190 ValidationStatus
validate(RenderActionBase
*pAction
);
194 /*---------------------------------------------------------------------*/
199 /*---------------------------------------------------------------------*/
203 ComputeElementHandlerMixin(void);
204 ComputeElementHandlerMixin(const ComputeElementHandlerMixin
&source
);
206 virtual ~ComputeElementHandlerMixin(void);
209 /*---------------------------------------------------------------------*/
214 /*---------------------------------------------------------------------*/
215 /*! \name MT Destruction */
219 /*---------------------------------------------------------------------*/
224 /*---------------------------------------------------------------------*/
229 /*---------------------------------------------------------------------*/
234 /*========================== PRIVATE ================================*/
238 /*!\brief prohibit default function (move to 'public' if needed) */
239 void operator =(const ComputeElementHandlerMixin
&source
);
244 #include "OSGComputeElementHandlerMixin.inl"
246 #endif /* _OSGCOMPUTEELEMENTHANDLERMIXIN_H_ */