Changeset 2860 for trunk/packages/vizservers/nanovis
- Timestamp:
- Mar 16, 2012 12:15:59 AM (12 years ago)
- Location:
- trunk/packages/vizservers/nanovis
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/packages/vizservers/nanovis/ParticleEmitter.h
r2818 r2860 10 10 { 11 11 public: 12 ParticleEmitter(); 13 14 void setName(const std::string& name); 15 void setPosition(float x, float y, float z); 16 void setMinMaxLifeTime(float minLifeTime, float maxLifeTime); 17 void setMaxPositionOffset(float offsetX, float offsetY, float offsetZ); 18 void setMinMaxNumOfNewParticles(int minNum, int maxNum); 19 20 void setVectorField(); 21 void setEnabled(bool enabled); 22 bool isEnabled() const; 23 12 24 std::string _name; 13 25 vrVector3f _position; … … 25 37 26 38 bool _enabled; 27 28 ParticleEmitter();29 30 void setName(const std::string& name);31 void setPosition(float x, float y, float z);32 void setMinMaxLifeTime(float minLifeTime, float maxLifeTime);33 void setMaxPositionOffset(float offsetX, float offsetY, float offsetZ);34 void setMinMaxNumOfNewParticles(int minNum, int maxNum);35 36 void setVectorField();37 void setEnabled(bool enabled);38 bool isEnabled() const;39 39 }; 40 40 -
trunk/packages/vizservers/nanovis/ParticleSystem.h
r2857 r2860 76 76 }; 77 77 78 ParticleSystem(int width, int height, const std::string& fileName, 79 int fieldWidth, int fieldHeight, int fieldDepth, 80 bool timeVaryingData, int flowFileStartIndex, int flowFileEndIndex); 81 ~ParticleSystem(); 82 void createRenderTargets(); 83 void createSortRenderTargets(); 84 void createStreamlineRenderTargets(); 85 void advectStreamlines(); 86 void renderStreamlines(); 87 88 bool advect(float deltaT, float camx, float camy, float camz); 89 void enable(EnableEnum enabled); 90 void disable(EnableEnum enabled); 91 bool isEnabled(EnableEnum enabled); 92 93 //////////////////////////////////////////// 94 void addEmitter(ParticleEmitter *emitter); 95 ParticleEmitter *getEmitter(int index); 96 unsigned int getNumEmitters() const; 97 void removeEmitter(int index); 98 void removeAllEmitters(); 99 100 int getMaxSize() const; 101 102 void render(); 103 104 void reset(); 105 106 void setDefaultPointSize(float size); 107 108 unsigned int getNumOfActiveParticles() const; 109 110 void setScreenSize(int sreenWidth, int screenHeight); 111 112 void setFOV(float fov); 113 114 void setUserDefinedNumOfParticles(int numParticles); 115 116 float getScaleX() const; 117 float getScaleY() const; 118 float getScaleZ() const; 119 unsigned int getVectorFieldGraphicsID() const; 120 121 bool isTimeVaryingField() const; 122 void setTimeVaryingField(bool timeVarying); 123 124 void setDepthCueEnabled(bool enabled); 125 bool getDepthCueEnabled() const; 126 127 static void *dataLoadMain(void *data); 128 // TEMP 129 static void callbackForCgError(); 130 78 131 const int _width; 79 132 const int _height; … … 133 186 unsigned int velocity_tex[2]; 134 187 135 // TEMP136 188 /////////////////////////////////////////////////// 137 189 // TIME SERIES … … 170 222 bool _streamlineEnabled; 171 223 bool _depthCueEnabled; 172 173 // TEMP174 static void callbackForCgError();175 static CGcontext _context;176 224 177 225 CGprogram _distanceInitFP; … … 258 306 std::vector<vrVector3f> *_criticalPoints; 259 307 260 static void *dataLoadMain(void *data); 261 262 ParticleSystem(int width, int height, const std::string& fileName, 263 int fieldWidth, int fieldHeight, int fieldDepth, 264 bool timeVaryingData, int flowFileStartIndex, int flowFileEndIndex); 265 ~ParticleSystem(); 266 void createRenderTargets(); 267 void createSortRenderTargets(); 268 void createStreamlineRenderTargets(); 269 void advectStreamlines(); 270 void renderStreamlines(); 271 272 bool advect(float deltaT, float camx, float camy, float camz); 273 void enable(EnableEnum enabled); 274 void disable(EnableEnum enabled); 275 bool isEnabled(EnableEnum enabled); 276 277 //////////////////////////////////////////// 278 void addEmitter(ParticleEmitter *emitter); 279 ParticleEmitter *getEmitter(int index); 280 unsigned int getNumEmitters() const; 281 void removeEmitter(int index); 282 void removeAllEmitters(); 283 284 int getMaxSize() const; 285 286 void render(); 287 288 void reset(); 289 290 void setDefaultPointSize(float size); 291 292 unsigned int getNumOfActiveParticles() const; 293 294 void setScreenSize(int sreenWidth, int screenHeight); 295 296 void setFOV(float fov); 297 298 void setUserDefinedNumOfParticles(int numParticles); 299 300 float getScaleX()const; 301 float getScaleY()const; 302 float getScaleZ()const; 303 unsigned int getVectorFieldGraphicsID() const; 304 305 bool isTimeVaryingField() const; 306 void setTimeVaryingField(bool timeVarying); 307 308 void setDepthCueEnabled(bool enabled); 309 bool getDepthCueEnabled() const; 308 // TEMP 309 static CGcontext _context; 310 310 311 311 protected: -
trunk/packages/vizservers/nanovis/ParticleSystemFactory.h
r2818 r2860 11 11 class ParticleSystemFactory 12 12 { 13 ParticleSystem *_newParticleSystem;14 13 public: 15 14 ParticleSystemFactory(); … … 25 24 static void startElement(void *userData, const char *elementName, const char **attrs); 26 25 static void text(void *data, const XML_Char *txt, int len); 26 27 ParticleSystem *_newParticleSystem; 27 28 }; 28 29
Note: See TracChangeset
for help on using the changeset viewer.