00001 #ifndef EMITTER_H 00002 #define EMITTER_H 00003 00004 #include <ngl/Vec3.h> 00005 00006 //---------------------------------------------------------------------------------------------------------------------- 00016 00017 class Emitter 00018 { 00019 public: 00020 //---------------------------------------------------------------------------------------------------------------------- 00026 //---------------------------------------------------------------------------------------------------------------------- 00027 Emitter( 00028 const ngl::Vec3 _location = ngl::Vec3(0,0,0), 00029 const float _size = 1.0, 00030 const float _emitDensityRate = 4.0, 00031 const float _emitTemperatureRate = 4.0 00032 ); 00033 //---------------------------------------------------------------------------------------------------------------------- 00035 //---------------------------------------------------------------------------------------------------------------------- 00036 ~Emitter(); 00037 //---------------------------------------------------------------------------------------------------------------------- 00040 //---------------------------------------------------------------------------------------------------------------------- 00041 inline float getEmitDensityRate() const { return m_emitDensityRate; } 00042 //---------------------------------------------------------------------------------------------------------------------- 00045 //---------------------------------------------------------------------------------------------------------------------- 00046 inline float getEmitTemperatureRate() const { return m_emitTemperatureRate; } 00047 //---------------------------------------------------------------------------------------------------------------------- 00050 //---------------------------------------------------------------------------------------------------------------------- 00051 inline ngl::Vec3 getLocation() const { return m_location; } 00052 //---------------------------------------------------------------------------------------------------------------------- 00055 //---------------------------------------------------------------------------------------------------------------------- 00056 inline float getSize() const { return m_size; } 00057 //--------------------------------------------------------------------------------------------------------------------- 00060 //---------------------------------------------------------------------------------------------------------------------- 00061 inline void setEmitDensityRate( 00062 double _val 00063 ) { m_emitDensityRate = _val; } 00064 //--------------------------------------------------------------------------------------------------------------------- 00067 //---------------------------------------------------------------------------------------------------------------------- 00068 inline void setEmitTemperatureRate( 00069 double _val 00070 ) { m_emitTemperatureRate = _val; } 00071 //---------------------------------------------------------------------------------------------------------------------- 00074 //---------------------------------------------------------------------------------------------------------------------- 00075 inline void setLocation( 00076 const ngl::Vec3 _loc 00077 ) { m_location = _loc; } 00078 //--------------------------------------------------------------------------------------------------------------------- 00081 //---------------------------------------------------------------------------------------------------------------------- 00082 inline void setSize( 00083 double _val 00084 ) { m_size = _val; } 00085 00086 private: 00087 //---------------------------------------------------------------------------------------------------------------------- 00089 //---------------------------------------------------------------------------------------------------------------------- 00090 float m_emitDensityRate; 00091 //---------------------------------------------------------------------------------------------------------------------- 00093 //---------------------------------------------------------------------------------------------------------------------- 00094 float m_emitTemperatureRate; 00095 //---------------------------------------------------------------------------------------------------------------------- 00097 //---------------------------------------------------------------------------------------------------------------------- 00098 ngl::Vec3 m_location; 00099 //---------------------------------------------------------------------------------------------------------------------- 00101 //---------------------------------------------------------------------------------------------------------------------- 00102 float m_size; 00103 }; 00104 00105 00106 #endif // EMITTER_H