3 ms·
int % float -> float is not a native operation I'm aware of on any CPU or GPU. Even C doesn't have this operation -- the % operator only applies to integers, an
by Jasper_ 5y ago
int % float -> float is not a native operation I'm aware of on any CPU or GPU. Even C doesn't have this operation -- the % operator only applies to integers, and the float variant is a function, fmodf(float, float); shading languages are similar. Also note that GPUs don't have any sort of integer division instruction.