Preview.azsl 793 B

12345678910111213141516171819202122232425262728293031
  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. #include <Atom/Features/SrgSemantics.azsli>
  9. #include <Atom/Features/PostProcessing/FullscreenVertex.azsli>
  10. #include <Atom/Features/PostProcessing/FullscreenPixelInfo.azsli>
  11. ShaderResourceGroup RenderImageSrg : SRG_PerPass
  12. {
  13. Texture2D m_texture;
  14. Sampler m_sampler
  15. {
  16. MaxAnisotropy = 16;
  17. AddressU = Wrap;
  18. AddressV = Wrap;
  19. AddressW = Wrap;
  20. };
  21. }
  22. PSOutput MainPS(VSOutput IN)
  23. {
  24. PSOutput OUT;
  25. OUT.m_color = RenderImageSrg::m_texture.SampleLevel(RenderImageSrg::m_sampler, IN.m_texCoord.xy, 0).rgba;
  26. return OUT;
  27. };