ICM – Speech to Text and Color – Week13


Here is the video of the draft.

Play here

Code here


Save frame

When saveFrame is called in draw, it crashes the sketch. And when I used the game phase to limit when the saveFrame is called, it still repeats when I call the function in draw. But it only calls once when it is in keypressed. However, for me, it sometimes crashes when I type “s” to save so I just gave up due to the limited time.

Sort string length and compare

I struggled a lot on this one. I tried the sorting method at first. But it didn’t work. Therefore, I used the nested for loops, however, I couldn’t get it to work either. When I asked Bomani about the solution, he showed me how to use the sort function and it worked. So the speech is shown with descending order of each word mentioned.

Displaying limited words

Only certain amount of words on a screen–otherwise it is cluttered

Lagging on speech registration

Sometimes it doesn’t show the text when it registers

It keeps listening to the speech but only show when the showResult is called. So the problem I encountered includes when I said things before pressing the space bar, it will show when the timer is up.

KeyTyped function

I was struggling for a while with KeyTyped while using action keys, however, it didn’t work. When I went back to the reference page, I realized about that crucial point and then I used keypressed function.

I was having struggling with the name input with the buttons at first since it won’t go away when the next phases of the game are initiated. Therefore, I created a boolean which is greeted, to test if the button is pressed.

Visual Presentation

I would make the visuals more pleasing but I was running out of time since I had to work on my pcomp. But I’m glad I got to work with text and used speech library as well as mapped to the color so create visual representations in my sketch.

Published by Yiting Liu


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

Create your website with WordPress.com
Get started
<span>%d</span> bloggers like this: