I’m on a bit of a roll with the HLSL>GLSL translation. This one is the latest version of the VVVV Superformula shader. This time, a 2D superformula transformation is applied to the mesh, before the 3D one, for even more complex forms. Seems to work best with lower scale values, as higher values produce chaotic-looking results, with lots of self-intersection.
I did most of the code translation work on a recent train journey.