chjno / MEDP349-Fall17

MEDP 349 Physical Computing, Hunter College, Fall 2017
3 stars 3 forks source link

speech #10

Open AlexPitre opened 7 years ago

AlexPitre commented 7 years ago

I put the speech synthesis library in and I added the script line into the index.

the sample code the library gives is:

var foo = new p5.Speech(); // speech synthesis object foo.speak('hi there'); // say something

I get an error message saying that p5.Speech is not a constructor. I put it in the setup and the draw loop, but idk which one is correct. All the tutorials I found online were way over my head. I'm just trying to understand how to put it into the code I have to read the text on the screen.

AlexPitre commented 7 years ago

p.s. the piezo is working great on the wood

AlexPitre commented 7 years ago

p.p.s. the more I work on it, the more questions I have.

chjno commented 7 years ago

Hey!

I just got the simple speech synthesis example working from the p5.speech website. Here's the example: http://alpha.editor.p5js.org/chjno/sketches/Sy_MPT40Z

I added the p5.speech.js library manually, the same way we added the p5.serialport.js library.

I don't have time right now to dig deeper but lmk if that helps or if you have any more questions!