Open Inventor Release 2023.2.3
 
Loading...
Searching...
No Matches
SoAlgebraicShape.h
Go to the documentation of this file.
1#ifndef SO_ALGEBRAIC_SHAPE_H
2#define SO_ALGEBRAIC_SHAPE_H
3
8#include <Inventor/SbBox.h>
9#include <Inventor/SbVec.h>
10
11
12class SoBufferedShape;
13
15
16
147{
149 SO_PIMPL_PUBLIC_HEADER(SoAlgebraicShape)
150
151public:
152
173
181 MAX_WORK_SPACE
182 };
183
198
207
241
254
263
269
270private:
271
276
280 virtual ~SoAlgebraicShape ();
281
287 virtual void computeBBox ( SbBox3f &box, SbVec3f &center ) = 0;
288
295 bool solveQuadric ( const SbVec3f& abc, SbVec2f& roots ) const;
296
302 static SoFragmentShader* fragmentShaderFromFile ( const SbString& filename );
303
308 virtual void generatePrimitives(SoAction *action);
309
311
314 void setCustomTransformationShaderObject( SoVertexShader* vso );
315 void setCustomRayParametersShaderObject ( SoVertexShader* vso );
316 void setCustomGeometryBufferedShape ( SoBufferedShape* shape );
318
319private:
320
322
325 virtual void GLRender ( SoGLRenderAction *action );
326 virtual void computeBBox ( SoAction *action, SbBox3f &box, SbVec3f &center );
328
329private:
330
332
335 static void initClass ();
336 static void exitClass ();
338
342 virtual void notify ( SoNotList *list );
343
344private:
345
346 // Internal for common constructor initialization
347 void initialize ();
348
349 // Internal for updating shader parameter when BBox is not valid
350 void updateBBox ();
351
352};
353
354#endif // SO_QUADRIC_SHAPE_H
SO_PIMPL_PUBLIC_DECLARATION(SoFileDataAdapter)
#define SO_NODE_HEADER(className)
Definition SoSubNode.h:151
3D box class.
Definition SbBox.h:649
Class for smart character strings.
Definition SbString.h:202
2D vector class.
Definition SbVec.h:76
3D vector class.
Definition SbVec.h:932
Abstract base class for all actions.
Definition SoAction.h:132
<a href="IconLegend.html"><img src="extTGS.gif" alt="VSG extension" border="0"></a> Abstract base cl...
SoMFNode shaderSlots
Multi-field for Shader slots of type SoShaderObject.
SoSFEnum clippingPolicy
Specifies how the algebraic shape should be clipped by a clipping plane.
ASWorkSpace
Specifies which reference frame to use inside the ray intersection shader function.
@ WORLD
The camera space (or view space)
@ CAMERA
The normalized bounding box space.
ASShaderSlot
Specifies the available slots for shader programs.
SoSFNode rayIntersection
Field for an SoFragmentShader object that defines the GLSL ray intersection function.
SoSFEnum workspace
Field to define the workspace.
ASClippingPolicy
Specifies how the algebraic shape should be clipped by a clipping plane.
@ FULL_SHAPE
Standard behaviour.
SoSFBool generateTransparency
Specify if the shape generates transparent fragment.
<a href="IconLegend.html"><img src="extTGS.gif" alt="VSG extension" border="0"></a> Node to render g...
<a href="IconLegend.html"><img src="extTGS.gif" alt="VSG extension" border="0"></a> Node that define...
Renders a scene graph using Open Inventor's Render Engine.
Multiple-value field containing any number of nodes.
Definition SoMFNode.h:94
Field containing a single Boolean value.
Definition SoSFBool.h:79
Field containing an enumerated value.
Definition SoSFEnum.h:89
Field containing a a node.
Definition SoSFNode.h:97
Abstract base class for all shape nodes.
Definition SoShape.h:115
<a href="IconLegend.html"><img src="extTGS.gif" alt="VSG extension" border="0"></a> Node that define...
void notify(SoNotList *list)