sullivan@harvard.ARPA (John Sullivan) (07/15/84)
Recently net.music has had some discussion of devices (Harmonizers) which will change the pitch but not the speed (or vice-versa) of a signal. Now of course this is impossible theoretically, but I can think of a couple of ways this might work in practice for limited bandwidth signals like most sound. For example, one could pick a time constant delta-t, and get fourier transforms of each interval of that length. Then these could be shifted in frequency space, and then transformed back. Of course they successive intervals would no longer match up right, but I suppose with an appropriate time constant (maybe ~.05 sec? We need it short enough to have essentially fixed frequency spectrum from one interval to the next, but long enough so we don't mess up bass notes.) it might work. Another way to do what really amounts to the same thing, but with less computation would be to sample the signal for short intervals (say delta-t=.05 sec long each) which either overlap slightly or have small gaps between them, depending on whether it is to be speeded up or slowed down. Then you can output these at a corrected rate so they just fit back to back. Is this how the devices actually work? Does anyone know the real time constant used? How do they avoid loud clicks going from one sampling period to the next? John M. Sullivan {allegra,ihnp4,decvax,genrad}!harvard!sullivan
simard@loral.UUCP (07/16/84)
[Do not write in this space] I am also interested in the technique by which Harmonizers and similar units achieve pitch and/or speed changes independently. I think this would be a general-interest item meriting a followup posting to the net. -- Ray Simard Loral Instrumentation, San Diego {ucbvax, ittvax!dcdwest}!sdcsvax!sdccsu3!loral!simard
dave@rocksvax.UUCP (Dave Sewhuk) (07/18/84)
You grab small chunks of audio sampled at rate X, throw away some of the samples. You buffer the samples up so that they can be played out at a steady, slower rate and record them at this slower rate. When you play back the recording, you use the normal rate, remember they were sampled originally at this rate so no pitch change, and you end up speeding up the audio rate without changing the pitch, due to the thrown away samples. This works well with voice because you can cleverly find the spaces and throw away more data in the spaces than in the voice. This makes the person talk more like the Federal Express guy. You always reduce the bandwidth going in thus keeping the process from making something from nothing. I heard an article using this technique on "All Things Considered" last year. They had Noel Adams read a poem that took 18 secs to read, compressed it such that it took only 10 sec to play back. Sounded like Noel was talking faster... My Yamaha CD-X1 uses that technique to acheive fast forward/reverse. You hear snips of music at the proper pitch, only much faster. You hear the snips when you take out too much data, which for fast forward is OK. As for independently changing pitch you use a balanced mixer and a low pass filter to to translate the baseband pitches to any other frequency you want. Audio goes in 1 port a signal generator in the other. If you set signal gen to 1Khz you translate all incoming frequencies 1Khz. Theory for this is found in any communications book and is the basis for AM broadcasting, only they use signal generator in the Mhz region. By using complex waves as the translate frequency you can make all the sci-fi voices you ever wanted to hear, great fun to do... Hope that clears up those operations. -- Dave arpa: Sewhuk.HENR@Xerox.ARPA uucp: {allegra,rochester,amd,sunybcs}!rocksvax!dave
simard@loral.UUCP (Ray Simard) (07/27/84)
Digital "harmonizers" work basically by sampling the input signal, storing the
signal in a memory buffer, while simultaneously outputing the signal at a
different rate. Some smarts are usually included so that when the output
pointer is at a zero crossing and about to overtake the input pointer, the
output pointer is reset to a previous zero crossing, thus eliminating the
glitch that occurs when the output pointer overtakes the input pointer. The
effect can be observed even without this zero-crossing matching however, as
I have used an 8080 and 8 bit a/d d/a converters to do some experimenting
with this technique. The buffer size I use is relatively small in this case,
512 to 1024 bytes.
This has the effect of 're-playing' the most recent completed wave in
order to make up for the fact that the playback is occuring faster than
the record.
I would have posted this message to the net, however we seem to be having
a problem with our mail system at this time and can only mail to specific
destinations. If you feel it might be useful, please post from your end.
Keith Doyle
{ucbvax,decvax}!trwrb!cadovax!keithd
>Per Keith's request, I have posted this to net.audio.
--
Ray Simard
Loral Instrumentation, San Diego
{ucbvax, ittvax!dcdwest}!sdcsvax!sdccsu3!loral!simard