Panda3D
|
00001 // Filename: lineEmitter.h 00002 // Created by: charles (22Jun00) 00003 // 00004 //////////////////////////////////////////////////////////////////// 00005 // 00006 // PANDA 3D SOFTWARE 00007 // Copyright (c) Carnegie Mellon University. All rights reserved. 00008 // 00009 // All use of this software is subject to the terms of the revised BSD 00010 // license. You should have received a copy of this license along 00011 // with this source code in a file named "LICENSE." 00012 // 00013 //////////////////////////////////////////////////////////////////// 00014 00015 #ifndef LINEEMITTER_H 00016 #define LINEEMITTER_H 00017 00018 #include "baseParticleEmitter.h" 00019 00020 //////////////////////////////////////////////////////////////////// 00021 // Class : LineEmitter 00022 // Description : Describes a linear region in which 00023 // particles are generated. 00024 //////////////////////////////////////////////////////////////////// 00025 class EXPCL_PANDAPHYSICS LineEmitter : public BaseParticleEmitter { 00026 PUBLISHED: 00027 LineEmitter(); 00028 LineEmitter(const LineEmitter ©); 00029 virtual ~LineEmitter(); 00030 00031 virtual BaseParticleEmitter *make_copy(); 00032 00033 INLINE void set_endpoint1(const LPoint3& point); 00034 INLINE void set_endpoint2(const LPoint3& point); 00035 00036 INLINE LPoint3 get_endpoint1() const; 00037 INLINE LPoint3 get_endpoint2() const; 00038 00039 virtual void output(ostream &out) const; 00040 virtual void write(ostream &out, int indent=0) const; 00041 00042 private: 00043 LPoint3 _endpoint1; 00044 LPoint3 _endpoint2; 00045 00046 // CUSTOM EMISSION PARAMETERS 00047 // none 00048 00049 virtual void assign_initial_position(LPoint3& pos); 00050 virtual void assign_initial_velocity(LVector3& vel); 00051 }; 00052 00053 #include "lineEmitter.I" 00054 00055 #endif // LINEEMITTER_H