Line | |
---|
1 | /*! |
---|
2 | * @file sprite_particles.h |
---|
3 | |
---|
4 | */ |
---|
5 | |
---|
6 | #ifndef _SPRITE_PARTICLE_SYSTEM_H |
---|
7 | #define _SPRITE_PARTICLE_SYSTEM_H |
---|
8 | |
---|
9 | #include "particle_system.h" |
---|
10 | #include "material.h" |
---|
11 | |
---|
12 | //! A class to handle ParticleSystems |
---|
13 | class SpriteParticles : public ParticleSystem |
---|
14 | { |
---|
15 | |
---|
16 | public: |
---|
17 | SpriteParticles(unsigned int maxCount = PARTICLE_DEFAULT_MAX_COUNT); |
---|
18 | SpriteParticles(const TiXmlElement* root); |
---|
19 | virtual ~SpriteParticles(); |
---|
20 | |
---|
21 | virtual void loadParams(const TiXmlElement* root); |
---|
22 | |
---|
23 | void setMaterialTexture(const std::string& textureFile); |
---|
24 | |
---|
25 | /** @returns the Material that lies on this particles */ |
---|
26 | inline const Material* getMaterial() const { return &this->material; }; |
---|
27 | |
---|
28 | virtual void draw() const; |
---|
29 | |
---|
30 | private: |
---|
31 | void init(); |
---|
32 | |
---|
33 | private: |
---|
34 | Material material; //!< A Material for all the Particles. |
---|
35 | }; |
---|
36 | |
---|
37 | #endif /* _SPRITE_PARTICLE_SYSTEM_H */ |
---|
Note: See
TracBrowser
for help on using the repository browser.