Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / May 2005

Tip: Looking for answers? Try searching our database.

Guitar tuning algorithms...

Thread view: 
SPG - 16 May 2005 00:38 GMT
Hi all,

I have written an app that will connect and listen to an input from my sound
card.
At the moment I just display the waveform on a realtime graph, which looks
pretty cool, but now I want to try and add a guitar tuning module just for
fun.

I have googled a bit to find out what I need to do, and a lot points to FFT
algorithms, I was wondering if there is anyone outhtere with a bit more info
on how to best implement this (I have an FFT class but not a clue what I
should do with it!)

Steve
Rhino - 17 May 2005 18:39 GMT
> Hi all,
>
[quoted text clipped - 10 lines]
>
> Steve

You might get an answer to your question at a more specialized
newsgroup/mailing list like this one:
http://java.sun.com/products/java-media/sound/list.html

or this one:

http://forums.java.sun.com/category.jspa?categoryID=9

Rhino
Christian Gudrian - 17 May 2005 19:04 GMT
Am Sun, 15 May 2005 23:38:50 GMT schrieb SPG:

> I have an FFT class but not a clue what I should do with it!

Try to get the documentation for the class from the source you got the
class itself from.

Basically you will have to fill some sort of array with the source data
(your waveform).  You will have to configure the FFT class (number of
frequency bands, window function) and transform the data.  After that you
get the spectrum of the original waveform.  Search for the frequency with
maximum aplitude and you have the first, rough estimation of the tone that
has been played.

Christian
Juhan Kundla - 18 May 2005 09:04 GMT
Hei!

> Search for the frequency with
> maximum aplitude and you have the first, rough estimation of the tone that
> has been played.

Hm, i'm not completely sure, but i think that for tuning the lowest
frequency must be used, since this is what defines the pitch of the
tone. The higher frequencies define only the timbre of the tone.

Probably the lowest frequency has also the maximum amplitude, at least
with conventional quitar.

Juhan
Esmond Pitt - 19 May 2005 02:37 GMT
> Hei!
>
[quoted text clipped - 8 lines]
> Probably the lowest frequency has also the maximum amplitude, at least
> with conventional quitar.

Generally with any musical instrument the 2nd harmonic has the maximum
amplitude, and this is certainly true of bass guitars and violins (have
no info on guitars). In some cases like the clarinet it is the 3rd.


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.