HairComponent.h 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. /*
  2. * Copyright (c) Contributors to the Open 3D Engine Project.
  3. * For complete copyright and license terms please see the LICENSE at the root of this distribution.
  4. *
  5. * SPDX-License-Identifier: Apache-2.0 OR MIT
  6. *
  7. */
  8. #pragma once
  9. #include <AzCore/Component/Component.h>
  10. #include <AzFramework/Components/ComponentAdapter.h>
  11. // Hair specific
  12. #include <Components/HairComponentConfig.h>
  13. #include <Components/HairComponentController.h>
  14. namespace AZ
  15. {
  16. namespace Render
  17. {
  18. namespace Hair
  19. {
  20. class HairRenderObject;
  21. inline constexpr AZ::TypeId HairComponentTypeId{ "{9556883B-6F3C-4010-BB3F-EBB480515D68}" };
  22. //! Parallel to the 'EditorHairComponent' this class is used in game mode.
  23. class HairComponent final
  24. : public AzFramework::Components::ComponentAdapter<HairComponentController, HairComponentConfig>
  25. {
  26. public:
  27. using BaseClass = AzFramework::Components::ComponentAdapter<HairComponentController, HairComponentConfig>;
  28. AZ_COMPONENT(AZ::Render::Hair::HairComponent, Hair::HairComponentTypeId, BaseClass);
  29. HairComponent() = default;
  30. HairComponent(const HairComponentConfig& config);
  31. ~HairComponent();
  32. static void Reflect(AZ::ReflectContext* context);
  33. void Activate() override;
  34. };
  35. } // namespace Hair
  36. } // namespace Render
  37. } // namespace AZ