1. 移动物体用mouse
  2. 每次run都随机移动物体

来回:x=sin(t)*400

x=sin(t)*((width-50)+(width-50))/2

重复单方向运动:x=(x+1)%400

随机:random()*height

let r=400;

x=map(sin(frameCount/100),-1,1,0,r)

y=map(cos(frameCount/100),-1,1,0,r)

circle(x,y,50)

r=r-0.2

Week 2 — A Self-Portrait in Motion

Open my p5.js sketch

Idea

For this week, I continued working on my self-portrait from Week 1. I wanted to keep the person and green background, but add geometric decorations that could float, fall, and respond to the mouse. My focus was on how a still portrait could feel different when the space around it started moving.

Process