by Luigi Rosso
Comments
Silverlight 4 Guitar Tuner
One of the cool new features of Silverlight 4 is raw access to the camera and microphone. This opens up a whole bunch of cool possibilities for software development. One of them which we explored was creating an online guitar tuner.
Microsoft unveiled a beta version of Silverlight 4 at PDC, you can grab it here if you don’t have it installed
I remember looking for something like this a few years ago when I couldn’t find my real guitar tuner. All I found were a bunch of tools which simply played back the right pitch, they would not analyze the actual recorded pitch from your guitar, which is what I was used to using. I found some shareware tools that would do this but I really wanted something quick that I could just browse to and tune my guitar, and not risk downloading some viruses or waste time installing something only to realize it doesn’t do exactly what I wanted.
With Silverlight 4, we can now do this. We simply calculate the spectogram of the frequencies comprising a short period of time (currently half a second) to find the fundamental frequency of the sampled sound.
My favorite tuner lately has been the one on my POD XT Pro, so we designed this to look like that.
To speed things up, we used a good FFT implementation found on CodeProject and simply adapted it to work with Silverlight.
We also added a little bit of silence detection which helps the Tuner show when there’s no input, ideally you’d have some settings for this and some more input feedback with something like a volume meter. This is disabled in the demo above, you can enable it at compile time. Grab the source here, and feel free to implement these things yourself!
For any inquiries feel free to
.








