72 lines
2.3 KiB
C++
72 lines
2.3 KiB
C++
// Filename: pointParticleFactory.cxx
|
|
// Created by: charles (05Jul00)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) 2001, Disney Enterprises, Inc. All rights reserved
|
|
//
|
|
// All use of this software is subject to the terms of the Panda 3d
|
|
// Software license. You should have received a copy of this license
|
|
// along with this source code; you will also find a current copy of
|
|
// the license at http://www.panda3d.org/license.txt .
|
|
//
|
|
// To contact the maintainers of this program write to
|
|
// panda3d@yahoogroups.com .
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
#include "pointParticleFactory.h"
|
|
#include "pointParticle.h"
|
|
|
|
#include <stdlib.h>
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function : PointParticleFactory
|
|
// Access : public
|
|
// Description : default constructor
|
|
////////////////////////////////////////////////////////////////////
|
|
PointParticleFactory::
|
|
PointParticleFactory(void) :
|
|
BaseParticleFactory() {
|
|
}
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function : PointParticleFactory
|
|
// Access : public
|
|
// Description : copy constructor
|
|
////////////////////////////////////////////////////////////////////
|
|
PointParticleFactory::
|
|
PointParticleFactory(const PointParticleFactory ©) :
|
|
BaseParticleFactory(copy) {
|
|
}
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function : ~PointParticleFactory
|
|
// Access : public
|
|
// Description : destructor
|
|
////////////////////////////////////////////////////////////////////
|
|
PointParticleFactory::
|
|
~PointParticleFactory(void) {
|
|
}
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function : populate_child_particle
|
|
// Access : public
|
|
// Description : child particle generation function
|
|
////////////////////////////////////////////////////////////////////
|
|
void PointParticleFactory::
|
|
populate_child_particle(BaseParticle *bp) const {
|
|
bp->set_oriented(false);
|
|
}
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function : alloc_particle
|
|
// Access : public
|
|
// Description : child particle generation function
|
|
////////////////////////////////////////////////////////////////////
|
|
BaseParticle *PointParticleFactory::
|
|
alloc_particle(void) const {
|
|
return new PointParticle;
|
|
}
|