Skip to content

Instantly share code, notes, and snippets.

@jpcima
Last active October 1, 2020 12:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jpcima/cd3d7b605f2391ef21dbb272a5431bbe to your computer and use it in GitHub Desktop.
Save jpcima/cd3d7b605f2391ef21dbb272a5431bbe to your computer and use it in GitHub Desktop.
Parametric crossfade curves
set mxtics 2
set mytics 2
set grid mxtics mytics
set key top center
set xrange [0:1]
set yrange [0:1]
fadePowS(k, x) = (x<0.5) ? ((1-(2*x)**k)/2+.5) : (((1-2*(x-.5))**k)/2)
k=3
plot fadePowS(k, x) t "Out", fadePowS(k, 1-x) t "In"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment