• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1RWStructuredBuffer<uint4>      sbuf_rw_i;
2RWStructuredBuffer<uint4>      sbuf_rw_d;
3
4RWStructuredBuffer<uint4>      sbuf_rw_nocounter; // doesn't use inc or dec
5
6float4 main(uint pos : FOO) : SV_Target0
7{
8    uint4 result = 0;
9
10    sbuf_rw_i[7];
11    sbuf_rw_d[7];
12
13    sbuf_rw_nocounter[5] = 2;
14
15    uint c1 = sbuf_rw_i.IncrementCounter();
16    uint c2 = sbuf_rw_d.DecrementCounter();
17
18    return float4(result.x, result.y, c1, c2);
19}
20