• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1SamplerState       g_sSamp : register(s0);
2
3RWTexture1D <float4> g_tTex1df4 : register(t0);
4RWTexture1D <int4>   g_tTex1di4;
5RWTexture1D <uint4>  g_tTex1du4;
6
7RWTexture2D <float4> g_tTex2df4;
8RWTexture2D <int4>   g_tTex2di4;
9RWTexture2D <uint4>  g_tTex2du4;
10
11RWTexture3D <float4> g_tTex3df4;
12RWTexture3D <int4>   g_tTex3di4;
13RWTexture3D <uint4>  g_tTex3du4;
14
15RWTexture1DArray <float4> g_tTex1df4a;
16RWTexture1DArray <int4>   g_tTex1di4a;
17RWTexture1DArray <uint4>  g_tTex1du4a;
18
19RWTexture2DArray <float4> g_tTex2df4a;
20RWTexture2DArray <int4>   g_tTex2di4a;
21RWTexture2DArray <uint4>  g_tTex2du4a;
22
23RWBuffer <float4> g_tBuffF;
24RWBuffer <int4>   g_tBuffI;
25RWBuffer <uint4>  g_tBuffU;
26
27struct PS_OUTPUT
28{
29    float4 Color : SV_Target0;
30    float  Depth : SV_Depth;
31};
32
33uniform int   c1;
34uniform int2  c2;
35uniform int3  c3;
36uniform int4  c4;
37
38uniform int   o1;
39uniform int2  o2;
40uniform int3  o3;
41uniform int4  o4;
42
43PS_OUTPUT main()
44{
45   PS_OUTPUT psout;
46
47   uint MipLevel;
48   uint WidthU;
49   uint HeightU;
50   uint ElementsU;
51   uint DepthU;
52   uint NumberOfLevelsU;
53   uint NumberOfSamplesU;
54
55   float WidthF;
56   float HeightF;
57   float ElementsF;
58   float DepthF;
59   float NumberOfLevelsF;
60   float NumberOfSamplesF;
61
62   // 1D, float/int/uint, uint params
63   g_tTex1df4.GetDimensions(WidthU);
64   g_tTex1di4.GetDimensions(WidthU);
65   g_tTex1du4.GetDimensions(WidthU);
66
67   // buffer, float/int/uint, uint params
68   g_tBuffF.GetDimensions(WidthU);
69   g_tBuffI.GetDimensions(WidthU);
70   g_tBuffU.GetDimensions(WidthU);
71
72   // 1DArray, float/int/uint, uint params
73   g_tTex1df4a.GetDimensions(WidthU, ElementsU);
74   g_tTex1di4a.GetDimensions(WidthU, ElementsU);
75   g_tTex1du4a.GetDimensions(WidthU, ElementsU);
76
77   // 2D, float/int/uint, uint params
78   g_tTex2df4.GetDimensions(WidthU, HeightU);
79   g_tTex2di4.GetDimensions(WidthU, HeightU);
80   g_tTex2du4.GetDimensions(WidthU, HeightU);
81
82   // 2DArray, float/int/uint, uint params
83   g_tTex2df4a.GetDimensions(WidthU, HeightU, ElementsU);
84   g_tTex2di4a.GetDimensions(WidthU, HeightU, ElementsU);
85   g_tTex2du4a.GetDimensions(WidthU, HeightU, ElementsU);
86
87   // 3D, float/int/uint, uint params
88   g_tTex3df4.GetDimensions(WidthU, HeightU, DepthU);
89   g_tTex3di4.GetDimensions(WidthU, HeightU, DepthU);
90   g_tTex3du4.GetDimensions(WidthU, HeightU, DepthU);
91
92   psout.Color = 1.0;
93   psout.Depth = 1.0;
94
95   return psout;
96}
97