Stencil.azsl 718 B

123456789101112131415161718192021222324252627282930313233343536373839
  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. struct VSInput
  9. {
  10. float3 m_position : POSITION;
  11. float4 m_color : COLOR0;
  12. };
  13. struct VSOutput
  14. {
  15. float4 m_position : SV_Position;
  16. float4 m_color : COLOR0;
  17. };
  18. VSOutput MainVS(VSInput vsInput)
  19. {
  20. VSOutput OUT;
  21. OUT.m_position = float4(vsInput.m_position, 1.0);
  22. OUT.m_color = vsInput.m_color;
  23. return OUT;
  24. }
  25. struct PSOutput
  26. {
  27. float4 m_color : SV_Target0;
  28. };
  29. PSOutput MainPS(VSOutput vsOutput)
  30. {
  31. PSOutput OUT;
  32. OUT.m_color = vsOutput.m_color;
  33. return OUT;
  34. }