BloomParentPass.h 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  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 <Atom/RPI.Public/Pass/ParentPass.h>
  10. namespace AZ
  11. {
  12. namespace Render
  13. {
  14. //! Parent pass for all Bloom related passes.
  15. //! The only difference between this and ParentPass is that this will check for available bloom settings
  16. //! and disable itself if no settings are found. See the IsEnabled override.
  17. class BloomParentPass final
  18. : public RPI::ParentPass
  19. {
  20. AZ_RPI_PASS(BloomParentPass);
  21. public:
  22. AZ_RTTI(AZ::Render::BloomParentPass, "{072861A3-A87A-439D-BD8B-D2BDD8D31799}", AZ::RPI::ParentPass);
  23. AZ_CLASS_ALLOCATOR(BloomParentPass, SystemAllocator);
  24. virtual ~BloomParentPass() = default;
  25. //! Creates a BloomParentPass
  26. static RPI::Ptr<BloomParentPass> Create(const RPI::PassDescriptor& descriptor);
  27. //! Does a check for available BloomSettings, disable itself when the BloomSetting isn't available.
  28. bool IsEnabled() const override;
  29. private:
  30. BloomParentPass(const RPI::PassDescriptor& descriptor);
  31. };
  32. } // namespace Render
  33. } // namespace AZ