diff --git a/05/cubicpulse.frag b/05/cubicpulse.frag index a365991..f1461f5 100644 --- a/05/cubicpulse.frag +++ b/05/cubicpulse.frag @@ -15,9 +15,9 @@ float cubicPulse( float c, float w, float x ){ return 1.0 - x*x*(3.0-2.0*x); } -float plot(vec2 _st, float _pct){ - return smoothstep( _pct-0.02, _pct, _st.y) - - smoothstep( _pct, _pct+0.02, _st.y); +float plot(vec2 st, float pct){ + return smoothstep( pct-0.02, pct, st.y) - + smoothstep( pct, pct+0.02, st.y); } void main() { diff --git a/05/expo.frag b/05/expo.frag index 377b0ae..8f02d22 100644 --- a/05/expo.frag +++ b/05/expo.frag @@ -8,9 +8,9 @@ uniform vec2 u_resolution; uniform vec2 u_mouse; uniform float u_time; -float plot(vec2 _st, float _pct){ - return smoothstep( _pct-0.01, _pct, _st.y) - - smoothstep( _pct, _pct+0.01, _st.y); +float plot(vec2 st, float pct){ + return smoothstep( pct-0.02, pct, st.y) - + smoothstep( pct, pct+0.02, st.y); } void main() { diff --git a/05/expstep.frag b/05/expstep.frag index bf25534..60369d4 100644 --- a/05/expstep.frag +++ b/05/expstep.frag @@ -12,9 +12,9 @@ float expStep( float x, float k, float n ){ return exp( -k*pow(x,n) ); } -float plot(vec2 _st, float _pct){ - return smoothstep( _pct-0.01, _pct, _st.y) - - smoothstep( _pct, _pct+0.01, _st.y); +float plot(vec2 st, float pct){ + return smoothstep( pct-0.02, pct, st.y) - + smoothstep( pct, pct+0.02, st.y); } void main() { diff --git a/05/impulse.frag b/05/impulse.frag index 93995bc..9ca5091 100644 --- a/05/impulse.frag +++ b/05/impulse.frag @@ -13,9 +13,9 @@ float impulse( float k, float x ){ return h*exp(1.0-h); } -float plot(vec2 _st, float _pct){ - return smoothstep( _pct-0.01, _pct, _st.y) - - smoothstep( _pct, _pct+0.01, _st.y); +float plot(vec2 st, float pct){ + return smoothstep( pct-0.02, pct, st.y) - + smoothstep( pct, pct+0.02, st.y); } void main() { diff --git a/05/linear.frag b/05/linear.frag index 821d0f8..e594a92 100644 --- a/05/linear.frag +++ b/05/linear.frag @@ -7,9 +7,9 @@ uniform vec2 u_mouse; uniform float u_time; // Plot a line on Y using a value between 0.0-1.0 -float plot(vec2 _st, float _pct){ - return smoothstep( _pct-0.01, _pct, _st.y) - - smoothstep( _pct, _pct+0.01, _st.y); +float plot(vec2 st, float pct){ + return smoothstep( pct-0.02, pct, st.y) - + smoothstep( pct, pct+0.02, st.y); } void main() { diff --git a/05/parabola.frag b/05/parabola.frag index 21dfadc..6b9f5ed 100644 --- a/05/parabola.frag +++ b/05/parabola.frag @@ -11,9 +11,9 @@ float parabola( float x, float k ){ return pow( 4.0*x*(1.0-x), k ); } -float plot(vec2 _st, float _pct){ - return smoothstep( _pct-0.01, _pct, _st.y) - - smoothstep( _pct, _pct+0.01, _st.y); +float plot(vec2 st, float pct){ + return smoothstep( pct-0.02, pct, st.y) - + smoothstep( pct, pct+0.02, st.y); } void main() { diff --git a/05/pcurve.frag b/05/pcurve.frag index e6cb85e..33fc204 100644 --- a/05/pcurve.frag +++ b/05/pcurve.frag @@ -13,9 +13,9 @@ float pcurve( float x, float a, float b ){ return k * pow( x, a ) * pow( 1.0-x, b ); } -float plot(vec2 _st, float _pct){ - return smoothstep( _pct-0.01, _pct, _st.y) - - smoothstep( _pct, _pct+0.01, _st.y); +float plot(vec2 st, float pct){ + return smoothstep( pct-0.02, pct, st.y) - + smoothstep( pct, pct+0.02, st.y); } void main() { diff --git a/05/smoothstep.frag b/05/smoothstep.frag index 350de26..7111a30 100644 --- a/05/smoothstep.frag +++ b/05/smoothstep.frag @@ -8,9 +8,9 @@ uniform vec2 u_resolution; uniform vec2 u_mouse; uniform float u_time; -float plot(vec2 _st, float _pct){ - return smoothstep( _pct-0.01, _pct, _st.y) - - smoothstep( _pct, _pct+0.01, _st.y); +float plot(vec2 st, float pct){ + return smoothstep( pct-0.02, pct, st.y) - + smoothstep( pct, pct+0.02, st.y); } void main() { diff --git a/05/step.frag b/05/step.frag index 41a82f0..927a213 100644 --- a/05/step.frag +++ b/05/step.frag @@ -7,9 +7,9 @@ precision mediump float; uniform vec2 u_resolution; uniform float u_time; -float plot(vec2 _st, float _pct){ - return smoothstep( _pct-0.01, _pct, _st.y) - - smoothstep( _pct, _pct+0.01, _st.y); +float plot(vec2 st, float pct){ + return smoothstep( pct-0.02, pct, st.y) - + smoothstep( pct, pct+0.02, st.y); } void main() {