And the source files zipped with the demos I showed.
http://www.hellokeita.in/presentations/LFPUG/20090827/examples.zip
The contents are:
Example01-SineWaveExample: Simple example generating a sine wave
Example02-KeyboardExample: Example of a piano keyboard
Example03-WaveformExample: Changing the waveform of a sound
Example04-TimePitchExample: Changing pitch and tempo of a mp3
Example05-HeliumBalloon: Real time pitch shifting using Java
Yesterday was my very first time presenting in English at LFPUG.
I was quite nervous but everything went really well.
Thanks Tink to letting me speak there.
Thank you for everyone that went there. The applause in the middle of the presentation cheered me up.
I really enjoyed speaking, and I hope there’s a next time.
I’ll prepare a PDF of the presentation I did together with the source code of the demos I showed and post it here.
Also, Tink should upload the recorded video of the presentation in few days on LFPUG website http://www.lfpug.com
Pitch shifting is the method to change the frequency or the height of a sound.
And why it’s fake? Because, I’m really not using the correct algorithm, actually I just made one for demo purpose. If you listen carefully, you can hear some clippings when you change the slider position.
There is a difference between my previous post about pitch Controlling Pitch and Tempo.
The previous one I was using a dynamically generated sine wave and changing the pitch. It’s much easier because I already have the samples for each sound.
On this example I’m using an MP3 file (Daft Punk, please don’t sue me…If you want, I can change it) and changing the pitch on runtime.
Well it’s working, and as you can see no FPS loss.
The source… well, I’m preparing for my LFPUG presentation so, I’ll try to explain about it there, and than release some kind of source.
There is a post from my friend Li http://www.lidev.com.ar/?p=237 where he is using more accurate algorithm to change the pitch. There’s not much loss on quality and no clips.
Komposer is the main class, who will playback the music.
Timbre is the class that defines the tone of the sound.
Track is a groups of notes that will play with the defined timbre. Currently it will only play one track.
Note is the class that defines the pitch(frequency) and the in/out of the sound.
var komposer:Komposer = new Komposer();
var timbre:Timbre = new Timbre();
timbre.addValue(0);
timbre.addValue(1);
timbre.addValue(-1);
timbre.addValue(0);