-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathParticle.h
More file actions
62 lines (44 loc) · 1.43 KB
/
Particle.h
File metadata and controls
62 lines (44 loc) · 1.43 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
/********************************************************
Particle.h
Header File for Particle Class
Gina Guerrero - Fall 2013
********************************************************/
#ifndef _PARTICLE_H_
#define _PARTICLE_H_
#include "Attributes.h"
#ifdef __APPLE__
# include <GLUT/glut.h>
#else
# include <GL/glut.h>
#endif
class Particle {
private:
int InUse; // particle off/on
double Birth; // store NTimeSteps of when the particle is "born" (for age)
Vector3d *history; // particle's history of centers
int nhistory; // history indx
int maxhistory; // max history
int Blend; // draw in blend mode toggle
public:
Attributes A; // attributes class
Particle(); // defaults...
~Particle();
Particle(const Particle& other);
Particle& operator= (const Particle& other);
void SetMaxHistory(int blendsize);
void Reset(); // gets called by the constructor. kind of cleans up..
void Draw(); // draws the particle
void AddHistory(Vector3d c); // adds history
//////////// SETTERS //////////////
void SetBirth(double timestep);
void SetInUse(int type);
void SetBlend(int blend);
//////////// GETTERS ///////////////
double GetBirth();
double GetAge(double currentTimestep);
int IsInUse();
int Getnhistory();
////////// DEBUGGING //////////////
void PrintInfo();
};
#endif