Published
Edited
Dec 17, 2020
2 stars
Insert cell
Insert cell
Insert cell
Insert cell
bnb({
w, h,
webgl: true,
numFrames: 125,
fps: 25,
record: true,
video: true,
loops:4,
shutterAngle: 0.8,
samplesPerFrame: 12,
chromaticAberration: 100,
setup: (s, g) => {
s.frameRate(25)
},
draw: (s, t, g) => {
s.background(22)
s.rotateY(t * s.TAU)
s.rotateZ(t * s.TAU)
s.stroke(255)
s.strokeWeight(2)
s.fill(0)
const angle = t * s.TAU
const w = 100 + (s.cos(angle) * s.sin(8 * angle) + 1) * 150
const d = 100 + (s.sin(angle) * s.sin(8 * angle) + 1) * 50
s.box(w, d, d)
s.push()
s.rotateZ(s.PI/2)
s.box(w, d, d)
s.pop()
s.push()
s.rotateY(s.PI/2)
s.box(w, d, d)
s.pop()
},
})
Insert cell
Insert cell
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more