Page 1 of 1

looping the test tones, intersting discovery inside:)

PostPosted: Sat Sep 13, 2003 9:02 am
by sampleandhold
i was starting to make a new patch, once again i come up with a cheesy hardcore pad... i must be depressed. anyway, i discovered more to my dismay that my test tones were still out of tune. appearantly i am having diffeculties in looping my tones, even though they sound fine. so this is what i discovered. and for those of you who are struggling with getting the loops just right, i think this will be applicable not only to test tones, but to any sound source providing you know the note of the source you are planning on looping.

okay.

here we go... again

if you have your test tones sampled, and you sampled them at 440 hz, or A4 i dare you to select any start point away from the start of wave. say.... sample 36, set your start there. okay now this point will more then likely be above the zero crossing. but it doesn't matter. really it doesn't. okay now, take your end point and put it at say.... sample 136. you have a loop size of 100. now play your test tone. you WILL hear no clicking, no buzz, just the pure sweet sound of your test tone. of course you have to make sure you sampled the tones at 440 hz with a sample rate of 44.1.

now play this along with any of the other tones you have. you may actualy hear a beat when you play the tone with the loop size of 100 with another loop you set differently. of course that means that the other tone is not actually playing A4.

now go through and set the rest of your test tones with loop sizes of 100. they will loop perfectly and sound good. you can even have loop sizes of 200, 300, and up. how ever, one of my test tones actualy seem to have artifacts at 400. it had a faint buzz in the back ground. once i changed to to a loop size of 100, the artifact disappeared.

all my test tones are now set with loop sizes of 100. what was strange is that i started to set one of my triangle waves with a loop size of 400 and the other one with a loop size of 100 and they matched. but i didn't think much of it. then i started to discover that everything was out of tune and i started to adjust things, i found that all the other test tones were matching up perfectly if they all had the same size loop, or a mutliple of 100 hundred.

now for the exciting part. i haven't tried this out, i am actually formulating this as i type. my samples were all sampled at 44.1, this means that for every second there are 44100 samples. so for every 100 samples you get about 1.00227272727272727272727272727273 cycle. pretty close to perfect i would say. this would mean our A4 will actualy be about 442hz. from what i have read some synths have A4 tuned up to 445hz. whatever.

now this is the idea that i am coming to. lets say you have a sample of a bass at say f#2, that is about 92.4986hz. you take 44100 and divide that by 92.4986 and you should get an answer of 476.7639blah blah blah. this answer is your loop size. i would set the loop points anywere along the wave as long as there is a loop size of 477 samples in it. i would figure rounding up would be best. your sample should sound perfect but your sample really wont be technically f#2 any more. it will actualy be a little bit lower but really at that kind of level, i don't think anyone but a machine will know the difference.

i just did some more calculations, and it appears you should be able to sample anything as high as G10 at least. your sample size would be about 2, but i don't know if the emu will let you set such a small size of a loop. but like we could hear that sample anyway.

like i said, this is kind of nothing but a theory right now. since i haven't tried it out. but i am almost certian this should work. you should be able to take a sample, view it in a spectal analyzer and see the lowest frequency, this should be the fundemental, and from that do the simple arthmatic to get your loop size. and this should work for anything, even something that is out of tune. all you need is the number of waves per second and to sample at 44.1 and you should get a perfect loop every time.

a little bit more before i go to bed... if you sample at 48 like you can on the emu, you would have to set the loop size at 109.090909 blah blah blah. and even if we could sample at 96, you still would have inaccurate loop points. it looks like here your loop size would be 218.181818 and so on.

sorry for the long post, but i think this is worth it and will be useful to all of you using your samplers as synths :grin:

PostPosted: Sat Sep 13, 2003 4:17 pm
by MindMech
The way to get a perfect loop is to look at the beginning and ending of each waveform, zoom in, and set the start and end points to the same place.

And don't trust the E-Mu to interpolate all the way up and down the keyboard. It can't do it very well. You *need* to take more than one sample and split up the keyboard or you will get clicking and other artifacts.

PostPosted: Sat Sep 13, 2003 4:37 pm
by sampleandhold
yeah... i have heard some different sounds at high registers, but i can't tell if it is an artifact or perhaps that munson curve thing.

see the point was that i had set the loop points doing what you said looking and listening, and then i found that i was out of tune on other tones. then when i ran them all with a loop size of 100, looping about 44 cycles, i got all my test tones in tune, and i didn't have to look and test and look and bump. it all worked and looped perfectly. seriously you guys should give it a shot.

and in actual reality the best way to sample the test tones would be to sample every other note. i guess that is the way one would get the best possible sounding piano sample. but we can't, and i haven't really noticed too much in the way of artifacts with my other method, and this one. no clicking and nothing that i dont see as artifacts. but i don't go up that high on the reg any way.

it was just an idea to help people get their loops sorted faster.

PostPosted: Sun Sep 14, 2003 3:44 am
by lost_sound
if you go to sample edit menu and select tools 1 (i think) and there is the sample rate convert menu and in there (this is all from memory and not looking at the unit)there is a sample rate calculator witch does the same math as you just explaind and you can specify what note you sampled ,and what sample rate, and and boom it spits out the number of samples it will take to make a perfect single cycle loop for that pitch sample.


lost_sound