Is there no looping in the material editor?

I can’t seem to be able find a way to loop inside the material editor. Is that not possible? Both GLSL and HLSL have for loops, so why wouldn’t there be one in the material editor?

My use-case is processing an NxN square (where N could possibly even be a parameter) around each pixel to determine its color. It’s hardly sane to have to have N^2 copies of the same processing (and even impossible if N is a parameter).

Any ideas?

I have the same issue.

I think you have to put it in a custom shader:

You need to do this in HLSL code via the ccustom shader using the “while” function.