Panda3D

rectangleEmitter.h

00001 // Filename: rectangleEmitter.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 RECTANGLEEMITTER_H
00016 #define RECTANGLEEMITTER_H
00017 
00018 #include "baseParticleEmitter.h"
00019 
00020 ////////////////////////////////////////////////////////////////////
00021 //       Class : RectangleEmitter
00022 // Description : Describes a planar square region in which
00023 //               particles are generated.
00024 ////////////////////////////////////////////////////////////////////
00025 class EXPCL_PANDAPHYSICS RectangleEmitter : public BaseParticleEmitter {
00026 PUBLISHED:
00027   RectangleEmitter();
00028   RectangleEmitter(const RectangleEmitter &copy);
00029   virtual ~RectangleEmitter();
00030 
00031   virtual BaseParticleEmitter *make_copy();
00032 
00033   INLINE void set_min_bound(const LPoint2& vmin);
00034   INLINE void set_max_bound(const LPoint2& vmax);
00035 
00036   INLINE LPoint2 get_min_bound() const;
00037   INLINE LPoint2 get_max_bound() const;
00038 
00039   virtual void output(ostream &out) const;
00040   virtual void write(ostream &out, int indent=0) const;
00041 
00042 private:
00043   LPoint2 _vmin;
00044   LPoint2 _vmax;
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 "rectangleEmitter.I"
00054 
00055 #endif // RECTANGLEEMITTER_H
 All Classes Functions Variables Enumerations