#include "version.sh"
in highp vec3  umf_df_adf;
uniform lowp vec4 color0;
uniform lowp vec4 color1;
uniform highp float period_rev;
uniform highp float space_ratio;

out lowp vec4 fragColor;

void main()
{
    highp float acc_period = umf_df_adf.z * period_rev;
    acc_period = fract(acc_period);
    lowp float ratio = step(space_ratio, acc_period);
    fragColor = mix(color1, color0, ratio);
    fragColor.a *= clamp(umf_df_adf.x - abs(umf_df_adf.y), 0.0, 1.0);
}
