orientedParticle.cxx 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. // Filename: orientedParticle.cxx
  2. // Created by: charles (19Jun00)
  3. //
  4. ////////////////////////////////////////////////////////////////////
  5. //
  6. // PANDA 3D SOFTWARE
  7. // Copyright (c) 2001, Disney Enterprises, Inc. All rights reserved
  8. //
  9. // All use of this software is subject to the terms of the Panda 3d
  10. // Software license. You should have received a copy of this license
  11. // along with this source code; you will also find a current copy of
  12. // the license at http://www.panda3d.org/license.txt .
  13. //
  14. // To contact the maintainers of this program write to
  15. // [email protected] .
  16. //
  17. ////////////////////////////////////////////////////////////////////
  18. #include "orientedParticle.h"
  19. ////////////////////////////////////////////////////////////////////
  20. // Function : OrientedParticle
  21. // Access : public
  22. // Description : simple constructor
  23. ////////////////////////////////////////////////////////////////////
  24. OrientedParticle::
  25. OrientedParticle(int lifespan, bool alive) :
  26. BaseParticle(lifespan, alive) {
  27. set_oriented(true);
  28. }
  29. ////////////////////////////////////////////////////////////////////
  30. // Function : OrientedParticle
  31. // Access : public
  32. // Description : copy constructor
  33. ////////////////////////////////////////////////////////////////////
  34. OrientedParticle::
  35. OrientedParticle(const OrientedParticle &copy) :
  36. BaseParticle(copy) {
  37. }
  38. ////////////////////////////////////////////////////////////////////
  39. // Function : ~OrientedParticle
  40. // Access : public
  41. // Description : simple destructor
  42. ////////////////////////////////////////////////////////////////////
  43. OrientedParticle::
  44. ~OrientedParticle(void) {
  45. }
  46. ////////////////////////////////////////////////////////////////////
  47. // Function : make_copy
  48. // Access : public, virtual
  49. // Description : simple destructor
  50. ////////////////////////////////////////////////////////////////////
  51. PhysicsObject *OrientedParticle::
  52. make_copy(void) const {
  53. return new OrientedParticle(*this);
  54. }
  55. ////////////////////////////////////////////////////////////////////
  56. // Function : init
  57. // Access : Public
  58. // Description : particle init routine
  59. ////////////////////////////////////////////////////////////////////
  60. void OrientedParticle::
  61. init(void) {
  62. }
  63. ////////////////////////////////////////////////////////////////////
  64. // Function : die
  65. // Access : public
  66. // Description : particle death routine
  67. ////////////////////////////////////////////////////////////////////
  68. void OrientedParticle::
  69. die(void) {
  70. }
  71. ////////////////////////////////////////////////////////////////////
  72. // Function : update
  73. // Access : public
  74. // Description : particle update routine.
  75. // This NEEDS to be filled in with quaternion slerp
  76. // stuff, or oriented particles will not rotate.
  77. ////////////////////////////////////////////////////////////////////
  78. void OrientedParticle::
  79. update(void) {
  80. }