Skip to content

Commit dbac924

Browse files
authored
Updated "Sound effect" example.
The `ellipseMode` when not set to `RADIUS` would consider the third parameter as `DIAMETER`.
1 parent f1a2439 commit dbac924

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/data/examples/en/33_Sound/05_Sound_Effect.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ class Doorbell {
3232
}
3333
stroke(0);
3434
strokeWeight(4);
35+
ellipseMode(RADIUS);
3536
ellipse(this.x, this.y, this.r, this.r);
3637
}
3738
}
@@ -51,7 +52,7 @@ function setup() {
5152
dingdong = loadSound('assets/doorbell.mp3');
5253

5354
// Create a new doorbell
54-
doorbell = new Doorbell(width / 2, height / 2, 64);
55+
doorbell = new Doorbell(width / 2, height / 2, 32);
5556
}
5657

5758
function draw() {

0 commit comments

Comments
 (0)