Hi,
not related to the thread on smoother audio in Pd, I am struggling with doing a smooth loop player for data stored in tables.
One building block for this is attached: It is a simple tabread4~ lookup that should loop over a configurable section of a table and play it back with various frequencies. As you'll easily see, I use a
[phasor~] | [*~ loopsize] | [+~ loopstart] | [tabread4~ table]
idiom here. Now I would like to avoid enveloping the rewind sections, so I built an elaborate mechanism to set the loop points as good as possible by hand. Test sections let you load a sample or try to find the smooth loop points inside of a sine-wave table graphically.
Now my problem is, that even when I have found a nice and smooth sounding loop section, as soon as I start to change the frequency played (with the "pd transpose" things), the sound gets very distorted.
I'm puzzled: Shouldn't the tabread4~ interpolate correctly in this case? Any help or explanation is appreciated. (Except anything involving crossfades: I know I could do that and I guess I also know how.)
Frank Barknecht Do You RjDj.me? _ ______footils.org__
As I understand and as Matt already wrote, you wanted a transposition of the phasor~'s frequency (which would change the frequency of the loop but not the sample content), but instead you did the classic up/downsampling-of-the-soundsample transposition. (The "distortion" you get is due to the difference in spectral content, which should be richer as you transpose upwards since you read a longer portion of the sample. Also, the end of the loop changes which could mean a harder discontinuity.)
I tried to fix the transposition and I also added an offset in the audio path before tabread4~ that corresponds to the beginning of the loop.
And I'm sure you've already figured everything out, long before you got our emails.
alabala
On 23 April 2010 20:27, Frank Barknecht fbar@footils.org wrote:
Hi,
not related to the thread on smoother audio in Pd, I am struggling with doing a smooth loop player for data stored in tables.
One building block for this is attached: It is a simple tabread4~ lookup that should loop over a configurable section of a table and play it back with various frequencies. As you'll easily see, I use a
[phasor~] | [*~ loopsize] | [+~ loopstart] | [tabread4~ table]
idiom here. Now I would like to avoid enveloping the rewind sections, so I built an elaborate mechanism to set the loop points as good as possible by hand. Test sections let you load a sample or try to find the smooth loop points inside of a sine-wave table graphically.
Now my problem is, that even when I have found a nice and smooth sounding loop section, as soon as I start to change the frequency played (with the "pd transpose" things), the sound gets very distorted.
I'm puzzled: Shouldn't the tabread4~ interpolate correctly in this case? Any help or explanation is appreciated. (Except anything involving crossfades: I know I could do that and I guess I also know how.)
Ciao
Frank Barknecht Do You RjDj.me? _ ______footils.org__
Pd-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
Hii Ypatios and Matt,
On Fri, Apr 23, 2010 at 10:49:19PM +0200, ypatios wrote:
As I understand and as Matt already wrote, you wanted a transposition of the phasor~'s frequency (which would change the frequency of the loop but not the sample content), but instead you did the classic up/downsampling-of-the-soundsample transposition.
...
I tried to fix the transposition and I also added an offset in the audio path before tabread4~ that corresponds to the beginning of the loop.
And I'm sure you've already figured everything out, long before you got our emails.
Yes, indeed, what a silly mistake: I was doing "timbre stretching" instead of transposition here. Thanks a lot for pointing me at this. I guess, the path to a higher state of consiousness sometimes requires to engage in public self-humiliation ... :)
Frank
On Sat, 2010-04-24 at 10:19 +0200, Frank Barknecht wrote:
I guess, the path to a higher state of consiousness sometimes requires to engage in public self-humiliation ... :)
The fact, that old Pd "rabbits" like you also have questions not only answers, is comforting. (even if they turn out to be not real questions ;-)
Roman
On Sat, Apr 24, 2010 at 11:32:52AM +0200, Roman Haefeli wrote:
The fact, that old Pd "rabbits" like you also have questions not only answers, is comforting. (even if they turn out to be not real questions ;-)
The more you learn, the more questions turn up. :)
Anyway back to the looping: With the fix, I can smoothly loop sine-waves now, but it still is pretty hard to get good looppoints for samples.
Here's an example soundfile: http://footils.org/snd/23.wav
With loopstart for example at sample 2912 and loopend at 5402, this looks pretty even in the array overlay, but if you listen to it, you can still hear a nasty rumble. I wonder, how to get rid of this ...
Frank Barknecht Do You RjDj.me? _ ______footils.org__
Hi :-)
Here's an example soundfile: http://footils.org/snd/23.wav
With loopstart for example at sample 2912 and loopend at 5402, this looks pretty even in the array overlay, but if you listen to it, you can still hear a nasty rumble. I wonder, how to get rid of this ...
I thing this is due to the loop's frequency? With transposition 0 you get about 17-18 Hz. As you transpose lower it should sound smoother but at higher rates the loop frequency is heard as a pitched sound. The problem is that a crossfade wouldn't really help here and I don't know any other solution (maybe filtering, but.....).
alabala
Anyway back to the looping: With the fix, I can smoothly loop sine-waves now,
Oh, and as for the sinewaves, if you set the loop start and end points at exactly the beginning and ending of one period, then the loop frequency is the same as the frequency of the actual content of the soundsample, thus making the sound smooth, but also louder? (haven't tested this..)
alabala
On Sat, 24 Apr 2010, Roman Haefeli wrote:
The fact, that old Pd "rabbits" like you also have questions not only answers, is comforting. (even if they turn out to be not real questions ;-)
In what manner is it comforting ?
(yes, that's a question, not an answer.)
_ _ __ ___ _____ ________ _____________ _____________________ ... | Mathieu Bouchard, Montréal, Québec. téléphone: +1.514.383.3801