Micah,
So, vWinCoord.x should return a index value and not a value of an element? indexof() returns the index value of the kernel, not the value of that element of the variable in that index of the kernel.
My questions is when I do this:
"il_ps_2_0\n"
"dcl_input_position_interp(linear) vWinCoord0.x___\n"
"dcl_output_generic o0\n"
"dcl_resource_id(0)_type(1d,unnorm)_fmtx(float)_fmty(float)_fmtz(float)_fmtw(float)\n"
"dcl_resource_id(1)_type(1d,unnorm)_fmtx(float)_fmty(float)_fmtz(float)_fmtw(float)\n"
"dcl_literal l0, 0x0000001, 0x00000002, 0x00000002, 0x00000002\n"
"mov r1, l0\n"
"utof r2, r1\n"
"sample_resource(0)_sampler(0) r0, vWinCoord0.x\n"
"sample_resource(1)_sampler(1) r3, vWinCoord0.x\n"
"mul r1, r0, r3\n"
"div o0, r1, r2\n"
"ret_dyn\n"
"end\n";
What exactly is the "sample_resource(x)_samper(x) rx, vWinCoord0.x" statement doing? I didn't really gather this from the IL docs. If vWinCoord0.x is an "indexof()" then where is r0 getting it's value from, in Hardware?
Furthermore, does the statement go to the position of the resource(x) held by index vWinCoord0.x and return that value to rx?