Skip to content

Commit bc8a9dc

Browse files
aashu2006ksen0
authored andcommitted
fix(tutorial): use p5.Oscillator constructor
Fixes a ReferenceError in the simple-melody-app tutorial where Oscillator was used without the p5 namespace, causing the example to fail at runtime.
1 parent 118982a commit bc8a9dc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/content/tutorials/en/simple-melody-app.mdx.todo

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,7 @@ let myFreq = 262;
295295
function setup() {
296296
  createCanvas(400, 400);
297297
  // Create the Oscillator object.
298-
  osc = new Oscillator(myFreq);
298+
  osc = new p5.Oscillator(myFreq);
299299
  // console.log(osc.f);
300300
}
301301

0 commit comments

Comments
 (0)