Sample? into variable

Audio software developers forum.
Forum rules
If you require help using Audacity, please post on the forum board relevant to your operating system:
Windows
Mac OS X
GNU/Linux and Unix-like
Post Reply
EdakX
Posts: 2
Joined: Fri Jun 25, 2010 6:06 am
Operating System: Please select

Sample? into variable

Post by EdakX » Fri Jun 25, 2010 6:24 am

Hey all, I want to start by saying I've looked around for this, google, this form, etc. I think my main problem is I don't know exactly what I'm looking for. Also, I know the title is a little bland/odd.

Anyways, I've programmed for years, but I'm attempting something that has to deal with music files specifically now and I've never worked with audio in programming.

1. What's the shortest piece of information in an audio file that gets directly translated to sound? Is it a sample?
-My further questions will assume it's sample:

2. All samples are initially numbers in some form or another before they are converted to sound, how do I access that specific number so I can use it within my code?

3. What files inside Audacity source code deal with this portion? I'd love to read through it.

If you have any reading material dealing in this subject, please point me in that direction also.

I'm trying to write a program that will compare each second against every other second, ultimately finding the chorus (school project) so my first step is finding how to turn each piece/sample into a numerical value for comparison.

Thanks!!

steve
Site Admin
Posts: 81609
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: Sample? into variable

Post by steve » Fri Jun 25, 2010 1:28 pm

If you are an advanced C+ programmer, this may be of interest: http://wiki.audacityteam.org/wiki/Proposal_Audio_Diff
If you are looking for something a lot more simple, perhaps you could develop something using Nyquist: http://audacityteam.org/help/nyquist

There is a simple Nyquist plug-in for reading individual audio samples here: http://forum.audacityteam.org/viewtopic ... 39&t=34365

Some good links for Nyquist programming:
http://www.audacity-forum.de/download/e ... ist-en.htm
http://www.audacity-forum.de/download/e ... /home.html
http://www.audacity-forum.de/download/e ... -index.htm
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

EdakX
Posts: 2
Joined: Fri Jun 25, 2010 6:06 am
Operating System: Please select

Re: Sample? into variable

Post by EdakX » Sat Jun 26, 2010 6:42 am

Thanks for the links! Looks like Proposal Audio Diff is exactly what I was looking for :) I'll start reading

Post Reply