260 likes | 448 Views
Sound Processing. Arithmetic on Sound. Sound is an array of amplitudes (numbers) Adding two sounds together Make a sound louder or softer Blends of two sounds Echos. Adding two sounds. Laser Guns. +. Distress. =. New Sound. Adding Sounds Demo. Cool Edit Edit -> Mix Paste.
E N D
Arithmetic on Sound • Sound is an array of amplitudes (numbers) • Adding two sounds together • Make a sound louder or softer • Blends of two sounds • Echos
Adding two sounds Laser Guns + Distress = New Sound
Adding Sounds Demo • Cool Edit • Edit -> Mix Paste
Adding two sounds Laser = laser gun sound; Warn = warning message; NewSnd = new array(Laser.length); for (each index i in NewSnd) { NewSnd[i]=Laser[i]+Warn[i]; }
Amplify Sound Demo • Cool Edit • Transform -> Amplitude -> Amplify
Making a sound louder for (each index i in oldSound) { newSound[i]=oldSound[i]*3; }
General Amplify algorithm amp = 3.0; three times as loud for (each index i in oldSound) { newSound[i]=oldSound[i]*amp; }
General Amplify algorithm amp = 0.5; half as loud for (each index i in oldSound) { newSound[i]=oldSound[i]*amp; }
Blending two sounds Whistle 90% whistle 10% words 50% whistle 50% words 10% whistle 90% words Words
Blending Sounds Demo • Cool Edit • Transform -> Amplitude -> Amplify • Edit -> Mix Paste
Blending two sounds B = blend value between 0.0 and 1.0 for (each index i in Snd1) { newSnd[i]=(1.0-B)*Snd1[i]+ B*Snd2[i]; }
Singing a Round by yourself • Row Row Row your boat
Singing a Round by yourself • Row Row Row your boat • Sing in a round
Singing a round by yourself + Time delay =
Singing a round by yourself Demo • Cool Edit • Edit -> Mix Paste
Singing a round by yourself song = the original song; delay = how many samples to delay; newSng = new array(song.length+delay); for (each index i in song) { newSng[i] = song[i]; } for (each index i in song) { newSng[i+delay] = newSng[i+delay]+song[i]; }
Echoes • An echo occurs because sound returns delayed and softer after bouncing off of something • Original • Canyon Echo (large delay) • Room Reverb (small delay)
Echoes Demo • Cool Edit • Transform -> Delay Effects -> Echo
Echoes sound = the original sound; delay = how many samples to delay; softness = 0.1; newSound = new array(sound.length+delay); for (each index i in sound) { newSound[i] = sound[i]; } for (each index i in sound) { newSound[i+delay] = newSound[i+delay] + sound[i]*softness; }
Speech Recognition • Converting an audio signal into text • Problems • There is no way to write this sentence in english • to • two • too
Speech Recognition - problems • Diversity of speech • I want a cookie • I want a cookie • I want a cookie • Confused recognition • I want to fly • Eye want to cry
Speech Recognition - success • Small number of words • about 1000 • Clear differences among words • Train recognizer to person’s voice
Speech synthesis • Converting text into sound • Concatenation of sound • Words go together funny • Prosody, the inflection that you speak with • Variation changes meaning • That is yours • That is yours