Lines Silhouette

Lines Silhouette

January 10, 2021

example p5.js javascript for-loops

This sketch uses a for loop to draw a bunch of lines with random lengths to create a silhouette effect.

lines silhouette

Remix Ideas

  • Change the minLineWidth, maxLineWidth, and lineWidthChange variables to create different effects.
  • Give each line a different color.
  • Make the lines pattern horizontal instead of vertical, so that it looks like an audio waveform.

For Loops Examples


Happy Coding is a community of folks just like you learning about coding.
Do you have a comment or question? Post it here!

Comments are powered by the Happy Coding forum. This page has a corresponding forum post, and replies to that post show up as comments here. Click the button above to go to the forum to post a comment!