Open Inventor Release 2024.1.1
 
Loading...
Searching...
No Matches
PoStreamParticleMotion.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-2014 BY FEI S.A.S, ***
17 *** BORDEAUX, FRANCE ***
18 *** ALL RIGHTS RESERVED ***
19**=======================================================================*/
20/*=======================================================================
21** Author : VSG (MMM YYYY)
22**=======================================================================*/
23
24#ifndef _PO_STREAMPARTICLEMOTION_
25#define _PO_STREAMPARTICLEMOTION_
26
27#include <MeshViz/3Ddata/PoBaseStreamLine.h>
28#include <Inventor/fields/SoSFBool.h>
29
30
31class SoLineSet;
32
101
102 SO_KIT_HEADER(PoStreamParticleMotion) ;
103
104
105 public:
106
107 /* Fields */
108
114
120
126
133
139
145
151
152 /*----------------------------------------------------------------------------*/
153 private:
154 static void initClass() ;
155 static void exitClass() ;
156
157 private:
159 // Constructor.
160
161 virtual ~PoStreamParticleMotion() ;
162 // Destructor
163
164 virtual void setDefaultOnNonWritingFields();
165 virtual SbBool setUpConnections(SbBool onOff, SbBool doItAlways = FALSE) ;
166
167 void saveSpeed(PiStreamPath &stream_path, SbVec3f &speed);
168 void saveTime(PiStreamPath &stream_path, float time);
169
170 void rebuildFrames( const SbString& part_name );
171 SbBool modifyBlinkerParams( const SbString& part_name );
172
173 SbBool fieldsHaveChanged();
174
175 PiStreamPath *m_streamPath;
176 int m_allocStreamPath;
177
178 private:
179 FieldSensorList m_fieldSensorList ;
180 // Sensors
181
182 SoFieldList m_fieldList ;
183 // List of fields defined in this class
184
185 virtual void newAnimator(SoGroup *group, SoLineSet *line_set,
186 SoCoordinate3 *particle_coord, SoCoordinate3 *particle_speed,
187 SoMFColor *particle_color);
188 virtual void endAnimator(SoGroup *group, SoLineSet *line_set,
189 SoCoordinate3 *particle_coord, SoCoordinate3 *particle_speed,
190 SoMFColor *particle_color);
191 virtual void newFrame(SoGroup *frame, int frame_ind);
192 virtual void endFrame(SoGroup *frame, int frame_ind);
193 virtual void newLine(SoGroup *line, int line_ind);
194 virtual void endLine(SoGroup *line, int line_ind);
195 virtual void newParticle(const SbVec3f &pos, const SbVec3f &speed, const SbVec3f &norm, const SbColor *color, int ind);
196 // method to build the frames to be animated
197} ;
198
199/*----------------------------------------------------------------------------*/
200
201#endif /* _PO_STREAMPARTICLEMOTION_ */
202
203
<a href="IconLegend.html"><img src="extMV.gif" alt="MeshViz" border="0"></a> Base class of all stream...
<a href="IconLegend.html"><img src="extMV.gif" alt="MeshViz" border="0"></a> Animation of particles a...
SoSFInt32 pulseFrequency
Number of frames to be visualized during an animation cycle.
SoSFInt32 viewFrame
Visualized frame index (used only if isBlinking is FALSE).
SoSFFloat shiftStart
Duration from which the first position on the streamline is calculated.
SoSFFloat blinkSpeed
Number of animation's cycles per second.
SoSFBool isBlinking
Stop the animation if isBlinking is FALSE.
SoSFFloat timeStep
Time step between 2 consecutive points of a streamline.
SoSFBool isStartRandomized
Set it to TRUE prevents each first position of the different streamlines to start simultaneously.
Color vector class.
Definition SbColor.h:82
Class for smart character strings.
Definition SbString.h:202
3D vector class.
Definition SbVec.h:932
Coordinate point node.
Maintains a list of pointers to fields.
Definition SoFieldList.h:72
Base class for all group nodes.
Definition SoGroup.h:122
Polyline shape node.
Definition SoLineSet.h:190
Multiple-value field containing any number of RGB colors stored as three floats.
Definition SoMFColor.h:98
Field containing a single Boolean value.
Definition SoSFBool.h:79
Field containing a floating-point value.
Definition SoSFFloat.h:78
Field containing a int32_t integer.
Definition SoSFInt32.h:80
int SbBool
Boolean type.
Definition SbBase.h:87