ParticleSystemFactory.h 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. /*
  2. * Copyright (C) 2022 The V-Gears Team
  3. *
  4. * This file is part of V-Gears
  5. *
  6. * V-Gears is free software: you can redistribute it and/or modify it under
  7. * terms of the GNU General Public License as published by the Free Software
  8. * Foundation, version 3.0 (GPLv3) of the License.
  9. *
  10. * V-Gears is distributed in the hope that it will be useful,
  11. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. * GNU General Public License for more details.
  14. */
  15. #pragma once
  16. #include <OgreMovableObject.h>
  17. /**
  18. * A particle system factory.
  19. */
  20. class ParticleSystemFactory : public Ogre::MovableObjectFactory{
  21. public:
  22. /**
  23. * Constructor.
  24. */
  25. ParticleSystemFactory(){};
  26. /**
  27. * Destructor.
  28. */
  29. ~ParticleSystemFactory(){};
  30. /**
  31. * Type of the particle systems
  32. */
  33. static Ogre::String FACTORY_TYPE_NAME;
  34. /**
  35. * Retrieves the particle systems type.
  36. *
  37. * @return The particle systems type.
  38. */
  39. const Ogre::String& getType() const;
  40. /**
  41. * Destroys a particle system.
  42. *
  43. * @param obj[in|out] System to destroy.
  44. */
  45. void DestroyInstance(Ogre::MovableObject* obj);
  46. private:
  47. /**
  48. * Creates an instance from a template.
  49. *
  50. * @param name[in] Name for the particle system
  51. * @param params[in] List of parameters for the particle system.
  52. */
  53. Ogre::MovableObject* createInstanceImpl(
  54. const Ogre::String& name, const Ogre::NameValuePairList* params
  55. );
  56. };