LookModificationComponentController.h 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  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 <AzCore/Component/TransformBus.h>
  11. #include <AtomLyIntegration/CommonFeatures/PostProcess/LookModification/LookModificationBus.h>
  12. #include <AtomLyIntegration/CommonFeatures/PostProcess/LookModification/LookModificationComponentConfig.h>
  13. #include <ACES/Aces.h>
  14. #include <Atom/Feature/PostProcess/LookModification/LookModificationSettingsInterface.h>
  15. #include <Atom/Feature/PostProcess/PostProcessSettingsInterface.h>
  16. #include <Atom/Feature/PostProcess/PostProcessFeatureProcessorInterface.h>
  17. #include <AzCore/Asset/AssetCommon.h>
  18. #include <Atom/RPI.Reflect/System/AnyAsset.h>
  19. namespace AZ
  20. {
  21. namespace Render
  22. {
  23. class LookModificationComponentController final
  24. : public LookModificationRequestBus::Handler
  25. {
  26. public:
  27. friend class EditorLookModificationComponent;
  28. AZ_TYPE_INFO(AZ::Render::LookModificationComponentController, "{66912D19-CAB2-457C-A4EF-88FE4AF592B1}");
  29. static void Reflect(AZ::ReflectContext* context);
  30. static void GetProvidedServices(AZ::ComponentDescriptor::DependencyArrayType& provided);
  31. static void GetIncompatibleServices(AZ::ComponentDescriptor::DependencyArrayType& incompatible);
  32. static void GetRequiredServices(AZ::ComponentDescriptor::DependencyArrayType& required);
  33. LookModificationComponentController() = default;
  34. LookModificationComponentController(const LookModificationComponentConfig& config);
  35. void Activate(EntityId entityId);
  36. void Deactivate();
  37. void SetConfiguration(const LookModificationComponentConfig& config);
  38. const LookModificationComponentConfig& GetConfiguration() const;
  39. // Auto-gen function override declarations (functions definitions in .cpp)...
  40. #include <Atom/Feature/ParamMacros/StartParamFunctionsOverride.inl>
  41. #include <Atom/Feature/PostProcess/LookModification/LookModificationParams.inl>
  42. #include <Atom/Feature/ParamMacros/EndParams.inl>
  43. private:
  44. AZ_DISABLE_COPY(LookModificationComponentController);
  45. void OnConfigChanged();
  46. PostProcessSettingsInterface* m_postProcessInterface = nullptr;
  47. LookModificationSettingsInterface* m_settingsInterface = nullptr;
  48. LookModificationComponentConfig m_configuration;
  49. EntityId m_entityId;
  50. };
  51. }
  52. }