Panda3D
 All Classes Functions Variables Enumerations
pointParticleFactory.cxx
00001 // Filename: pointParticleFactory.cxx
00002 // Created by:  charles (05Jul00)
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 #include "pointParticleFactory.h"
00016 #include "pointParticle.h"
00017 
00018 #include <stdlib.h>
00019 
00020 ////////////////////////////////////////////////////////////////////
00021 //    Function : PointParticleFactory
00022 //      Access : public
00023 // Description : default constructor
00024 ////////////////////////////////////////////////////////////////////
00025 PointParticleFactory::
00026 PointParticleFactory() :
00027   BaseParticleFactory() {
00028 }
00029 
00030 ////////////////////////////////////////////////////////////////////
00031 //    Function : PointParticleFactory
00032 //      Access : public
00033 // Description : copy constructor
00034 ////////////////////////////////////////////////////////////////////
00035 PointParticleFactory::
00036 PointParticleFactory(const PointParticleFactory &copy) :
00037   BaseParticleFactory(copy) {
00038 }
00039 
00040 ////////////////////////////////////////////////////////////////////
00041 //    Function : ~PointParticleFactory
00042 //      Access : public
00043 // Description : destructor
00044 ////////////////////////////////////////////////////////////////////
00045 PointParticleFactory::
00046 ~PointParticleFactory() {
00047 }
00048 
00049 ////////////////////////////////////////////////////////////////////
00050 //    Function : populate_child_particle
00051 //      Access : public
00052 // Description : child particle generation function
00053 ////////////////////////////////////////////////////////////////////
00054 void PointParticleFactory::
00055 populate_child_particle(BaseParticle *bp) const {
00056   bp->set_oriented(false);
00057 }
00058 
00059 ////////////////////////////////////////////////////////////////////
00060 //    Function : alloc_particle
00061 //      Access : public
00062 // Description : child particle generation function
00063 ////////////////////////////////////////////////////////////////////
00064 BaseParticle *PointParticleFactory::
00065 alloc_particle() const {
00066   return new PointParticle;
00067 }
00068 
00069 ////////////////////////////////////////////////////////////////////
00070 //     Function : output
00071 //       Access : Public
00072 //  Description : Write a string representation of this instance to
00073 //                <out>.
00074 ////////////////////////////////////////////////////////////////////
00075 void PointParticleFactory::
00076 output(ostream &out) const {
00077   #ifndef NDEBUG //[
00078   out<<"PointParticleFactory";
00079   #endif //] NDEBUG
00080 }
00081 
00082 ////////////////////////////////////////////////////////////////////
00083 //     Function : write
00084 //       Access : Public
00085 //  Description : Write a string representation of this instance to
00086 //                <out>.
00087 ////////////////////////////////////////////////////////////////////
00088 void PointParticleFactory::
00089 write(ostream &out, int indent) const {
00090   #ifndef NDEBUG //[
00091   out.width(indent); out<<""; out<<"PointParticleFactory:\n";
00092   BaseParticleFactory::write(out, indent+2);
00093   #endif //] NDEBUG
00094 }
 All Classes Functions Variables Enumerations