Counter Strike : Global Offensive Source Code
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

30 lines
565 B

  1. //====== Copyright � 1996-2007, Valve Corporation, All rights reserved. ===========================
  2. #include "common_vs_fxc.h"
  3. struct VS_INPUT
  4. {
  5. float3 vPos : POSITION;
  6. float2 vBaseTexCoord : TEXCOORD0;
  7. };
  8. struct VS_OUTPUT
  9. {
  10. float4 projPos : POSITION;
  11. float2 vUv0 : TEXCOORD0;
  12. };
  13. VS_OUTPUT main( const VS_INPUT i )
  14. {
  15. VS_OUTPUT o;
  16. o.projPos.xyzw = float4( i.vPos.xyz, 1.0f );
  17. // PS3-specific fixup to y/z coordinates
  18. o.projPos.y = -o.projPos.y;
  19. o.projPos.z = 2.0f * o.projPos.z - o.projPos.w;
  20. o.vUv0.xy = i.vBaseTexCoord.xy;
  21. return o;
  22. }