Bruh. That code is barely human readable, but here's what I discovered anyway. Those uniforms aren't meant to be uniforms. You should define them at the beginning of the fragment shader and pass them through the functions manually. Their definition in each function should include inout
so that it can be modified by the function.
mp( vec3 p, inout vec3 pp, inout vec3 bp, inout float tt, inout float b, inout float bb, inout float g, inout float g2)
{
...
void fragment() {
float t=0.0, tt=0.0, b=0.0, g=0.0, g2=0.0, bb=0.0;
vec3 np=vec3(0.0), bp=vec3(0.0), pp=vec3(0.0), po=vec3(0.0), no=vec3(0.0), al=vec3(0.0), ld=vec3(0.0);
...
I've tried to do it, but proved to be a difficult task. Good luck with that!