Skip to content

Instantly share code, notes, and snippets.

@longlivemikey
Created July 11, 2019 20:27
Show Gist options
  • Star 5 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save longlivemikey/559497a73c41973a979a9bfce91494a6 to your computer and use it in GitHub Desktop.
Save longlivemikey/559497a73c41973a979a9bfce91494a6 to your computer and use it in GitHub Desktop.
Sine Wave Path - After Effects
S=effect("Speed")("Slider");
A=effect("Amp")("Slider");
F=effect("Freq")("Slider")/3.6;
R=effect("Resolution")("Slider");
W=effect("Width")("Slider")
P=[];
for (i=0;i<R;i++){
P.push([W/R*i,Math.sin(time*S+i/(R/F))*A]);}
createPath(P,[],[], false)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment