Open Inventor Release 2024.2.0
 
Loading...
Searching...
No Matches
SoVertexAttribFeedback.h
1/*=======================================================================
2 *** THE CONTENT OF THIS WORK IS PROPRIETARY TO FEI S.A.S, (FEI S.A.S.), ***
3 *** AND IS DISTRIBUTED UNDER A LICENSE AGREEMENT. ***
4 *** ***
5 *** REPRODUCTION, DISCLOSURE, OR USE, IN WHOLE OR IN PART, OTHER THAN AS ***
6 *** SPECIFIED IN THE LICENSE ARE NOT TO BE UNDERTAKEN EXCEPT WITH PRIOR ***
7 *** WRITTEN AUTHORIZATION OF FEI S.A.S. ***
8 *** ***
9 *** RESTRICTED RIGHTS LEGEND ***
10 *** USE, DUPLICATION, OR DISCLOSURE BY THE GOVERNMENT OF THE CONTENT OF THIS ***
11 *** WORK OR RELATED DOCUMENTATION IS SUBJECT TO RESTRICTIONS AS SET FORTH IN ***
12 *** SUBPARAGRAPH (C)(1) OF THE COMMERCIAL COMPUTER SOFTWARE RESTRICTED RIGHT ***
13 *** CLAUSE AT FAR 52.227-19 OR SUBPARAGRAPH (C)(1)(II) OF THE RIGHTS IN ***
14 *** TECHNICAL DATA AND COMPUTER SOFTWARE CLAUSE AT DFARS 52.227-7013. ***
15 *** ***
16 *** COPYRIGHT (C) 1996-2020 BY FEI S.A.S, ***
17 *** BORDEAUX, FRANCE ***
18 *** ALL RIGHTS RESERVED ***
19**=======================================================================*/
20/*=======================================================================
21** Author : Damien DALLA ROSA (Apr 2011)
22**=======================================================================*/
23
24#if !defined(SO_VERTEXATTRIBFEEDBACK_H)
25#define SO_VERTEXATTRIBFEEDBACK_H
26
27#include <Inventor/fields/SoSFBool.h>
28#include <Inventor/fields/SoSFEnum.h>
29#include <Inventor/nodes/SoSeparator.h>
30#include <Inventor/SbPImpl.h>
31
33
34SO_PIMPL_PUBLIC_DECLARATION(SoVertexAttribFeedback)
35
36
92{
93 SO_NODE_HEADER( SoVertexAttribFeedback );
94 SO_PIMPL_PUBLIC_HEADER(SoVertexAttribFeedback)
95
96 // ----------------------- Public usage --------------------------------------
97
98public:
99
105 {
110
112 SEPARATE
113 };
114
119 {
125 TRIANGLES
126 };
127
138
151
160
166
172
177
198 void registerFeedback(const SbString& varyingName, SoBufferObject* bufferObject, int primitiveSize = -1);
199
205 void unregisterFeedback(const SbString& varyingName);
206
215
224 static SbBool isSupported(SoState* state);
225
226private:
227
228 virtual void callback(SoCallbackAction *action);
229 virtual void getBoundingBox(SoGetBoundingBoxAction *action);
230 virtual void getMatrix(SoGetMatrixAction *action);
231 virtual void handleEvent(SoHandleEventAction *action);
232 virtual void rayPick(SoRayPickAction *action);
233 virtual void search(SoSearchAction *action);
234 virtual void getPrimitiveCount(SoGetPrimitiveCountAction *action);
235 virtual void distribute(SoDistributeAction* action);
236 virtual void GLRenderInPath(SoGLRenderAction *action);
237 virtual void GLRenderOffPath(SoGLRenderAction *action);
238 virtual void GLRenderBelowPath(SoGLRenderAction*);
239
240private:
241
243 static void initClass();
244
246 static void exitClass();
247
248private:
249
251 virtual ~SoVertexAttribFeedback();
252
253 private:
254
255 void commonConstructor();
256};
257
258#endif // SO_VERTEXATTRIBFEEDBACK_H
259
260
Class for smart character strings.
Definition SbString.h:202
<a href="IconLegend.html"><img src="extTGS.gif" alt="VSG extension" border="0"></a> Abstract base cl...
Performs a generic traversal of a scene graph or path.
<a href="IconLegend.html"><img src="extTGS.gif" alt="VSG extension" border="0"></a> Computes a distr...
<a href="IconLegend.html"><img src="extTGS.gif" alt="VSG extension" border="0"></a> OpenGL buffer ob...
Renders a scene graph using Open Inventor's Render Engine.
Computes bounding box of a scene.
Computes transformation matrix for a subgraph.
<a href="IconLegend.html"><img src="extTGS.gif" alt="VSG extension" border="0"></a> Counts number of...
Allows nodes in a graph to receive input events.
Intersects objects with a ray cast into scene.
Field containing a single Boolean value.
Definition SoSFBool.h:79
Field containing an enumerated value.
Definition SoSFEnum.h:89
Searches for nodes in a scene graph.
Group node that saves and restores traversal state.
Traversal state.
Definition SoState.h:74
<a href="IconLegend.html"><img src="extTGS.gif" alt="VSG extension" border="0"></a> Node to record v...
SoVertexAttribFeedback()
Default constructor.
SoSFBool autoResizeBuffers
Set this field to TRUE when the size of the recorded varyings is not known.
PrimitiveType
This enum is used to setup the expected recorded primitive type from the shaders.
@ POINTS
The shader is supposed to generate POINTS.
@ LINES
The shader is supposed to generate LINES.
SoSFBool queryGeneratedPrimitivesCount
Read back the number of recorded primitives.
int getGeneratedPrimitivesCount() const
This function returns the number of generated primitives during the traversal of the sub scene graph.
void registerFeedback(const SbString &varyingName, SoBufferObject *bufferObject, int primitiveSize=-1)
This function allows to attach a buffer object to a specific varying of the shader pushed on the stat...
static SbBool isSupported(SoState *state)
This function indicates if the vertex attributes feedback feature is available on this system.
SoSFEnum primitiveType
The type of primitive recorded during traversal.
BufferMode
This enum is used by the field buffersMode to describe the data packing format in the buffer objects.
@ INTERLEAVED
All varyings are recorded, interleaved, in a single buffer object.
SoSFBool disableFragmentProcessing
Turn off the fragment rasterizer.
void unregisterFeedback(const SbString &varyingName)
This function is used to unregister a varying registered with the registerFeedback function.
SoSFEnum buffersMode
The buffer mode used to record the primitives.
int SbBool
Boolean type.
Definition SbBase.h:87