Hi all,
I read in ispc guide that it is not valid to assign varying value to uniform value.
However it sounds like neccesary thing to do then returning values through referenced array, like in this example from ispc guide:
export void simple(uniform float vin[], uniform float vout[],
uniform int count) {
foreach (index = 0 ... count) {
float v = vin[index];
if (v < 3.)
v = v * v;
else
v = sqrt(v);
vout[index] = v;
}
}
vout is uniform and v is varying but it is still ok to do vout[index] = v, how is that?
Thank you