Re: [PD] convolution using pd-vanilla
and it took me quite some time to figure it out :) 2014-05-06 10:55 GMT-03:00 Oli Larkin olilar...@googlemail.com: thanks everyone ... Alexandre that is just what i was looking for On 6 May 2014, at 06:09, Alexandre Torres Porres wrote: I did one and shared on the list you can check it at: https://drive.google.com/file/d/0B3AoiT0xk8fnNU9PRHdldVVFbU0/edit?usp=sharing 2014-05-05 16:41 GMT-03:00 katja katjavet...@gmail.com: Brute force time domain convolution for small kernel can be done with [fexpr~]. For zero phase filter kernels, fast convolution in Pd is relatively simple. Multiply real and imaginary part of the signal's spectrum with the filter's spectrum while using four times overlap and Hann windowing before FFT and after IFFT, and normalize. Pd's FFT routines assume x[0] at the start of the filter kernel, not at the center, so you have to rotate your zero phase filter kernel before taking it's Fourier Transform. Katja On Mon, May 5, 2014 at 8:49 PM, david medine dmed...@ucsd.edu wrote: For the FFT based convolution, you could easily modify the example patch I06.timbre.stamp.pd to do straight up convolution in the frequency domain. I wouldn't know how to do it in the time domain without an extern or a lot of painstaking work. It might be a nice thing to have, though. I can tell you, though, that the frequency domain method will out perform the time domain in terms of CPU usage. But, since you are windowing there will be a latency. Apart from that, the output is identical by both methods. y(n) = x(n) * g(n) Y(k) = X(k)G(k), y(n) = IDFT(Y(k)) where g(n) is the impulse response, X(k) is the discrete Fourier transform of x(n) and * is the convolution operation. On 05/05/2014 09:33 AM, Oli Larkin wrote: hi, is anyone aware of an example of both a brute force time domain (e.g. buffir~ in Max) and an FFT-based fast convolution patch in pd-vanilla? I would like to do a comparison of the two. Can be using a small IR, just for demo purposes. cheers, Oli ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] convolution using pd-vanilla
I did one and shared on the list you can check it at: https://drive.google.com/file/d/0B3AoiT0xk8fnNU9PRHdldVVFbU0/edit?usp=sharing 2014-05-05 16:41 GMT-03:00 katja katjavet...@gmail.com: Brute force time domain convolution for small kernel can be done with [fexpr~]. For zero phase filter kernels, fast convolution in Pd is relatively simple. Multiply real and imaginary part of the signal's spectrum with the filter's spectrum while using four times overlap and Hann windowing before FFT and after IFFT, and normalize. Pd's FFT routines assume x[0] at the start of the filter kernel, not at the center, so you have to rotate your zero phase filter kernel before taking it's Fourier Transform. Katja On Mon, May 5, 2014 at 8:49 PM, david medine dmed...@ucsd.edu wrote: For the FFT based convolution, you could easily modify the example patch I06.timbre.stamp.pd to do straight up convolution in the frequency domain. I wouldn't know how to do it in the time domain without an extern or a lot of painstaking work. It might be a nice thing to have, though. I can tell you, though, that the frequency domain method will out perform the time domain in terms of CPU usage. But, since you are windowing there will be a latency. Apart from that, the output is identical by both methods. y(n) = x(n) * g(n) Y(k) = X(k)G(k), y(n) = IDFT(Y(k)) where g(n) is the impulse response, X(k) is the discrete Fourier transform of x(n) and * is the convolution operation. On 05/05/2014 09:33 AM, Oli Larkin wrote: hi, is anyone aware of an example of both a brute force time domain (e.g. buffir~ in Max) and an FFT-based fast convolution patch in pd-vanilla? I would like to do a comparison of the two. Can be using a small IR, just for demo purposes. cheers, Oli ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] SOLVED!!! Re: pitch to voltage SOLVED!!!
I have no idea what the patch is doing either, but I was able to clean it a lot. many things that didn't need to be there cheers 2014-04-28 3:52 GMT-03:00 Simon Iten itensi...@gmail.com: roman, thanks for your inputs. i tried both fexpr and expr and sticked to fexpr at some point, don’t know why though. will change it back! (i remember reading that fexpr was more expensive but also more precise) to make the whole thing work with real world signals (bass guitar in my case) you have to add an adaptive filter in the beginning of the chain (which is very easy because you get the frequency information hehe…) this will filter out overtones and prevent octave jumping. thanks simon On 28 Apr 2014, at 08:39, Roman Haefeli reduz...@gmail.com wrote: That works very well. Good job and thanks for sharing! One minor thing jumped to my eye: Your patch uses some instances of [fexpr~] and all of them actually don't need [fexpr~] functionality. I experienced that [fexpr~] is quite expensive, which seems apparent considering it is designed for feedback algorithms. I don't know if [fexpr~] is also expensive when you use it not for feedbacks as your patch does. Anyway, you could replace them by likely less expensive [expr~] instances: [fexpr~ $x1=0] - [expr~ $v1=0] Roman On Mon, 2014-04-28 at 00:59 +0200, simon wrote: hey miller and list, find attached a version that works beautifully. it's a dirty hack without upsampling but it works extremly well. don't ask me why, i have no idea. thanks for all the help miller, really appreciate it! and thanks for pd in general :-) cheers, simon On Apr 27, 2014, at 8:59 PM, Simon Iten wrote: sorry this one went off-list :-) On 27 Apr 2014, at 19:05, simon itensi...@gmail.com wrote: sure, here is the version with biquad in a subpatch with a block opject to upsample. probably i'm doing something wrong, i just copied from the block help-patch. sinetosawtoothupsample.pd On Apr 27, 2014, at 5:48 PM, Miller Puckette wrote: Drat, I don't have any explanation for this... can you send me the patch again? cheers M On Sun, Apr 27, 2014 at 05:44:22PM +0200, simon wrote: hmm, changing change to biquad does also not work. i mean it does as long as i don't upsample in the subpatch. as soon as i change the block object i get square instead of pulses... On Apr 27, 2014, at 3:48 PM, Miller Puckette wrote: Actually I don't know where the change~ object is from - I've nver seen t before. I would just use biquad~ 0 0 1 -1 0 (assuming that change~ simply ubtracts the previous sample from teh current one as I guessed from the patch :) M On Sun, Apr 27, 2014 at 03:40:01PM +0200, Simon Iten wrote: ok tried to upsample the whole thing (after the osc~) and now change~ does nothing anymore… it just spits out the same square wave i feed in…clues? On 27 Apr 2014, at 13:05, Simon Iten itensi...@gmail.com wrote: crosspost! sorry about the noise. thanks for the inputs i will try to to this. not sure if i can. otherwise i will ask back if that’s ok! On 27 Apr 2014, at 13:03, Simon Iten itensi...@gmail.com wrote: so if i would measure at the peak of the sawtooth and would upsample inside the pd patch, i would get higher resolution, right? any ideas how i can measure at the peak? (using the rpole output on both samphold inputs does not work and delaying one of them is also not working) which i would highly recommend you try this method with your gk-3 equipped guitar (one for each string) since you only have to cover a two octave range per string the error is tolerable. (you can add an offset to make it fit) On 27 Apr 2014, at 12:56, Miller Puckette m...@ucsd.edu wrote: That is an excellent, witty way to measure pulse withs using only tilde obects - my hat's off to you. The methond only has limited accuracy since its measurement is in samples. For instance, a 1/2 cycle of a 440-hz. tone at 44.1 kHz is only 50 samples, so there's only 2% accuracy. That's about 1/3 of a half tone (30-ish cents) which would sound horribly out of tune. There's an alternative sine-to-sawtooth recipe described here: http://msp.ucsd.edu/Publications/icmc10.pdf This is the basis of my guitar processing patch, smeck, but should be more broadly useful. But it has its own limitations: the sawtooth you get out is wiggly if the input sn't a pure sinusoid. There's also the possibility of simply pitch tracking with sigmund~. Use a maximum frequency around 6000 and a maximum of 6 partals (default 50!) for best results. cheers M On Sun, Apr 27, 2014 at 11:27:33AM +0200, Simon Iten wrote: dear list, i have a strange problem with my “sinetosawtooth” patch. it is basically a version of the pitch to voltage conversion used in the old gr300 guitar synths from roland. i cut out all the clutter
Re: [PD] WG: Inverse bandpass filter
can;t remember where I saw about this, but check this link http://msp.ucsd.edu/techniques/v0.11/book-html/node141.html see the quote An easy and practical way to remove the zero-frequency component from an audio signal is to use a one-pole low-pass filter to extract it, and then subtract the result from the signal. The resulting transfer function is one minus the transfer function of the low-pass filter: doesn't it agree with what I said? cheers 2014-04-22 14:37 GMT-03:00 Robert Esler rob...@urbanstew.org: I could be wrong, but I don't think it's quite the same thing. I believe the signal would be out of phase negating many of the effects of the filter. I would recommend using [biquad~] and in pd-extended there is a [notch] object which takes care of the coefficients. This sounds much cleaner and more notch-like to my ear than subtracting the filtered output. There is an explanation in Miller's book if you like unit circle math: http://msp.ucsd.edu/techniques/latest/book-html/node144.html --- Message: 4 Date: Tue, 22 Apr 2014 01:59:07 -0300 From: Alexandre Torres Porres por...@gmail.com Subject: Re: [PD] WG: Inverse bandpass filter To: Ingo i...@miamiwave.com Cc: pd-list pd-list@iem.at Message-ID: caeasfmhd0hanlmv9vutcsqzjkzy69i7wmebqq+20s2riwya...@mail.gmail.com Content-Type: text/plain; charset=utf-8 isn't it just subtract the audio from the filtered output? I guess you can get inverse freq response just by that cheers 2014-04-18 17:21 GMT-03:00 Ingo i...@miamiwave.com: You could send the original signal in parallel and invert the phase by multiplying with -1. You might have to delay the original signal in case that the processed signal gets also delayed by one or more blocks. Ingo ___ Von: pd-list-boun...@iem.at [mailto:pd-list-boun...@iem.atpd-list-boun...@iem.at] Im Auftrag von AP Vague Gesendet: Freitag, 18. April 2014 18:49 An: pd-list@iem.at Betreff: [PD] Inverse bandpass filter Is there a simple way to make [bp~] or [vcf~] have an inverse function? To filter out, rather than pass a changing frequency value. Is the easiest way to do this with a combination of [lop~] and [hip~]? ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] WG: Inverse bandpass filter
could be, I know nothing really about it. But I think I've read something that stated so. And I also tried it and saw that you could inverse filters like that. cheers 2014-04-22 21:06 GMT-03:00 Robert Esler rob...@urbanstew.org: Though with DC you don't have the issue of phase. I'm not an expert in filter math, but I assume that by the time your filtered audio (assuming its not DC) gets subtracted by the [-~] object it is out of phase with the original signal. Moreover, I hear a distinct difference. Maybe I'm not conceiving your statement properly and perhaps this discussion has been about DC all along… Regards From: Alexandre Torres Porres por...@gmail.com Date: Tuesday, April 22, 2014 3:51 PM To: GCC rob...@urbanstew.org Cc: apva...@gmail.com, Ingo i...@miamiwave.com, pd-lista puredata pd-list@iem.at Subject: Re: [PD] WG: Inverse bandpass filter can;t remember where I saw about this, but check this link http://msp.ucsd.edu/techniques/v0.11/book-html/node141.html see the quote An easy and practical way to remove the zero-frequency component from an audio signal is to use a one-pole low-pass filter to extract it, and then subtract the result from the signal. The resulting transfer function is one minus the transfer function of the low-pass filter: doesn't it agree with what I said? cheers 2014-04-22 14:37 GMT-03:00 Robert Esler rob...@urbanstew.org: I could be wrong, but I don't think it's quite the same thing. I believe the signal would be out of phase negating many of the effects of the filter. I would recommend using [biquad~] and in pd-extended there is a [notch] object which takes care of the coefficients. This sounds much cleaner and more notch-like to my ear than subtracting the filtered output. There is an explanation in Miller's book if you like unit circle math: http://msp.ucsd.edu/techniques/latest/book-html/node144.html --- Message: 4 Date: Tue, 22 Apr 2014 01:59:07 -0300 From: Alexandre Torres Porres por...@gmail.com Subject: Re: [PD] WG: Inverse bandpass filter To: Ingo i...@miamiwave.com Cc: pd-list pd-list@iem.at Message-ID: caeasfmhd0hanlmv9vutcsqzjkzy69i7wmebqq+20s2riwya...@mail.gmail.com Content-Type: text/plain; charset=utf-8 isn't it just subtract the audio from the filtered output? I guess you can get inverse freq response just by that cheers 2014-04-18 17:21 GMT-03:00 Ingo i...@miamiwave.com: You could send the original signal in parallel and invert the phase by multiplying with -1. You might have to delay the original signal in case that the processed signal gets also delayed by one or more blocks. Ingo ___ Von: pd-list-boun...@iem.at [mailto:pd-list-boun...@iem.atpd-list-boun...@iem.at] Im Auftrag von AP Vague Gesendet: Freitag, 18. April 2014 18:49 An: pd-list@iem.at Betreff: [PD] Inverse bandpass filter Is there a simple way to make [bp~] or [vcf~] have an inverse function? To filter out, rather than pass a changing frequency value. Is the easiest way to do this with a combination of [lop~] and [hip~]? ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] WG: Inverse bandpass filter
isn't it just subtract the audio from the filtered output? I guess you can get inverse freq response just by that cheers 2014-04-18 17:21 GMT-03:00 Ingo i...@miamiwave.com: You could send the original signal in parallel and invert the phase by multiplying with -1. You might have to delay the original signal in case that the processed signal gets also delayed by one or more blocks. Ingo ___ Von: pd-list-boun...@iem.at [mailto:pd-list-boun...@iem.at] Im Auftrag von AP Vague Gesendet: Freitag, 18. April 2014 18:49 An: pd-list@iem.at Betreff: [PD] Inverse bandpass filter Is there a simple way to make [bp~] or [vcf~] have an inverse function? To filter out, rather than pass a changing frequency value. Is the easiest way to do this with a combination of [lop~] and [hip~]? ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] can vcf~ be obtained with biquad coefficients?
hi, this is the next thing on my list :) need to know if you can have biquad coeficients for the parameters of vcf~ So I know [vcf~] can be obtained with a [cpole~] object - though I didn't do it yet as I find it a bit hard to get to the coeficients from the vcf~ code. So, quick question, if you can get it with a [cpole~] object, does it mean you could do it with [biquad~] coeficients? I suppose so, but then, how exactly? I mean, if I have the coeficients of [cpole~], how do I get to [biquad~]'s? Thanks ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Edit / Text Editor - what's the use?
I meant the thing that you used to get from the edit menu, then Text Editor 2014-04-15 1:40 GMT-03:00 Billy Stiltner billy.stilt...@gmail.com: use [pointer] to traverse right click [text] or help browser-Pure Data/5. Reference/text-object.pd On Thu, Apr 3, 2014 at 2:28 PM, Alexandre Torres Porres por...@gmail.comwrote: Hi there, I see there's a new [text] object in Pd 0.45 that defines, opens and edits text. This raises some doubts about the Text Editor option in the Edit Menu. I never knew what it was for, and I'm still clueless. How do you use it? Is there any example around I missed? cheers ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] can [bp~] be obtained with biquad coefficients?
now trying to make [vcf~], that looks like a toughy... :P 2014-04-12 17:07 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Sam, 2014-04-12 at 03:45 -0300, Alexandre Torres Porres wrote: change the [fexpr~] to something like [fexpr~ $x[0] + ($f2 * $y[-1]) + ($f3 * $y[-2])] f*ck, I'll be damned, now my patch that implements [bp~] with [fexpr~] seems to work, it's attached. Thanks! That is great! I never really dug into that topic, but having it as a patch makes it more accessible I think, at least for me. Thanks for sharing. Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] can [bp~] be obtained with biquad coefficients?
change the [fexpr~] to something like [fexpr~ $x[0] + ($f2 * $y[-1]) + ($f3 * $y[-2])] f*ck, I'll be damned, now my patch that implements [bp~] with [fexpr~] seems to work, it's attached. Thanks! it's pretty easy to see that from the code you quoted I can't really see it from the code itself. And, well, remember I mentioned about the biquad code? { t_sample output = *in++ + fb1 * last + fb2 * prev; if (PD_BIGORSMALL(output)) output = 0; *out++ = ff1 * output + ff2 * last + ff3 * prev; prev = last; last = output; } Well, I made a silly confusion mistake and thought the first line was feedforward (and then equivalent to the bp~). But still, it could be it for all I can tell. How can you actually see wether is feedback or not? Anyway, the patch works and I can also make it on biquad, it's all attached. after all it's a resonating filter and therefore needs a feedback path. I wouldn't know about that, but that's how you convinced me you knew what you were talking about :) Thanks again 2014-04-11 16:46 GMT-03:00 volker böhm vbo...@gmx.ch: On 11.04.2014, at 16:48, Alexandre Torres Porres wrote: last and prev are the last two _output_ samples. i don't know fexpr~ very well, but it looks like you try to access the last _input_ samples. In [fexpr~] you can access input samples with $x variables and output samples with $y. So you're correct. I'm going for the input samples. But I did it because I believe last and prev in this formula are in fact about input samples. no, and it's pretty easy to see that from the code you quoted: t_sample output = *in++ + coef1 * last + coef2 * prev; *out++ = gain * output; prev = last; last = output; after all it's a resonating filter and therefore needs a feedback path. so it somehow has to take outgoing samples back in. So I feel pretty strong about getting this [fexpr~] right. Is there anything I did not take into consideration? yes, calculate coef1, coef2 and gain by using the formulas from the code, change the [fexpr~] to something like [ fexpr~ $x[0] + ($f2 * $y[-1]) + ($f3 * $y[-2]) ], (where $f2 and $f3 would be coef1 and coef2 resp.) apply the gain factor afterwards, and you are done. vb bp.pd Description: Binary data ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] [bp~] really equal to [vcf~]?
Hi there, who can confirm that both [bp~] and [vcf~] are exactly the really same thingy? The code looks quite different... Moreover, why the two outlets for vcf~? Help doesn't say anything. Thanks ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] can [bp~] be obtained with biquad coefficients?
there are incremnents to do still, but thanks :) 2014-04-12 9:25 GMT-03:00 patrice colet colet.patr...@free.fr: Le 12/04/2014 08:45, Alexandre Torres Porres a écrit : change the [fexpr~] to something like [fexpr~ $x[0] + ($f2 * $y[-1]) + ($f3 * $y[-2])] f*ck, I'll be damned, now my patch that implements [bp~] with [fexpr~] seems to work, it's attached. Thanks! thanks for the share, when I tried to implement filters with expr and biquad I haven't been able to get it working fully (some clics appeared when changing frequency)... Your implementation works very well in both cases, chapeau bas it's pretty easy to see that from the code you quoted I can't really see it from the code itself. And, well, remember I mentioned about the biquad code? { t_sample output = *in++ + fb1 * last + fb2 * prev; if (PD_BIGORSMALL(output)) output = 0; *out++ = ff1 * output + ff2 * last + ff3 * prev; prev = last; last = output; } Well, I made a silly confusion mistake and thought the first line was feedforward (and then equivalent to the bp~). But still, it could be it for all I can tell. How can you actually see wether is feedback or not? Anyway, the patch works and I can also make it on biquad, it's all attached. after all it's a resonating filter and therefore needs a feedback path. I wouldn't know about that, but that's how you convinced me you knew what you were talking about :) Thanks again 2014-04-11 16:46 GMT-03:00 volker böhm vbo...@gmx.ch: On 11.04.2014, at 16:48, Alexandre Torres Porres wrote: last and prev are the last two _output_ samples. i don't know fexpr~ very well, but it looks like you try to access the last _input_ samples. In [fexpr~] you can access input samples with $x variables and output samples with $y. So you're correct. I'm going for the input samples. But I did it because I believe last and prev in this formula are in fact about input samples. no, and it's pretty easy to see that from the code you quoted: t_sample output = *in++ + coef1 * last + coef2 * prev; *out++ = gain * output; prev = last; last = output; after all it's a resonating filter and therefore needs a feedback path. so it somehow has to take outgoing samples back in. So I feel pretty strong about getting this [fexpr~] right. Is there anything I did not take into consideration? yes, calculate coef1, coef2 and gain by using the formulas from the code, change the [fexpr~] to something like [ fexpr~ $x[0] + ($f2 * $y[-1]) + ($f3 * $y[-2]) ], (where $f2 and $f3 would be coef1 and coef2 resp.) apply the gain factor afterwards, and you are done. vb ___pd-l...@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [bp~] really equal to [vcf~]?
that's great to know, thanks! Let me just see if I get a bit of the theory. Can I get [vcf~] with just one [cpole~] object and the right coeficients? Cheers 2014-04-12 13:36 GMT-03:00 Miller Puckette m...@ucsd.edu: They're quite different. bp~ is the cheapest possible bandpass filter (as far as I know). vcf~ is a one-pole complex filter whose outputs are the real and imaginry parts. The real part may be used as a resonant bandpass filter and the imaginary as a resonant low-pass filter, but they can be combined to make other possibilities. It's possible to graph their frequency responses using the help patch H10.measurement.pd' in 3.audio.examples. cheers Miller On Sat, Apr 12, 2014 at 04:28:11AM -0300, Alexandre Torres Porres wrote: Hi there, who can confirm that both [bp~] and [vcf~] are exactly the really same thingy? The code looks quite different... Moreover, why the two outlets for vcf~? Help doesn't say anything. Thanks ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] can [bp~] be obtained with biquad coefficients?
last and prev are the last two _output_ samples. i don't know fexpr~ very well, but it looks like you try to access the last _input_ samples. In [fexpr~] you can access input samples with $x variables and output samples with $y. So you're correct. I'm going for the input samples. But I did it because I believe last and prev in this formula are in fact about input samples. And I still do. The reason being that I checked the code of other objects like [biquad~], and last and prev where names used both for input and output operations, the difference being that the math for the output operation was something like *out++ + coef1 * last + coef2 * prev instead of *in++ + coef1 * last + coef2 * prev (like bp~) . So I feel pretty strong about getting this [fexpr~] right. Is there anything I did not take into consideration? One way or another, input or output samples, seems pretty clear to me you could achieve [bp~] with [biquad~] coefficients. I think the tricky part now is getting to the coefficients and gain values. Cheers 2014-04-11 3:23 GMT-03:00 volker böhm vbo...@gmx.ch: On 11.04.2014, at 03:07, Alexandre Torres Porres wrote: hey, the code I sent only calculates the coeficients, but I left out an important part which is t_sample output = *in++ + coef1 * last + coef2 * prev; *out++ = gain * output; prev = last; last = output; This shows how the filter is done with those coefficients It's easy to implement this with [fexpr~], it goes something like: [fexpr~ $x + (coef1 * $x1[-1]) + (coef2 * $x1[-2])] last and prev are the last two _output_ samples. i don't know fexpr~ very well, but it looks like you try to access the last _input_ samples. vb ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Loading arrays with arbitrary wave forms
hey, I tried making mine a bit more understandable it works with any table size. Just set the size as the argument in the [table] object. This means it works with [tabosc4~] if you'd like, and it makes the extra 3 guard points correctively. The guard points thing and interpolation is a bit hard to grasp at first. Say you have 0-96 points, you need extra 3 points (1 in the beggining, 2 at the end) so it goes now from 0-99 and your original indexes are now from *1 to 97*. The first point (0) needs to be equal to the last one (97) and then the extra two points (98-99) must be equal to (1-2). What my patch does is get the table size and consider it has these extra points, so it writes the table values like sinesum does. In the example I'm doing a hann window and using it as an envelope, but you could do whatever. cheers 2014-04-10 8:45 GMT-03:00 IOhannes m zmölnig zmoel...@iem.at: On 04/09/2014 09:46 AM, IOhannes m zmoelnig wrote: [sin]| ah, there is no [sin] object, use [cos] instead. anyhow, the patch was not really meant to be be copied to your Pd instance, but to show how easy it is to do what you want. it basically consists of two three parts: #1 generate numbers 0..1023; i'm using [until] and a counter for this. for simplicity, the counter is not reset at the beginning, so it will only generate the correct numbers once (the next time you click on [1024(, it will instead generate numbers 1024..2047); adding a reset is simple enough. #2 normalize the numbers 0..1023 to something more useful, e.g. to 0..2pi (my code is bogus here, as it incorporates a deg2rad conversion without ever seeing deg values) and use these values as input to a function (in my example sin(x)+0.1*random()) #3 write the generated value into the table at the given index (the value from the counter) fgmrdsa IOhannes ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list interpolation.pd Description: Binary data ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] can [bp~] be obtained with biquad coefficients?
hey, the code I sent only calculates the coeficients, but I left out an important part which is t_sample output = *in++ + coef1 * last + coef2 * prev; *out++ = gain * output; prev = last; last = output; This shows how the filter is done with those coefficients It's easy to implement this with [fexpr~], it goes something like: [fexpr~ $x + (coef1 * $x1[-1]) + (coef2 * $x1[-2])] It's seems this formula can also be achieved done with biquad, which receives a list where the first two elements are the same coefficients. But it still doesn't seem it is as simple as that. Maybe there's also something regarding the gain of the filter or something. Hope the wizards can help me solve this Cheers 2014-04-09 14:20 GMT-03:00 Alexandre Torres Porres por...@gmail.com: I'd start with a look at the [bp~] source to see if you can extract some hints about how the filter is implemented. Anyway, this is what I got from the code. But I wasn't successful to extract biquad coefficients from it. I still assume it can be done. It says it's a 2-pole bandpass filter, so I understand you can get to it with biquad, cause biquad is 2-pole and 2-zero. It's just a matter to get rid of the zeros somehow. I was able to leave them with a vlue of 0, but didn't seem to do the job. thanks static t_float sigbp_qcos(t_float f) { if (f = -(0.5f*3.14159f) f = 0.5f*3.14159f) { t_float g = f*f; return (((g*g*g * (-1.0f/720.0f) + g*g*(1.0f/24.0f)) - g*0.5) + 1 ); } else return (0); } static void sigbp_docoef(t_sigbp *x, t_floatarg f, t_floatarg q) { t_float r, oneminusr, omega; if (f 0.001) f = 10; if (q 0) q = 0; x-x_freq = f; x-x_q = q; omega = f * (2.0f * 3.14159f) / x-x_sr; if (q 0.001) oneminusr = 1.0f; else oneminusr = omega/q; if (oneminusr 1.0f) oneminusr = 1.0f; r = 1.0f - oneminusr; x-x_ctl-c_coef1 = 2.0f * sigbp_qcos(omega) * r; x-x_ctl-c_coef2 = - r * r; x-x_ctl-c_gain = 2 * oneminusr * (oneminusr + r * omega); /* post(r %f, omega %f, coef1 %f, coef2 %f, r, omega, x-x_ctl-c_coef1, x-x_ctl-c_coef2); */ } 2014-04-08 22:21 GMT-03:00 Alexandre Torres Porres por...@gmail.com: I'd start with a look at the [bp~] source to see if you can extract some hints about how the filter is implemented. Done that, way out of my head. What I can deal with is wether I can get to it with biquad coefficients. thanks 2014-04-08 21:28 GMT-03:00 Bill Gribble g...@billgribble.com: The quick and dirty way is just to feed the filter white noise and plot the output signal's spectrum. Guaranteed to show the actual performance of the filter, and not somebody's idea of how it ought to be working. If you need a theoretical curve, I'd start with a look at the [bp~] source to see if you can extract some hints about how the filter is implemented. It may be quite easy to figure out the poles and zeros if the code is clear and/or documented. Good luck! Bill Gribble ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] can [bp~] be obtained with biquad coefficients?
well, here's an attempt to make bp out of [fexpr~] and... it did not work 2014-04-10 22:07 GMT-03:00 Alexandre Torres Porres por...@gmail.com: hey, the code I sent only calculates the coeficients, but I left out an important part which is t_sample output = *in++ + coef1 * last + coef2 * prev; *out++ = gain * output; prev = last; last = output; This shows how the filter is done with those coefficients It's easy to implement this with [fexpr~], it goes something like: [fexpr~ $x + (coef1 * $x1[-1]) + (coef2 * $x1[-2])] It's seems this formula can also be achieved done with biquad, which receives a list where the first two elements are the same coefficients. But it still doesn't seem it is as simple as that. Maybe there's also something regarding the gain of the filter or something. Hope the wizards can help me solve this Cheers 2014-04-09 14:20 GMT-03:00 Alexandre Torres Porres por...@gmail.com: I'd start with a look at the [bp~] source to see if you can extract some hints about how the filter is implemented. Anyway, this is what I got from the code. But I wasn't successful to extract biquad coefficients from it. I still assume it can be done. It says it's a 2-pole bandpass filter, so I understand you can get to it with biquad, cause biquad is 2-pole and 2-zero. It's just a matter to get rid of the zeros somehow. I was able to leave them with a vlue of 0, but didn't seem to do the job. thanks static t_float sigbp_qcos(t_float f) { if (f = -(0.5f*3.14159f) f = 0.5f*3.14159f) { t_float g = f*f; return (((g*g*g * (-1.0f/720.0f) + g*g*(1.0f/24.0f)) - g*0.5) + 1 ); } else return (0); } static void sigbp_docoef(t_sigbp *x, t_floatarg f, t_floatarg q) { t_float r, oneminusr, omega; if (f 0.001) f = 10; if (q 0) q = 0; x-x_freq = f; x-x_q = q; omega = f * (2.0f * 3.14159f) / x-x_sr; if (q 0.001) oneminusr = 1.0f; else oneminusr = omega/q; if (oneminusr 1.0f) oneminusr = 1.0f; r = 1.0f - oneminusr; x-x_ctl-c_coef1 = 2.0f * sigbp_qcos(omega) * r; x-x_ctl-c_coef2 = - r * r; x-x_ctl-c_gain = 2 * oneminusr * (oneminusr + r * omega); /* post(r %f, omega %f, coef1 %f, coef2 %f, r, omega, x-x_ctl-c_coef1, x-x_ctl-c_coef2); */ } 2014-04-08 22:21 GMT-03:00 Alexandre Torres Porres por...@gmail.com: I'd start with a look at the [bp~] source to see if you can extract some hints about how the filter is implemented. Done that, way out of my head. What I can deal with is wether I can get to it with biquad coefficients. thanks 2014-04-08 21:28 GMT-03:00 Bill Gribble g...@billgribble.com: The quick and dirty way is just to feed the filter white noise and plot the output signal's spectrum. Guaranteed to show the actual performance of the filter, and not somebody's idea of how it ought to be working. If you need a theoretical curve, I'd start with a look at the [bp~] source to see if you can extract some hints about how the filter is implemented. It may be quite easy to figure out the poles and zeros if the code is clear and/or documented. Good luck! Bill Gribble bp.pd Description: Binary data ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] can [bp~] be obtained with biquad coefficients?
Those bypass fiters oops, meant Those bandpass filters 2014-04-09 9:59 GMT-03:00 Alexandre Torres Porres por...@gmail.com: Hi, that is the way I'm pointing to. I know of those but it's a bit more complicated than that. Those bypass fiters have zero values of -1 and 1, while [bp~] has only pole values. So my question is if I can achieve [bp~] by only turning the zero values of -1 and 1 to 0. I actually tried it and it didn't seem to do the trick. Maybe I'm doing something wrong. I don't know. It'd solve my issue if I could have [bp~] as biquad coefficients. But if not, I'd need some guidelines on how to plot the frequency response in the same way as [filterview] or [mmb.filterplot] plot the biquad coefficients. Cheers 2014-04-09 8:30 GMT-03:00 Colet Patrice colet.patr...@free.fr: Le 09/04/2014 01:45, Alexandre Torres Porres a écrit : Hi there. I'm trying to find a way to plot the frequency response of [bp~]. Hello, I don't know if it helps, in ggee there are filter objects that are applying formula for biquad coefficients, it's easy to use those formula in expr and apply them to biquad object in vanilla. I know of patches that can plot from biquad coefficients, so it'd be great if I could get biquad coefficients from an input of frequency and Q. I see [bp~] is a 2 pole filter. So does it mean I can achieve it by zeroing out a bandpass filter made with [biquad~]? Cause I see people make bandpass filters with 2poles in biquad, but the zeros are at -1 and 1. I tried zero values of zero, but it didn't look to good to make me believe that's the same as [bp~]. I know of miller's example H10.measurement.pd, and compared to it, didn't seem to fit. Anyway, I wanted something that would plot [bp~] right away, not like the H10 example, which takes some time. But then, if we can't do it with biquad coefficients, I would need some guidelines to do it some other how. Thanks Cheers I know about filterview and patch ___pd-l...@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] can [bp~] be obtained with biquad coefficients?
Hi, that is the way I'm pointing to. I know of those but it's a bit more complicated than that. Those bypass fiters have zero values of -1 and 1, while [bp~] has only pole values. So my question is if I can achieve [bp~] by only turning the zero values of -1 and 1 to 0. I actually tried it and it didn't seem to do the trick. Maybe I'm doing something wrong. I don't know. It'd solve my issue if I could have [bp~] as biquad coefficients. But if not, I'd need some guidelines on how to plot the frequency response in the same way as [filterview] or [mmb.filterplot] plot the biquad coefficients. Cheers 2014-04-09 8:30 GMT-03:00 Colet Patrice colet.patr...@free.fr: Le 09/04/2014 01:45, Alexandre Torres Porres a écrit : Hi there. I'm trying to find a way to plot the frequency response of [bp~]. Hello, I don't know if it helps, in ggee there are filter objects that are applying formula for biquad coefficients, it's easy to use those formula in expr and apply them to biquad object in vanilla. I know of patches that can plot from biquad coefficients, so it'd be great if I could get biquad coefficients from an input of frequency and Q. I see [bp~] is a 2 pole filter. So does it mean I can achieve it by zeroing out a bandpass filter made with [biquad~]? Cause I see people make bandpass filters with 2poles in biquad, but the zeros are at -1 and 1. I tried zero values of zero, but it didn't look to good to make me believe that's the same as [bp~]. I know of miller's example H10.measurement.pd, and compared to it, didn't seem to fit. Anyway, I wanted something that would plot [bp~] right away, not like the H10 example, which takes some time. But then, if we can't do it with biquad coefficients, I would need some guidelines to do it some other how. Thanks Cheers I know about filterview and patch ___pd-l...@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Loading arrays with arbitrary wave forms
the tricky detail you'd have to think of, if you're planing to use [tabread4~], is that you need 3 extra points that are copies of existing points. The help file will tell you that. [tabosc4~], in extent, needs a power of 2 plus the 3 extra points. 2014-04-09 9:21 GMT-03:00 David dfket...@gmail.com: Thanks to everyone who replied, I'll try your suggestions when I get home tonight. David. ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Loading arrays with arbitrary wave forms
I made one that takes care of it, here you go it's just doing a hann window, but you tweak any way you want it :) 2014-04-09 11:52 GMT-03:00 David dfket...@gmail.com: Right, I think 'sinesum' takes care of that for you. I don't know if Tim's example takes care of that or not. Thanks again. On Wed, Apr 9, 2014 at 10:36 AM, Alexandre Torres Porres por...@gmail.com wrote: the tricky detail you'd have to think of, if you're planing to use [tabread4~], is that you need 3 extra points that are copies of existing points. The help file will tell you that. [tabosc4~], in extent, needs a power of 2 plus the 3 extra points. 2014-04-09 9:21 GMT-03:00 David dfket...@gmail.com: Thanks to everyone who replied, I'll try your suggestions when I get home tonight. David. ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list Wavetables.pd Description: Binary data ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Loading arrays with arbitrary wave forms
and I'm using it for an envelope... 2014-04-09 12:42 GMT-03:00 Alexandre Torres Porres por...@gmail.com: I made one that takes care of it, here you go it's just doing a hann window, but you tweak any way you want it :) 2014-04-09 11:52 GMT-03:00 David dfket...@gmail.com: Right, I think 'sinesum' takes care of that for you. I don't know if Tim's example takes care of that or not. Thanks again. On Wed, Apr 9, 2014 at 10:36 AM, Alexandre Torres Porres por...@gmail.com wrote: the tricky detail you'd have to think of, if you're planing to use [tabread4~], is that you need 3 extra points that are copies of existing points. The help file will tell you that. [tabosc4~], in extent, needs a power of 2 plus the 3 extra points. 2014-04-09 9:21 GMT-03:00 David dfket...@gmail.com: Thanks to everyone who replied, I'll try your suggestions when I get home tonight. David. ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] can [bp~] be obtained with biquad coefficients?
I'd start with a look at the [bp~] source to see if you can extract some hints about how the filter is implemented. Anyway, this is what I got from the code. But I wasn't successful to extract biquad coefficients from it. I still assume it can be done. It says it's a 2-pole bandpass filter, so I understand you can get to it with biquad, cause biquad is 2-pole and 2-zero. It's just a matter to get rid of the zeros somehow. I was able to leave them with a vlue of 0, but didn't seem to do the job. thanks static t_float sigbp_qcos(t_float f) { if (f = -(0.5f*3.14159f) f = 0.5f*3.14159f) { t_float g = f*f; return (((g*g*g * (-1.0f/720.0f) + g*g*(1.0f/24.0f)) - g*0.5) + 1); } else return (0); } static void sigbp_docoef(t_sigbp *x, t_floatarg f, t_floatarg q) { t_float r, oneminusr, omega; if (f 0.001) f = 10; if (q 0) q = 0; x-x_freq = f; x-x_q = q; omega = f * (2.0f * 3.14159f) / x-x_sr; if (q 0.001) oneminusr = 1.0f; else oneminusr = omega/q; if (oneminusr 1.0f) oneminusr = 1.0f; r = 1.0f - oneminusr; x-x_ctl-c_coef1 = 2.0f * sigbp_qcos(omega) * r; x-x_ctl-c_coef2 = - r * r; x-x_ctl-c_gain = 2 * oneminusr * (oneminusr + r * omega); /* post(r %f, omega %f, coef1 %f, coef2 %f, r, omega, x-x_ctl-c_coef1, x-x_ctl-c_coef2); */ } 2014-04-08 22:21 GMT-03:00 Alexandre Torres Porres por...@gmail.com: I'd start with a look at the [bp~] source to see if you can extract some hints about how the filter is implemented. Done that, way out of my head. What I can deal with is wether I can get to it with biquad coefficients. thanks 2014-04-08 21:28 GMT-03:00 Bill Gribble g...@billgribble.com: The quick and dirty way is just to feed the filter white noise and plot the output signal's spectrum. Guaranteed to show the actual performance of the filter, and not somebody's idea of how it ought to be working. If you need a theoretical curve, I'd start with a look at the [bp~] source to see if you can extract some hints about how the filter is implemented. It may be quite easy to figure out the poles and zeros if the code is clear and/or documented. Good luck! Bill Gribble ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] can [bp~] be obtained with biquad coefficients?
Hi there. I'm trying to find a way to plot the frequency response of [bp~]. I know of patches that can plot from biquad coefficients, so it'd be great if I could get biquad coefficients from an input of frequency and Q. I see [bp~] is a 2 pole filter. So does it mean I can achieve it by zeroing out a bandpass filter made with [biquad~]? Cause I see people make bandpass filters with 2poles in biquad, but the zeros are at -1 and 1. I tried zero values of zero, but it didn't look to good to make me believe that's the same as [bp~]. I know of miller's example H10.measurement.pd, and compared to it, didn't seem to fit. Anyway, I wanted something that would plot [bp~] right away, not like the H10 example, which takes some time. But then, if we can't do it with biquad coefficients, I would need some guidelines to do it some other how. Thanks Cheers I know about filterview and patch ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] can [bp~] be obtained with biquad coefficients?
I'd start with a look at the [bp~] source to see if you can extract some hints about how the filter is implemented. Done that, way out of my head. What I can deal with is wether I can get to it with biquad coefficients. thanks 2014-04-08 21:28 GMT-03:00 Bill Gribble g...@billgribble.com: The quick and dirty way is just to feed the filter white noise and plot the output signal's spectrum. Guaranteed to show the actual performance of the filter, and not somebody's idea of how it ought to be working. If you need a theoretical curve, I'd start with a look at the [bp~] source to see if you can extract some hints about how the filter is implemented. It may be quite easy to figure out the poles and zeros if the code is clear and/or documented. Good luck! Bill Gribble ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Loading arrays with arbitrary wave forms
just - think of the table size you want. - get its period in seconds, or better, its frequency, according to the sample rate - use this frequency as the frequency of [phasor~], going from 0 to 1 (be careful to set the starting phase as zero, as well) - make [phasor~] feed whatever crazy idea and mathematical function you bum into, like sin(sin(x) * pi) or sin(x) ^ 3, put that into an [expr~] there you go 2014-04-08 21:41 GMT-03:00 David dfket...@gmail.com: Hi! Is there some way to fill an array (table) with an arbitrary wave form programatically? I know I can use sinesum or cosinesum to generate sums of sinusoidal wave forms, and in theory any periodic waveform can be generated this way. But I want to generate wave forms using more complicated trigonometric expressions, for example sin(sin(x) * pi) or sin(x) ^ 3. I'm not sure what they would sound like (which is what motivates me to try), or if there's some way to transform these expressions to use only sinesum or cosinesum (my knowledge of math is somewhat limited). Any suggestions on how I could do that in Pure Data? I could create an audio file using some other software tool and then load it into Pure Data, but I'd like to know if there's some way to do it directly in PD. Thanks. ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] [bag] as sustain pedal
hi there, I saw thia vanilla [bag] object, and it says it can be used as sustain, but I just couldn't see how. any examples around? cheers ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [bag] as sustain pedal
thing is that it forgets if it receives a note off, so maybe it needs [stripnote] to don't let note offs go through 2014-04-04 6:57 GMT-03:00 tim vets timv...@gmail.com: for remembering the note-off's to be [flush( -ed when the pedal is released? 2014-04-04 10:40 GMT+02:00 Alexandre Torres Porres por...@gmail.com: hi there, I saw thia vanilla [bag] object, and it says it can be used as sustain, but I just couldn't see how. any examples around? cheers ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [bag] as sustain pedal
maybe it needs [stripnote] done it that way :) 2014-04-04 11:47 GMT-03:00 Alexandre Torres Porres por...@gmail.com: thing is that it forgets if it receives a note off, so maybe it needs [stripnote] to don't let note offs go through 2014-04-04 6:57 GMT-03:00 tim vets timv...@gmail.com: for remembering the note-off's to be [flush( -ed when the pedal is released? 2014-04-04 10:40 GMT+02:00 Alexandre Torres Porres por...@gmail.com: hi there, I saw thia vanilla [bag] object, and it says it can be used as sustain, but I just couldn't see how. any examples around? cheers ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [qlist] and locality
* when you run into nameclashes, you know your project has outgrown Pd and it's time to choose another language what's a nameclash? (maybe I haven't outgrown Pd yet) 2014-04-03 13:00 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: On 04/03/2014 04:00 AM, IOhannes m zmoelnig wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA256 On 2014-04-03 03:05, Alexandre Torres Porres wrote: [...] btw: i would probably even recommend to use explicit *connections* (rather than send/receive pairs) for anything local. then you never have the problem of [qlist] and locality - very simple and forces you to think about your object interfaces. I would also recommend only using global receive-symbols when you have to use them. That way: * your patches are more readable * no need to feed $0 to message boxes * when you run into nameclashes, you know your project has outgrown Pd and it's time to choose another language -Jonathan fgmasdr IOhannes -BEGIN PGP SIGNATURE- Version: GnuPG v1 Comment: Using GnuPG with Icedove - http://www.enigmail.net/ iQIcBAEBCAAGBQJTPRULAAoJELZQGcR/ejb4NioP/0Kyyz4MA+Tqq8890uEHGj9Z FZHEo5z/idBj7Z+WmAHrEipkIW70pnVBB4bVzC8owgV66AQZBuEqXMeJcIpu3MXK ULvsvxcFcoY9YH7hbJAF+mlDFvbh1CXcVbvEChZ8y5rz0XekSMf+//qUfJSlKTWX GXjJzw8s42yfSpVJYBjEh6fBFzlk2foLRFPFXaR6Cbj+Y7aNEiW//+Vim3nOzleT 6azYe0leLabir72nnWIKGahnT2GXgWkgxu6L//nTgsBYOa1COUoKOh44wvBbMSoW lbLduDY5drxJbyISGoZdsuailriv1xMGIkiSwTw4WSwVWBj2kv5MgoHC09ugqtLe bVHrizcP09+VUz20y8IMnXrRRgj8AU8Z+9xzZIzf9PV3U15zSlRqwZSFIwMCuhYs CeRqxtDFVsB/PARQoCys/B4QDjAszBPE2VC1xKSelBMjyGbvPyZA7uq/R199zLCy WMp0uu0+Q6WKa/zIB+sphLlifnXjYYXJaCGZNOzign1EJLOnBvOY/4zgE3bHtx9r FIlSFSMo6BrYjOEJvh/MxF90TawI/aCQ/MbEea0+finxJi2jp2PnMom+QbCvjfBa zLh8hlNP0tLp21Jo1ydzu0/vYb9mEzMQtpEv9lqrde0INcEKL9TaswFGf5TXyM7h JeTnSBV0Th0CjQER9Gik =oC+u -END PGP SIGNATURE- ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/ listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/ listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [qlist] and locality
Oops, I'll be dammed, but [text] doesn't seem to handle $0 in the same way. Although it looks like a super [qlist], giving [text] a $0 for an address symbol, such as $0-test1, turns it into 0-test1... so no deal for it. I'm assuming it's not supposed to be something regarding an object design. As with [qlist] and [textfile], the issue is related to the way Pd doesn't handle $0 in messages. So unless it eventually does, I guess that the only thing left to do is to find some workarounds as discussed here. note that i'm not saying that this could not be done more conveniently on the Pd side. i'm only saying that you can build things yourself that do (more or less) what you want to do. and it's not that hard to create your own little set of helpers that do what you want (though probably not what I want) I get that, and I'm actually cool with the philosophy. The reason I insist is aimed to Pd's functionality as a whole, and I only mention one thing or another after giving it a good deal of thought and really believing it'd be a better user experience for other people. Specially beginners. Actually, lots of this issues come up for me when I'm preparing patches for classes. And I'm also writing extensive documentation for Pd. So when I hit this issues I think of the students and all the people I want to lure into Pd, selling it as a very simple and fucntional environment. Bur for example, now I'm teaching how to do sequencing, and I'd like to say that it just works if anyone needs [qlist] to send local messages. It's bad to not mention some limitations or to mention them and spend a lot of time on some clumsy workarounds to avoid them. And for having taught Pd a lot, the $0 thing in messages is always something that stands out for some working around. It's fine by me, I'm just thinking of newcomers having to grasp these details, when I wonder if it all could just be solved internally on the way Pd is programmed to deal with messages. I assume I have no idea of the hassles involved, but I have the idea that there must be a few options to solve this. It can't be impossible. Well, one way or another, this is just a humble opinion. It's my two cents on the subject. I don't see any problem emerging from the capability of messages inheriting $0, and it'd be totally backwards compatible to older patches. Moeover, [qlist] and [text] could send messages to local receives. cheers 2014-04-03 13:45 GMT-03:00 Alexandre Torres Porres por...@gmail.com: Miller proposed to use the new [text] class introduced in 0.45 Oh I see, didn't know about it. It really seems like it's the option for more flexibility than [qlist] can handle. Will try it out. cheers 2014-04-03 3:38 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Wed, 2014-04-02 at 20:49 -0300, Alexandre Torres Porres wrote: By the way, haven't been really able to make it work well with [textfile]. If you get a symbol with $0-symbol from a text file, you can't use it to work as an address for [send]. Miller proposed to use the new [text] class introduced in 0.45, not the old [textfile]. I haven't checked myself, but according to him this would solve all your trouble as it allows - if I understand correctly - to take literal $0 strings that get expanded only at reading time. (Is that what you meant, Miller?) Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] Edit / Text Editor - what's the use?
Hi there, I see there's a new [text] object in Pd 0.45 that defines, opens and edits text. This raises some doubts about the Text Editor option in the Edit Menu. I never knew what it was for, and I'm still clueless. How do you use it? Is there any example around I missed? cheers ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [qlist] and locality
thanks for explaining it all imagine trying to design something like that which is also backwards compatible with the crude namespacing tools that already exist in Pd. It's not possible ok, here's where I'm a bit confuse. You're not saying it'd be impossible to make messages inherit the $0 value, are you? As I don't see I'll be able to grasp the details for now, I'll just take your word for it :) cheers 2014-04-03 15:52 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: For example, if you have two help patches open and each has an array inside it named array1. One of the help patches will work, and the other won't. That's because Put menu arrays assume you only have one array by that name. Pd will use the first one it finds (probably the first one you create) and the duplicate will be ignored. In the case of arrays you'll get a warning, because you're not supposed to use the same name twice. But with the send/receive classes (as well as many other objects that use pd_bind) you can have many s/r pairs sharing the same name. So suppose you have [s loop] and [r loop] in a subpatch, and [s loop] and [r loop] in an unrelated subpatch. Are those s/r pairs supposed to communicate with each other? Or... Did the author forget he/she already used the name loop for the first s/r pair and doesn't actually want the other s/r pair to communicate with the first? If the answer to the second question is yes, then that's an example of a nameclash. Pd doesn't give you a way to tell the difference. Most programming languages have clear and sensible ways to avoid this. There's even a Pd external to do it-- I think it's called [sendlocal] and [receivelocal]-- but its author erroneously thought that $0 deprecates those objects. Pd gurus on the list can give you seemingly simple workarounds for these problems with scope and nameclashes, but as you the programmer accumulate them it gets more and more unwieldy. Worse, it makes it difficult to read patches, as you must spend time decoding someone else's idiosyncratic use of [makefilename] or whatever they are doing to get Pd to do what is concise, consistent and robust in nearly every other modern programming language. Finally-- and again-- these problems cannot be improved in Pd without breaking some backwards compatibility. Just take the related issue of namespaces with external libraries-- it's hard enough to design and test something robust like Python's namespacing. Now imagine trying to design something like that which is also backwards compatible with the crude namespacing tools that already exist in Pd. It's not possible, and that means as long as people imagine Pd Vanilla as the core Pd $0 hackery is the only way to simulate scoping. -Jonathan On Thursday, April 3, 2014 12:35 PM, Alexandre Torres Porres por...@gmail.com wrote: * when you run into nameclashes, you know your project has outgrown Pd and it's time to choose another language what's a nameclash? (maybe I haven't outgrown Pd yet) 2014-04-03 13:00 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: On 04/03/2014 04:00 AM, IOhannes m zmoelnig wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA256 On 2014-04-03 03:05, Alexandre Torres Porres wrote: [...] btw: i would probably even recommend to use explicit *connections* (rather than send/receive pairs) for anything local. then you never have the problem of [qlist] and locality - very simple and forces you to think about your object interfaces. I would also recommend only using global receive-symbols when you have to use them. That way: * your patches are more readable * no need to feed $0 to message boxes * when you run into nameclashes, you know your project has outgrown Pd and it's time to choose another language -Jonathan fgmasdr IOhannes -BEGIN PGP SIGNATURE- Version: GnuPG v1 Comment: Using GnuPG with Icedove - http://www.enigmail.net/ iQIcBAEBCAAGBQJTPRULAAoJELZQGcR/ejb4NioP/0Kyyz4MA+Tqq8890uEHGj9Z FZHEo5z/idBj7Z+WmAHrEipkIW70pnVBB4bVzC8owgV66AQZBuEqXMeJcIpu3MXK ULvsvxcFcoY9YH7hbJAF+mlDFvbh1CXcVbvEChZ8y5rz0XekSMf+//qUfJSlKTWX GXjJzw8s42yfSpVJYBjEh6fBFzlk2foLRFPFXaR6Cbj+Y7aNEiW//+Vim3nOzleT 6azYe0leLabir72nnWIKGahnT2GXgWkgxu6L//nTgsBYOa1COUoKOh44wvBbMSoW lbLduDY5drxJbyISGoZdsuailriv1xMGIkiSwTw4WSwVWBj2kv5MgoHC09ugqtLe bVHrizcP09+VUz20y8IMnXrRRgj8AU8Z+9xzZIzf9PV3U15zSlRqwZSFIwMCuhYs CeRqxtDFVsB/PARQoCys/B4QDjAszBPE2VC1xKSelBMjyGbvPyZA7uq/R199zLCy WMp0uu0+Q6WKa/zIB+sphLlifnXjYYXJaCGZNOzign1EJLOnBvOY/4zgE3bHtx9r FIlSFSMo6BrYjOEJvh/MxF90TawI/aCQ/MbEea0+finxJi2jp2PnMom+QbCvjfBa zLh8hlNP0tLp21Jo1ydzu0/vYb9mEzMQtpEv9lqrde0INcEKL9TaswFGf5TXyM7h JeTnSBV0Th0CjQER9Gik =oC+u -END PGP SIGNATURE- ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/ listinfo/pd-list ___ Pd-list@iem.at mailing
Re: [PD] [qlist] and locality
Wow, you keep beating that horse after its dead for quite a while by now I don't think this debate is going lead anywhere please, cope with my lack of knowledge in computer science/languages jargons. All I'm doing is asking to learn more about it and get what you guys mean. I'm not debating, since I'm even stating I couldn't do it when I say I probably won't be able to grasp all the details and will just take the word for it... So relax, you keep misjudging before reading more carefully. I'm not looking for a debate, and I'm also saying I'm cool with Pd's workaround myself, so there's no personal frustration. As I said, I'm not even thinking about me as my concerns come from luring people into using Pd, while I'm already sold for it. Anyway, having said that, I'd appreciate if anyone could help me understand Pd's structure and developing issues. For instance, I don't think I understand what inconsistencies mean in this context. cheers 2014-04-03 17:03 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Don, 2014-04-03 at 16:13 -0300, Alexandre Torres Porres wrote: thanks for explaining it all imagine trying to design something like that which is also backwards compatible with the crude namespacing tools that already exist in Pd. It's not possible ok, here's where I'm a bit confuse. You're not saying it'd be impossible to make messages inherit the $0 value, are you? Wow, you keep beating that horse after its dead for quite a while by now. It is _not_at_all_ about technical difficulties (probably it is indeed difficult, I don't really know). It's about breaking consistency. Expanding arguments of the parent is different from expanding to elements of incoming messages. While I understand your frustration to some degree, I don't think this debate is going lead anywhere, simply because of that fact that I don't believe any dev will deliberately introduce inconsistencies just for the sake of convenience. And yes, I understand the convenience of $0 expanding to the canvas-local ID and yes, it would probably make patching simpler. I am very much with you in this respect. Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [qlist] and locality
Hi Jonathan, I like it too, and the pedagogical concern is what gets me the most. I find new users to be reluctant to the clunkiness. Had never heard of the Nova system, is it available somewhere? Seems it's not built on the core of Pd anyway, right? thanks 2014-04-03 19:03 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: On 04/03/2014 03:13 PM, Alexandre Torres Porres wrote: thanks for explaining it all imagine trying to design something like that which is also backwards compatible with the crude namespacing tools that already exist in Pd. It's not possible ok, here's where I'm a bit confuse. You're not saying it'd be impossible to make messages inherit the $0 value, are you? I don't know how difficult such a change is. I assume something in Pd's parser would need to be changed. I can't remember if the code responsible for parsing a msg box message even knows where the message got sent from-- seems ike it doesn't since I can't find last error on msg-box parsing errors (like an out-of-range dollarsign variable). What I'm saying is that even with a canvas $0 inside message boxes Pd's scope system is still way too clunky. You still don't get straightforward subpatch-locality, nor nested-abstraction locality. I think Tim Blechmann's Nova system did both, and Ivica's [preset_hub] and [preset_node] get the latter (though I don't think it does global scope). Both work perfectly fine with no $0 at all. The pedagogical benefit is enormous-- new users can get the scope they want without having to learn or think about what a dollarsign variable is, or how string concatenation works. In the case of [preset_hub], just creating the object sets the scope boundary almost certainly to what the user wants it to be. I like that. -Jonathan ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [qlist] and locality
not confusing, thanks 2014-04-03 19:54 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Don, 2014-04-03 at 18:32 -0300, Alexandre Torres Porres wrote: Wow, you keep beating that horse after its dead for quite a while by now I don't think this debate is going lead anywhere please, cope with my lack of knowledge in computer science/languages jargons. I'm sorry. I sure will (though I don't feel I have in any way less of a lack of knowledge). Actually, I don't have any computer science background myself. All I'm doing is asking to learn more about it and get what you guys mean. I'm not debating, since I'm even stating I couldn't do it when I say I probably won't be able to grasp all the details and will just take the word for it... So relax, you keep misjudging before reading more carefully. I'm not looking for a debate, and I'm also saying I'm cool with Pd's workaround myself, so there's no personal frustration. As I said, I'm not even thinking about me as my concerns come from luring people into using Pd, while I'm already sold for it. Anyway, having said that, I'd appreciate if anyone could help me understand Pd's structure and developing issues. I think I can't answer that. For instance, I don't think I understand what inconsistencies mean in this context. I try to explain some more. The confusion probably comes from the fact, that a similar looking syntax is used for two relatively different things in Pd. A $1 in an object box is substituted by the first argument I give to the parent abstraction. If I create [myabs 0.3] and myabs contains an [f $1], the value of $1 actually is '0.3'. If I have a message box [bla $1( in the same abstraction [myabs], we actually don't know yet what the value of this $1 is. Only when we send message to [bla $1( we know what the value of $1. [1.7( | [bla $1( When I click the [1.7( message box, we know that the $1 in [bla $1( is going to be substituted by 1.7. So far, so good. We now have encountered two different $1s in the same abstraction. Once it got substituted by 0.3 and once by 1.7, although both are written $1. Confusing, isn't it? I know that is nothing new to you at all as you most likely have used dollar variables in both ways already. What I am trying to say is that a $1 in a message box [bla $1( is a different animal from a $1 in an object box [f $1]. Pd could have been designed to make this distinction more explicit. It could have used # variables for message boxes and $ variables for object boxes. Then we would be able to do both with message boxes, namely expanding to a parent's argument AND expanding to an element of the incoming message, depending on whether we use the # or the $ syntax. [1.7( | [bla #1( In our hypothetical Pd, #1 would be substituted by '1.7' as soon as we click the [1.7( message box (as does $1 in the real Pd). Clicking on [1.7( would output 'bla 1.7'. [1.7( | [bla $1( In our hypothetical Pd, $1 would hold the value of the first argument given to the parent abstraction [myabs 0.3], in our example '0.3'. Clicking the [1.7( message box would output a message 'bla 0.3'. However, there is no such thing in the real Pd (yet). In the real Pd, the $1 in the message box works totally differently from the $1 in the object box. The canvas local-ID unique to each instance of a .pd file (abstraction or patch) can be considered as an argument to that abstraction or patch. Thus it can easily be accessed by $0 in object boxes. When you propose that $0s in message boxes are substituted by the canvas-local ID, then you want the function of the dollar variables to be different depending on what number follows the dollar sign. You want $0 to access an argument given to the parent, but $1 to be substituted by the first element of the incoming message. That is where the inconsistency happens: Why should the function be different based on the value I put after the dollar sign? In our hypothetical Pd, this would be a non-issue. You wouldn't expect a #0 in message box to get substituted by the canvas-local ID. You would use $0 for that. In the real Pd, we unfortunately don't have direct access to the arguments of the parent from message boxes. When you ask Why can't a $0 in a message box be substituted by the canvas-local ID, then you also should ask Why isn't a $1 in message box substituted by the first argument given to the parent? The answer is that this is the way Pd is designed. I'd prefer our hypothetical Pd, if it would exist. However, switching from today's Pd to our hypothetical Pd would surely break compatibility, which makes its introduction a bit less likely. Finally, I don't see any other concise solution than our hypothetical Pd for the $0-in-message-boxes problem. I hope I didn't cause even more confusion. Roman 2014-04-03 17:03 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Don, 2014-04-03
Re: [PD] [qlist] and locality
I almost meant that :) you still have to send [text sequence] the values of the $ variables you want to use (starting with $1). But the ability to instance-ize sequences is there. hmmm, are you pointing to a solution where I can send $0 to textfile and it would generate the number and do the trick? Gotta check this thing better. cheers 2014-04-03 20:10 GMT-03:00 Miller Puckette m...@ucsd.edu: I almost meant that :) you still have to send [text sequence] the values of the $ variables you want to use (starting with $1). But the ability to instance-ize sequences is there. cheers M On Thu, Apr 03, 2014 at 08:38:16AM +0200, Roman Haefeli wrote: On Wed, 2014-04-02 at 20:49 -0300, Alexandre Torres Porres wrote: By the way, haven't been really able to make it work well with [textfile]. If you get a symbol with $0-symbol from a text file, you can't use it to work as an address for [send]. Miller proposed to use the new [text] class introduced in 0.45, not the old [textfile]. I haven't checked myself, but according to him this would solve all your trouble as it allows - if I understand correctly - to take literal $0 strings that get expanded only at reading time. (Is that what you meant, Miller?) Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [qlist] and locality
I think I got it, will try as soon as a I can. I have to properly study this new object first anyway. If I got it, that looks like a workaround I thought about before, still thinking of [qlist], like storing all the sequence in the patch and then send it to [qlist], where I could get the patch $0 value and send it to it. Someting like that, right? I thought it was a bit of a hassle, then I reached the list. Maybe with [text] it could be easier. cheers 2014-04-03 20:59 GMT-03:00 Miller Puckette m...@ucsd.edu: Yeah - for instance use a [pack] object to get a list of $ substtution values into [text sequence] - then one of the arguments to [pcak] can be $0. cheers M On Thu, Apr 03, 2014 at 08:44:02PM -0300, Alexandre Torres Porres wrote: I almost meant that :) you still have to send [text sequence] the values of the $ variables you want to use (starting with $1). But the ability to instance-ize sequences is there. hmmm, are you pointing to a solution where I can send $0 to textfile and it would generate the number and do the trick? Gotta check this thing better. cheers 2014-04-03 20:10 GMT-03:00 Miller Puckette m...@ucsd.edu: I almost meant that :) you still have to send [text sequence] the values of the $ variables you want to use (starting with $1). But the ability to instance-ize sequences is there. cheers M On Thu, Apr 03, 2014 at 08:38:16AM +0200, Roman Haefeli wrote: On Wed, 2014-04-02 at 20:49 -0300, Alexandre Torres Porres wrote: By the way, haven't been really able to make it work well with [textfile]. If you get a symbol with $0-symbol from a text file, you can't use it to work as an address for [send]. Miller proposed to use the new [text] class introduced in 0.45, not the old [textfile]. I haven't checked myself, but according to him this would solve all your trouble as it allows - if I understand correctly - to take literal $0 strings that get expanded only at reading time. (Is that what you meant, Miller?) Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [qlist] and locality
HEY, I SEE HOW [text] WORKS NOW Awesome, you can easily send arguments to it. Perfect 2014-04-03 20:59 GMT-03:00 Miller Puckette m...@ucsd.edu: Yeah - for instance use a [pack] object to get a list of $ substtution values into [text sequence] - then one of the arguments to [pcak] can be $0. cheers M On Thu, Apr 03, 2014 at 08:44:02PM -0300, Alexandre Torres Porres wrote: I almost meant that :) you still have to send [text sequence] the values of the $ variables you want to use (starting with $1). But the ability to instance-ize sequences is there. hmmm, are you pointing to a solution where I can send $0 to textfile and it would generate the number and do the trick? Gotta check this thing better. cheers 2014-04-03 20:10 GMT-03:00 Miller Puckette m...@ucsd.edu: I almost meant that :) you still have to send [text sequence] the values of the $ variables you want to use (starting with $1). But the ability to instance-ize sequences is there. cheers M On Thu, Apr 03, 2014 at 08:38:16AM +0200, Roman Haefeli wrote: On Wed, 2014-04-02 at 20:49 -0300, Alexandre Torres Porres wrote: By the way, haven't been really able to make it work well with [textfile]. If you get a symbol with $0-symbol from a text file, you can't use it to work as an address for [send]. Miller proposed to use the new [text] class introduced in 0.45, not the old [textfile]. I haven't checked myself, but according to him this would solve all your trouble as it allows - if I understand correctly - to take literal $0 strings that get expanded only at reading time. (Is that what you meant, Miller?) Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [qlist] and locality
See also the 'text' object in 0.45 that does $ expansion :) on it ;) Now, so it seems, at least [qlist] could be upgarded any time to do the expansion, right? That wouldn't hurt, would it? Cheers 2014-04-02 10:26 GMT-03:00 Miller Puckette m...@ucsd.edu: See also the 'text' object in 0.45 that does $ expansion :) M On Wed, Apr 02, 2014 at 09:45:56AM +0200, IOhannes m zmoelnig wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA256 On 2014-04-02 08:57, Roman Haefeli wrote: On Mon, 2014-03-31 at 18:54 -0300, Alexandre Torres Porres wrote: Hi there, I can't get messages from [qlist] to an object with $0. Is this really a problem? You can: [pack $0 f] | [add 500 $1-bla $2] ah yes. i assumed (most probably correctly), that alex wanted to store the qlist to a file and read it back in a different session of Pd. and/or store a qlist with one instance of an abstraction, and recall it from another instance. fgmasdr IOhannes -BEGIN PGP SIGNATURE- Version: GnuPG v1 Comment: Using GnuPG with Icedove - http://www.enigmail.net/ iQIcBAEBCAAGBQJTO8AvAAoJELZQGcR/ejb4ZLkQAIpZWuGsQZTyAz+DPXRW3Gyz UjhQzMXl3lRSOUuulxA/wTqjFnWsNgQxQH2v2PO+mxWgZL7I9D0JQW24sFrpzNdO zzyaH+i2F6ZQZPris+R71SarfMu8ovIuV4fX1m/2pUDxremPdjRnErwtiRlBu6DE qqxYOi/UYh1/ECSLIW01azr1d01d/C3bSkdYtnrOZGQJYz6VjpBpt8sFLyyPdMqO xbaYTRIezRx+LGXpgs2lEKO5c7DQJli0y4+a3DThO0arKf2BWL+VJ7DqNtJmnaj1 XgFMsm1wkXkDE3vlFqsnjMJnY2zWg8o247oUwnOK2R0ZFHHF7D/eYsKjOKgB8RCc CMoZu3cqq+CCZsl1QCfneoKN8DVRkxLSC3AoK0mpRlDSNK6CKBW7PpH2sc99My7R exnfXJxYKthREXt2GVrB5uD1wewMczg7rxAPo3wHNReYxItNd1TmjDb2d07/TmPg MN/OYp/UWF/LG45C3rENfLkPa8VT48P+I+cX2K8urlheC/2/jXaMZZb+slFjuTlp TvDnIGG9JzsUSQeWj71ILfvAXXHSrNH/9YmbdKuhhFSUe3qePUen8elgV7NOuoec KJcRGMViwqvtRpNVRjjirT9C4u/zV7x6xoPSdc4TINTtHFVheHTJF37xeWFkZZfX bQkA59PavXIbgvQmDPzM =XIxv -END PGP SIGNATURE- ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [qlist] and locality
or you could build your own [qlist] based on [text]... no need to change the old and rusty code of the original [qlist]. I get the workaround, but [qlist] is built for sequencing and simpler for that (like, it can easily set the tempo), and I still think it wouldn't hurt to make it more flexible. It'd be totally backwards compatible. Although I assume I don't think I get the hassle it'd be to do that. I'm still struggling to see what could be so tricky to make $0 possible to work in messages, sorry :P cheers 2014-04-02 13:50 GMT-03:00 IOhannes m zmölnig zmoel...@iem.at: On 04/02/2014 05:43 PM, Alexandre Torres Porres wrote: See also the 'text' object in 0.45 that does $ expansion :) on it ;) Now, so it seems, at least [qlist] could be upgarded any time to do the expansion, right? That wouldn't hurt, would it? or you could build your own [qlist] based on [text]...no need to change the old and rusty code of the original [qlist]. dsar IOhannes ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [qlist] and locality
By the way, haven't been really able to make it work well with [textfile]. If you get a symbol with $0-symbol from a text file, you can't use it to work as an address for [send]. 2014-04-02 19:00 GMT-03:00 Alexandre Torres Porres por...@gmail.com: or you could build your own [qlist] based on [text]... no need to change the old and rusty code of the original [qlist]. I get the workaround, but [qlist] is built for sequencing and simpler for that (like, it can easily set the tempo), and I still think it wouldn't hurt to make it more flexible. It'd be totally backwards compatible. Although I assume I don't think I get the hassle it'd be to do that. I'm still struggling to see what could be so tricky to make $0 possible to work in messages, sorry :P cheers 2014-04-02 13:50 GMT-03:00 IOhannes m zmölnig zmoel...@iem.at: On 04/02/2014 05:43 PM, Alexandre Torres Porres wrote: See also the 'text' object in 0.45 that does $ expansion :) on it ;) Now, so it seems, at least [qlist] could be upgarded any time to do the expansion, right? That wouldn't hurt, would it? or you could build your own [qlist] based on [text]...no need to change the old and rusty code of the original [qlist]. dsar IOhannes ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [qlist] and locality
So, tried other things, and I see it won't be able to deal with messages including $0 like [qlist]. So the reason must be not related to [qlist] or [textfile], but the way Pd handles (or doesn't handle) $0 in messages. The only workaround is to forcely insert $0 with [makefilename], but then all symbols have to be local. cheers 2014-04-02 20:49 GMT-03:00 Alexandre Torres Porres por...@gmail.com: By the way, haven't been really able to make it work well with [textfile]. If you get a symbol with $0-symbol from a text file, you can't use it to work as an address for [send]. 2014-04-02 19:00 GMT-03:00 Alexandre Torres Porres por...@gmail.com: or you could build your own [qlist] based on [text]... no need to change the old and rusty code of the original [qlist]. I get the workaround, but [qlist] is built for sequencing and simpler for that (like, it can easily set the tempo), and I still think it wouldn't hurt to make it more flexible. It'd be totally backwards compatible. Although I assume I don't think I get the hassle it'd be to do that. I'm still struggling to see what could be so tricky to make $0 possible to work in messages, sorry :P cheers 2014-04-02 13:50 GMT-03:00 IOhannes m zmölnig zmoel...@iem.at: On 04/02/2014 05:43 PM, Alexandre Torres Porres wrote: See also the 'text' object in 0.45 that does $ expansion :) on it ;) Now, so it seems, at least [qlist] could be upgarded any time to do the expansion, right? That wouldn't hurt, would it? or you could build your own [qlist] based on [text]...no need to change the old and rusty code of the original [qlist]. dsar IOhannes ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [qlist] and locality
you might want to see the messages sent by [qlist] the same as messages in msgboxes, where you don't have $0-expansion either Bummer. anyway, this brings me to a different topic then. Why is there this lack of expansion in messages? I think I've raised this issue sometime ago. Sorry I don't remember what the problem was, but I'd like to ask again if it's really really hard to expand the functionality in messages, or if this could happen sometime soon in Pd. I believe there won't be any compatibility issues by expanding this functionality. Old patches will still work and newer patches could be simpler, right? cheers 2014-04-01 4:31 GMT-03:00 IOhannes m zmoelnig zmoel...@iem.at: -BEGIN PGP SIGNED MESSAGE- Hash: SHA256 On 2014-03-31 23:54, Alexandre Torres Porres wrote: Hi there, I can't get messages from [qlist] to an object with $0. Is this really a problem? yes (at least: yes, i expect that to make problems; you might want to see the messages sent by [qlist] the same as messages in msgboxes, where you don't have $0-expansion either). however, it's fairly trivial to build a [qlist] from [textfile], [delay] and [s] where you can do whatever magic you'd like to do to the receive symbols. fgmasdr IOhannes -BEGIN PGP SIGNATURE- Version: GnuPG v1 Comment: Using GnuPG with Icedove - http://www.enigmail.net/ iQIcBAEBCAAGBQJTOms0AAoJELZQGcR/ejb4cjEP/jh/AyPAtefrXya26f7ph00z yFo7DI1o2dVgkXr8GOZa0/6XL0K0DWzeQFxd5P+a0TnSoNQ1+2JV92UGJjCX74Ub lWVwS6hXLgVHlUxmLZVQiq5yuIrWb3vqol1Ji70fmzt2hxn8VgSJ/DxxyMcVs28z hDSppMXTOg3ebUMq8YNOmYp0yWqAxLlW/qAPkywWMqxCUbxHYiTTfaMcyc3jcwbZ wP8oLTSWk2AdflS7zDCbrM1V+sB7yBiTm39pJK9jfjTH2ttjEbcUOo0VyD68lf+9 VGtvdt3fSzu3F2RljzppaC/n6Z32iCu5Kc/VulGM9Dya8K4cB6/icnxcjcNUtNlw 2anJWEQ/RpCxRA/J3NJRDo1Ml63r45ze0OESZboV1hEUUcU6vmXwFMWsCoxsNbkk RdQ8pTp5hayCLtJIwT93KLpZcpgNh6I2f1L84N8qOUQaaBhuqziSDH7BW3ngsNFw yTWpSmTJ65l7eusRsXDstNV8LLaANY4cvGsvwlKmi+Gu7ySRMn66tjkFSzWhb5c+ rxhocOpa+MiDOF5dAzE7ER6K1Guk/Uq52N276rniyegHOwtcPLYh1pND9WzMLRU2 RRFbM+XxWT4TbZ2VWbH9HYBP6v/iBdvOi18WhGLLJYRZH0xze/O+qtTIw5TDWgag mbBItM5lwmBpcXzi3IWi =/TRx -END PGP SIGNATURE- ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] [qlist] and locality
Hi there, I can't get messages from [qlist] to an object with $0. Is this really a problem? cheers ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Pd-L2Ork [ii]
same happens in pd-extended here on a mac 2014-03-31 17:43 GMT-03:00 pured...@11h11.com: When using [ii] in a patch, even with [import iemlib] - i have to use [init] once for [ii] to be found (need to save and reload the patch). ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/ listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] tabread interpolation in a patch
Hi folks, did this today. https://docs.google.com/file/d/0B3AoiT0xk8fnWkxjalB3c2dHQWs/ I have no idea about the math, but it Works :) So, this is Lagrange interpolation for what I hear, right? cheers ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] sending sound from pd to sc3?
if mac os, best to use soundflower 2014-03-20 17:55 GMT-03:00 mark hadman markhad...@googlemail.com: On 20 March 2014 15:43, lucrecio diaz lucrecio.d...@gmail.com wrote: Hi list, how can i send a signal from pd to sc3 ? I need to be able to receive the sound that pd is producing for processing in supercollider. any idea which is the best way of doing this? Linux / OSX / Windows / other ? ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] log function in slider
the solution is as I thought, to just invert the given formula in the code. Someone helped me with the math, is something like expr ln($f1 / 1.27) / (((log(127 / 1.27) / 1.27)) * 0.01) here's a patch attached I'm finally gonna check what kind of curve this thing gives :) Thanks everyone Cheers 2014-03-18 5:13 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: No, the code I ported is from vslider_set and vslider_draw_update (might be different in Vanilla). In vslider_bang, math is done to output the proper value. Without looking at the code I would have guessed vslider_bang simply outputs a stored value like [float] does. Then just do math to set the slider position or calculate a new stored value from mouse input. -Jonathan On Monday, March 17, 2014 1:21 AM, Alexandre Torres Porres por...@gmail.com wrote: Hi Roman. This is turning out trickier than I thought. A friend explained the code to me and got to the following equation, with min/max values as 0.01 and 1 respectively. [expr 0.01 * exp((log(1 / 0.01) / 0.01) * $f1 * 0.01)] For what I've checked, it seems to behave like your patch. But it doesn't do the trick I'm looking for yet. I sent a patch earlier, and I'm sending it back again. The goal is to connect a linear slider to an [expr] (with this so called log function) and then to another linear slider. The idea then is that this second slider behaves as one that was set as being log. In the patch attached I was able to emulate it poorly with [pow 0.25], but that was before reaching the list. See that if I use this expr function from the code or your patch it presents quite a different behavior. maybe it is some sort of inversion of this equation, not sure. Apparently this code converts the log function values to linear and I'm hoping to get the exact opposite. Got it? Thanks for looking into this 2014-03-12 4:38 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Don, 2014-03-06 at 21:37 -0300, Alexandre Torres Porres wrote: hi folks, out of curiosity, what's the exact log function used in the slider? I'd like to emulate it. I am not sure, if this is what you want. It converts the incoming linear range between 0 and 1 to a logarithmic range specified by $1 and $2, respectively by the second and third inlet. They behave like the lower and upper bound specified in the [vslider]/[hslider] classes. https://raw.github.com/reduzent/netpd2-patches/master/abs/rh_scalelog.pd Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list log.pd Description: Binary data ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] log function in slider
but when we use the slider with the log function, we're actually doing an inversion of this graphs I just posted. In other words, what we do is the first formula that is actually from the code. So using that formula was actually right to begin with. Check my patch attached now 2014-03-18 17:05 GMT-03:00 Alexandre Torres Porres por...@gmail.com: and as I was checking before, not too far from raising to the power of 0.25 (thicker line in the graph from the picture attached) 2014-03-18 16:48 GMT-03:00 Alexandre Torres Porres por...@gmail.com: the solution is as I thought, to just invert the given formula in the code. Someone helped me with the math, is something like expr ln($f1 / 1.27) / (((log(127 / 1.27) / 1.27)) * 0.01) here's a patch attached I'm finally gonna check what kind of curve this thing gives :) Thanks everyone Cheers 2014-03-18 5:13 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: No, the code I ported is from vslider_set and vslider_draw_update (might be different in Vanilla). In vslider_bang, math is done to output the proper value. Without looking at the code I would have guessed vslider_bang simply outputs a stored value like [float] does. Then just do math to set the slider position or calculate a new stored value from mouse input. -Jonathan On Monday, March 17, 2014 1:21 AM, Alexandre Torres Porres por...@gmail.com wrote: Hi Roman. This is turning out trickier than I thought. A friend explained the code to me and got to the following equation, with min/max values as 0.01 and 1 respectively. [expr 0.01 * exp((log(1 / 0.01) / 0.01) * $f1 * 0.01)] For what I've checked, it seems to behave like your patch. But it doesn't do the trick I'm looking for yet. I sent a patch earlier, and I'm sending it back again. The goal is to connect a linear slider to an [expr] (with this so called log function) and then to another linear slider. The idea then is that this second slider behaves as one that was set as being log. In the patch attached I was able to emulate it poorly with [pow 0.25], but that was before reaching the list. See that if I use this expr function from the code or your patch it presents quite a different behavior. maybe it is some sort of inversion of this equation, not sure. Apparently this code converts the log function values to linear and I'm hoping to get the exact opposite. Got it? Thanks for looking into this 2014-03-12 4:38 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Don, 2014-03-06 at 21:37 -0300, Alexandre Torres Porres wrote: hi folks, out of curiosity, what's the exact log function used in the slider? I'd like to emulate it. I am not sure, if this is what you want. It converts the incoming linear range between 0 and 1 to a logarithmic range specified by $1 and $2, respectively by the second and third inlet. They behave like the lower and upper bound specified in the [vslider]/[hslider] classes. https://raw.github.com/reduzent/netpd2-patches/master/abs/rh_scalelog.pd Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list log.pd Description: Binary data ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] log function in slider
just be sure to click the message, should have put a loadbang there, sorry 2014-03-18 17:16 GMT-03:00 Alexandre Torres Porres por...@gmail.com: but when we use the slider with the log function, we're actually doing an inversion of this graphs I just posted. In other words, what we do is the first formula that is actually from the code. So using that formula was actually right to begin with. Check my patch attached now 2014-03-18 17:05 GMT-03:00 Alexandre Torres Porres por...@gmail.com: and as I was checking before, not too far from raising to the power of 0.25 (thicker line in the graph from the picture attached) 2014-03-18 16:48 GMT-03:00 Alexandre Torres Porres por...@gmail.com: the solution is as I thought, to just invert the given formula in the code. Someone helped me with the math, is something like expr ln($f1 / 1.27) / (((log(127 / 1.27) / 1.27)) * 0.01) here's a patch attached I'm finally gonna check what kind of curve this thing gives :) Thanks everyone Cheers 2014-03-18 5:13 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: No, the code I ported is from vslider_set and vslider_draw_update (might be different in Vanilla). In vslider_bang, math is done to output the proper value. Without looking at the code I would have guessed vslider_bang simply outputs a stored value like [float] does. Then just do math to set the slider position or calculate a new stored value from mouse input. -Jonathan On Monday, March 17, 2014 1:21 AM, Alexandre Torres Porres por...@gmail.com wrote: Hi Roman. This is turning out trickier than I thought. A friend explained the code to me and got to the following equation, with min/max values as 0.01 and 1 respectively. [expr 0.01 * exp((log(1 / 0.01) / 0.01) * $f1 * 0.01)] For what I've checked, it seems to behave like your patch. But it doesn't do the trick I'm looking for yet. I sent a patch earlier, and I'm sending it back again. The goal is to connect a linear slider to an [expr] (with this so called log function) and then to another linear slider. The idea then is that this second slider behaves as one that was set as being log. In the patch attached I was able to emulate it poorly with [pow 0.25], but that was before reaching the list. See that if I use this expr function from the code or your patch it presents quite a different behavior. maybe it is some sort of inversion of this equation, not sure. Apparently this code converts the log function values to linear and I'm hoping to get the exact opposite. Got it? Thanks for looking into this 2014-03-12 4:38 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Don, 2014-03-06 at 21:37 -0300, Alexandre Torres Porres wrote: hi folks, out of curiosity, what's the exact log function used in the slider? I'd like to emulate it. I am not sure, if this is what you want. It converts the incoming linear range between 0 and 1 to a logarithmic range specified by $1 and $2, respectively by the second and third inlet. They behave like the lower and upper bound specified in the [vslider]/[hslider] classes. https://raw.github.com/reduzent/netpd2-patches/master/abs/rh_scalelog.pd Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] log function in slider
cool, looks great by the way, this guy was helping me out with the math, so I don't really know what's going on that well. Apparently he couldn't figure out the slider height variable. And Roman didn't use that too. The formula was behaving the same as Roman's patch, but we simplified the formula now so it's more related to Roman's patch. It's something like this now [expr~ min_$0 * exp($v1 * log(max_$0 / min_$0))] then doing the inverse is not too complicated, just use ln I still have not much clue about the original code, the slider height variable and other things, but, anyhow, these were the equations I was looking for ;) cheers 2014-03-18 18:32 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: On 03/18/2014 04:05 PM, Alexandre Torres Porres wrote: and as I was checking before, not too far from raising to the power of 0.25 (thicker line in the graph from the picture attached) Btw-- here's what that patch looks like in Pd-l2ork (attached). The array rectangle is orange because it's selected. I also changed the size of the garray by click-dragging with the mouse. -Jonathan 2014-03-18 16:48 GMT-03:00 Alexandre Torres Porres por...@gmail.com: the solution is as I thought, to just invert the given formula in the code. Someone helped me with the math, is something like expr ln($f1 / 1.27) / (((log(127 / 1.27) / 1.27)) * 0.01) here's a patch attached I'm finally gonna check what kind of curve this thing gives :) Thanks everyone Cheers 2014-03-18 5:13 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: No, the code I ported is from vslider_set and vslider_draw_update (might be different in Vanilla). In vslider_bang, math is done to output the proper value. Without looking at the code I would have guessed vslider_bang simply outputs a stored value like [float] does. Then just do math to set the slider position or calculate a new stored value from mouse input. -Jonathan On Monday, March 17, 2014 1:21 AM, Alexandre Torres Porres por...@gmail.com wrote: Hi Roman. This is turning out trickier than I thought. A friend explained the code to me and got to the following equation, with min/max values as 0.01 and 1 respectively. [expr 0.01 * exp((log(1 / 0.01) / 0.01) * $f1 * 0.01)] For what I've checked, it seems to behave like your patch. But it doesn't do the trick I'm looking for yet. I sent a patch earlier, and I'm sending it back again. The goal is to connect a linear slider to an [expr] (with this so called log function) and then to another linear slider. The idea then is that this second slider behaves as one that was set as being log. In the patch attached I was able to emulate it poorly with [pow 0.25], but that was before reaching the list. See that if I use this expr function from the code or your patch it presents quite a different behavior. maybe it is some sort of inversion of this equation, not sure. Apparently this code converts the log function values to linear and I'm hoping to get the exact opposite. Got it? Thanks for looking into this 2014-03-12 4:38 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Don, 2014-03-06 at 21:37 -0300, Alexandre Torres Porres wrote: hi folks, out of curiosity, what's the exact log function used in the slider? I'd like to emulate it. I am not sure, if this is what you want. It converts the incoming linear range between 0 and 1 to a logarithmic range specified by $1 and $2, respectively by the second and third inlet. They behave like the lower and upper bound specified in the [vslider]/[hslider] classes. https://raw.github.com/reduzent/netpd2-patches/master/abs/rh_scalelog.pd Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] log function in slider
Hey, a few things have made sense to me now. The minimum and maximum values in PD are in a 100 / 1 ratio. This ratio is important and it's a key in the formula. In the sense that if you have 10 and 1000, the plotting curve looks always the same. So if you forget about the minimum and maximum values, you can just work with this ratio variable. Something like: [expr exp($f1 * log(ratio))] Now this will give you a value from 1 to the value of ratio. And I thought it'd be cool to scale it from 0 to 1. One thing that annoys me a lot is that the log function will not allow you to start at zero. So I wanted to tweak this in order to make it so. Not hard, something like this does the trick. [expr exp($f1 * log(ratio) - 1) / (ratio -1)] You can always rescale this by multiplying to any factor and summing to a constant. cheers 2014-03-18 19:27 GMT-03:00 Alexandre Torres Porres por...@gmail.com: cool, looks great by the way, this guy was helping me out with the math, so I don't really know what's going on that well. Apparently he couldn't figure out the slider height variable. And Roman didn't use that too. The formula was behaving the same as Roman's patch, but we simplified the formula now so it's more related to Roman's patch. It's something like this now [expr~ min_$0 * exp($v1 * log(max_$0 / min_$0))] then doing the inverse is not too complicated, just use ln I still have not much clue about the original code, the slider height variable and other things, but, anyhow, these were the equations I was looking for ;) cheers 2014-03-18 18:32 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: On 03/18/2014 04:05 PM, Alexandre Torres Porres wrote: and as I was checking before, not too far from raising to the power of 0.25 (thicker line in the graph from the picture attached) Btw-- here's what that patch looks like in Pd-l2ork (attached). The array rectangle is orange because it's selected. I also changed the size of the garray by click-dragging with the mouse. -Jonathan 2014-03-18 16:48 GMT-03:00 Alexandre Torres Porres por...@gmail.com: the solution is as I thought, to just invert the given formula in the code. Someone helped me with the math, is something like expr ln($f1 / 1.27) / (((log(127 / 1.27) / 1.27)) * 0.01) here's a patch attached I'm finally gonna check what kind of curve this thing gives :) Thanks everyone Cheers 2014-03-18 5:13 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: No, the code I ported is from vslider_set and vslider_draw_update (might be different in Vanilla). In vslider_bang, math is done to output the proper value. Without looking at the code I would have guessed vslider_bang simply outputs a stored value like [float] does. Then just do math to set the slider position or calculate a new stored value from mouse input. -Jonathan On Monday, March 17, 2014 1:21 AM, Alexandre Torres Porres por...@gmail.com wrote: Hi Roman. This is turning out trickier than I thought. A friend explained the code to me and got to the following equation, with min/max values as 0.01 and 1 respectively. [expr 0.01 * exp((log(1 / 0.01) / 0.01) * $f1 * 0.01)] For what I've checked, it seems to behave like your patch. But it doesn't do the trick I'm looking for yet. I sent a patch earlier, and I'm sending it back again. The goal is to connect a linear slider to an [expr] (with this so called log function) and then to another linear slider. The idea then is that this second slider behaves as one that was set as being log. In the patch attached I was able to emulate it poorly with [pow 0.25], but that was before reaching the list. See that if I use this expr function from the code or your patch it presents quite a different behavior. maybe it is some sort of inversion of this equation, not sure. Apparently this code converts the log function values to linear and I'm hoping to get the exact opposite. Got it? Thanks for looking into this 2014-03-12 4:38 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Don, 2014-03-06 at 21:37 -0300, Alexandre Torres Porres wrote: hi folks, out of curiosity, what's the exact log function used in the slider? I'd like to emulate it. I am not sure, if this is what you want. It converts the incoming linear range between 0 and 1 to a logarithmic range specified by $1 and $2, respectively by the second and third inlet. They behave like the lower and upper bound specified in the [vslider]/[hslider] classes. https://raw.github.com/reduzent/netpd2-patches/master/abs/rh_scalelog.pd Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] log function in slider
here's what I got as an abstraction 2014-03-18 21:12 GMT-03:00 Alexandre Torres Porres por...@gmail.com: Hey, a few things have made sense to me now. The minimum and maximum values in PD are in a 100 / 1 ratio. This ratio is important and it's a key in the formula. In the sense that if you have 10 and 1000, the plotting curve looks always the same. So if you forget about the minimum and maximum values, you can just work with this ratio variable. Something like: [expr exp($f1 * log(ratio))] Now this will give you a value from 1 to the value of ratio. And I thought it'd be cool to scale it from 0 to 1. One thing that annoys me a lot is that the log function will not allow you to start at zero. So I wanted to tweak this in order to make it so. Not hard, something like this does the trick. [expr exp($f1 * log(ratio) - 1) / (ratio -1)] You can always rescale this by multiplying to any factor and summing to a constant. cheers 2014-03-18 19:27 GMT-03:00 Alexandre Torres Porres por...@gmail.com: cool, looks great by the way, this guy was helping me out with the math, so I don't really know what's going on that well. Apparently he couldn't figure out the slider height variable. And Roman didn't use that too. The formula was behaving the same as Roman's patch, but we simplified the formula now so it's more related to Roman's patch. It's something like this now [expr~ min_$0 * exp($v1 * log(max_$0 / min_$0))] then doing the inverse is not too complicated, just use ln I still have not much clue about the original code, the slider height variable and other things, but, anyhow, these were the equations I was looking for ;) cheers 2014-03-18 18:32 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: On 03/18/2014 04:05 PM, Alexandre Torres Porres wrote: and as I was checking before, not too far from raising to the power of 0.25 (thicker line in the graph from the picture attached) Btw-- here's what that patch looks like in Pd-l2ork (attached). The array rectangle is orange because it's selected. I also changed the size of the garray by click-dragging with the mouse. -Jonathan 2014-03-18 16:48 GMT-03:00 Alexandre Torres Porres por...@gmail.com: the solution is as I thought, to just invert the given formula in the code. Someone helped me with the math, is something like expr ln($f1 / 1.27) / (((log(127 / 1.27) / 1.27)) * 0.01) here's a patch attached I'm finally gonna check what kind of curve this thing gives :) Thanks everyone Cheers 2014-03-18 5:13 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: No, the code I ported is from vslider_set and vslider_draw_update (might be different in Vanilla). In vslider_bang, math is done to output the proper value. Without looking at the code I would have guessed vslider_bang simply outputs a stored value like [float] does. Then just do math to set the slider position or calculate a new stored value from mouse input. -Jonathan On Monday, March 17, 2014 1:21 AM, Alexandre Torres Porres por...@gmail.com wrote: Hi Roman. This is turning out trickier than I thought. A friend explained the code to me and got to the following equation, with min/max values as 0.01 and 1 respectively. [expr 0.01 * exp((log(1 / 0.01) / 0.01) * $f1 * 0.01)] For what I've checked, it seems to behave like your patch. But it doesn't do the trick I'm looking for yet. I sent a patch earlier, and I'm sending it back again. The goal is to connect a linear slider to an [expr] (with this so called log function) and then to another linear slider. The idea then is that this second slider behaves as one that was set as being log. In the patch attached I was able to emulate it poorly with [pow 0.25], but that was before reaching the list. See that if I use this expr function from the code or your patch it presents quite a different behavior. maybe it is some sort of inversion of this equation, not sure. Apparently this code converts the log function values to linear and I'm hoping to get the exact opposite. Got it? Thanks for looking into this 2014-03-12 4:38 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Don, 2014-03-06 at 21:37 -0300, Alexandre Torres Porres wrote: hi folks, out of curiosity, what's the exact log function used in the slider? I'd like to emulate it. I am not sure, if this is what you want. It converts the incoming linear range between 0 and 1 to a logarithmic range specified by $1 and $2, respectively by the second and third inlet. They behave like the lower and upper bound specified in the [vslider]/[hslider] classes. https://raw.github.com/reduzent/netpd2-patches/master/abs/rh_scalelog.pd Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list
Re: [PD] log function in slider
there's a bug in one of the number boxes, sorry 2014-03-18 23:37 GMT-03:00 Alexandre Torres Porres por...@gmail.com: here's what I got as an abstraction 2014-03-18 21:12 GMT-03:00 Alexandre Torres Porres por...@gmail.com: Hey, a few things have made sense to me now. The minimum and maximum values in PD are in a 100 / 1 ratio. This ratio is important and it's a key in the formula. In the sense that if you have 10 and 1000, the plotting curve looks always the same. So if you forget about the minimum and maximum values, you can just work with this ratio variable. Something like: [expr exp($f1 * log(ratio))] Now this will give you a value from 1 to the value of ratio. And I thought it'd be cool to scale it from 0 to 1. One thing that annoys me a lot is that the log function will not allow you to start at zero. So I wanted to tweak this in order to make it so. Not hard, something like this does the trick. [expr exp($f1 * log(ratio) - 1) / (ratio -1)] You can always rescale this by multiplying to any factor and summing to a constant. cheers 2014-03-18 19:27 GMT-03:00 Alexandre Torres Porres por...@gmail.com: cool, looks great by the way, this guy was helping me out with the math, so I don't really know what's going on that well. Apparently he couldn't figure out the slider height variable. And Roman didn't use that too. The formula was behaving the same as Roman's patch, but we simplified the formula now so it's more related to Roman's patch. It's something like this now [expr~ min_$0 * exp($v1 * log(max_$0 / min_$0))] then doing the inverse is not too complicated, just use ln I still have not much clue about the original code, the slider height variable and other things, but, anyhow, these were the equations I was looking for ;) cheers 2014-03-18 18:32 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: On 03/18/2014 04:05 PM, Alexandre Torres Porres wrote: and as I was checking before, not too far from raising to the power of 0.25 (thicker line in the graph from the picture attached) Btw-- here's what that patch looks like in Pd-l2ork (attached). The array rectangle is orange because it's selected. I also changed the size of the garray by click-dragging with the mouse. -Jonathan 2014-03-18 16:48 GMT-03:00 Alexandre Torres Porres por...@gmail.com: the solution is as I thought, to just invert the given formula in the code. Someone helped me with the math, is something like expr ln($f1 / 1.27) / (((log(127 / 1.27) / 1.27)) * 0.01) here's a patch attached I'm finally gonna check what kind of curve this thing gives :) Thanks everyone Cheers 2014-03-18 5:13 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: No, the code I ported is from vslider_set and vslider_draw_update (might be different in Vanilla). In vslider_bang, math is done to output the proper value. Without looking at the code I would have guessed vslider_bang simply outputs a stored value like [float] does. Then just do math to set the slider position or calculate a new stored value from mouse input. -Jonathan On Monday, March 17, 2014 1:21 AM, Alexandre Torres Porres por...@gmail.com wrote: Hi Roman. This is turning out trickier than I thought. A friend explained the code to me and got to the following equation, with min/max values as 0.01 and 1 respectively. [expr 0.01 * exp((log(1 / 0.01) / 0.01) * $f1 * 0.01)] For what I've checked, it seems to behave like your patch. But it doesn't do the trick I'm looking for yet. I sent a patch earlier, and I'm sending it back again. The goal is to connect a linear slider to an [expr] (with this so called log function) and then to another linear slider. The idea then is that this second slider behaves as one that was set as being log. In the patch attached I was able to emulate it poorly with [pow 0.25], but that was before reaching the list. See that if I use this expr function from the code or your patch it presents quite a different behavior. maybe it is some sort of inversion of this equation, not sure. Apparently this code converts the log function values to linear and I'm hoping to get the exact opposite. Got it? Thanks for looking into this 2014-03-12 4:38 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Don, 2014-03-06 at 21:37 -0300, Alexandre Torres Porres wrote: hi folks, out of curiosity, what's the exact log function used in the slider? I'd like to emulate it. I am not sure, if this is what you want. It converts the incoming linear range between 0 and 1 to a logarithmic range specified by $1 and $2, respectively by the second and third inlet. They behave like the lower and upper bound specified in the [vslider]/[hslider] classes. https://raw.github.com/reduzent/netpd2-patches/master/abs/rh_scalelog.pd Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management
Re: [PD] log function in slider
so you say this is actually the section of the code I'm looking for to make the conversion I want, right? == static void hslider_set(t_hslider *x, t_floatarg f)/* bugfix */ { double g; if(x-x_gui.x_isa.x_reverse)/* bugfix */ { if(f x-x_min) f = x-x_min; if(f x-x_max) f = x-x_max; } else { if(f x-x_max) f = x-x_max; if(f x-x_min) f = x-x_min; } if(x-x_lin0_log1) g = log(f/x-x_min)/x-x_k; else g = (f - x-x_min) / x-x_k; x-x_val = (int)(100.0*g + 0.4); x-x_pos = x-x_val; (*x-x_gui.x_draw)(x, x-x_gui.x_glist, IEM_GUI_DRAW_MODE_UPDATE); } 2014-03-17 4:07 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: AFAICT vslider is saving something like a slider position, and your expression above (along with the code I posted) is for getting back the original value from it. If you send it something between 0.01 and 1 you'll get a curve that's inverted from the one you're after. If you send it a slider position-- something like another [expr] based on the code inside vslider_set-- you'll get back (roughly) the same value you input. But I'm still stuck on why vslider_bang is doing any math at all. Why should it be more complex than if bang then output stored value? (Setting aside sending to receive symbols for the moment.) -Jonathan On Monday, March 17, 2014 1:21 AM, Alexandre Torres Porres por...@gmail.com wrote: Hi Roman. This is turning out trickier than I thought. A friend explained the code to me and got to the following equation, with min/max values as 0.01 and 1 respectively. [expr 0.01 * exp((log(1 / 0.01) / 0.01) * $f1 * 0.01)] For what I've checked, it seems to behave like your patch. But it doesn't do the trick I'm looking for yet. I sent a patch earlier, and I'm sending it back again. The goal is to connect a linear slider to an [expr] (with this so called log function) and then to another linear slider. The idea then is that this second slider behaves as one that was set as being log. In the patch attached I was able to emulate it poorly with [pow 0.25], but that was before reaching the list. See that if I use this expr function from the code or your patch it presents quite a different behavior. maybe it is some sort of inversion of this equation, not sure. Apparently this code converts the log function values to linear and I'm hoping to get the exact opposite. Got it? Thanks for looking into this 2014-03-12 4:38 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Don, 2014-03-06 at 21:37 -0300, Alexandre Torres Porres wrote: hi folks, out of curiosity, what's the exact log function used in the slider? I'd like to emulate it. I am not sure, if this is what you want. It converts the incoming linear range between 0 and 1 to a logarithmic range specified by $1 and $2, respectively by the second and third inlet. They behave like the lower and upper bound specified in the [vslider]/[hslider] classes. https://raw.github.com/reduzent/netpd2-patches/master/abs/rh_scalelog.pd Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] log function in slider
Hi Roman. This is turning out trickier than I thought. A friend explained the code to me and got to the following equation, with min/max values as 0.01 and 1 respectively. [expr 0.01 * exp((log(1 / 0.01) / 0.01) * $f1 * 0.01)] For what I've checked, it seems to behave like your patch. But it doesn't do the trick I'm looking for yet. I sent a patch earlier, and I'm sending it back again. The goal is to connect a linear slider to an [expr] (with this so called log function) and then to another linear slider. The idea then is that this second slider behaves as one that was set as being log. In the patch attached I was able to emulate it poorly with [pow 0.25], but that was before reaching the list. See that if I use this expr function from the code or your patch it presents quite a different behavior. maybe it is some sort of inversion of this equation, not sure. Apparently this code converts the log function values to linear and I'm hoping to get the exact opposite. Got it? Thanks for looking into this 2014-03-12 4:38 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Don, 2014-03-06 at 21:37 -0300, Alexandre Torres Porres wrote: hi folks, out of curiosity, what's the exact log function used in the slider? I'd like to emulate it. I am not sure, if this is what you want. It converts the incoming linear range between 0 and 1 to a logarithmic range specified by $1 and $2, respectively by the second and third inlet. They behave like the lower and upper bound specified in the [vslider]/[hslider] classes. https://raw.github.com/reduzent/netpd2-patches/master/abs/rh_scalelog.pd Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list slider.pd Description: Binary data ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] friendly reminder that osx pd-extended is still badly flawed
it's an OS thing, you can set it somewhere so it doenst open the latest files, someone showed how to do it here, cant remeber though :P 2014-03-13 12:41 GMT-03:00 i go bananas hard@gmail.com: pd 0.42.5 ...so it got fixed??? i don't like updating, cos if it ain't broke, don't fix itbut maybe i should try? On Fri, Mar 14, 2014 at 12:21 AM, i go bananas hard@gmail.com wrote: i'm on 10.6.8 On Fri, Mar 14, 2014 at 12:18 AM, José Rafael Subía Valdez jsubiaval...@gmail.com wrote: what version of OSX?? I have no problem with it. Does it open 2 instances or just 2 icons on the dock??? I remember a while back in tiger this occurred after doing something in system preferences (cant remember what.. it was a long time ago) Those days, I opened a patch and I saw a PD icon and another blank icon also called pd, but now.. running 10.6.8 and extended 0.43. I see no problem as you describe. On Thu, Mar 13, 2014 at 10:07 AM, i go bananas hard@gmail.comwrote: every time i open a patch from clicking on an icon, PD loads 2 patches. pretty sure this is a long standing issue that hasn't been fixed. (os-x) ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list -- Lic. José Rafael Subía Valdez www.jrsv.net ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Peak Level detect in Vanilla
well, lets see if we can get this to a closure So, basically you are saying it is less trouble to make an external than an abstraction? Nope, never said it. Not sure why you took it that way. Maybe because I mentioned efficiency. But that was supposed to mean computer efficiency, and as a response to what I thought was a general question about compiled classes vs abstractions. Not that the discussion was really about that, and, more importantly, not that is was my point at all, as I clearly stated and then shifted to my point after that... I didn't even feel like moving the discussion that way, that's why I tried not to do it and stick to my point, by the way. I give you an abstraction and you say you're still looking for the external? No no no. I'm not looking for no external. I already know about the external, and I even mentioned about it in my sencond message on this thread, when I said I was hoping there'd be a [peakenv~] like object in Vanilla. And then I pointed it could come as a feature in a probable update of [env~]. I've been using [peakenv~] and mostly [prvu~], I think they're great. Agreed, but I still have difficulties in understanding why you desperately need it to be a compiled class (I am certainly not against it, though). I wouldn't say I'm desperate... so you don't need to keep having trouble trying to figure me out. Also, I never even said I need this to be a compiled class, cause I actually do not. I'm happy to share my point yet again, but please don't misinterpret/misjudge my words. Once more, my only point is that I *think* this is an important feature that *should* come in vanilla objects, it deserves to! Maybe as an extension to [env~], like in a second outlet... that wouldn't hurt... and wouldn't even require a new object. Anyway, that's all there's to it. Nothing more... I think I'm being very clear and straightforward. Not anyone here thought this was a bad idea too (so it seems), now I'm wondering what is all the commotion about... or does anyone think this is actually a bad idea? I mean, I seriously wonder what's the deal. Pd Vanilla comes with a very limited set of objects, we all know that. I can get by with that with no problem. I'm just pointing how one little thingy could come into the set, and suddenly things get off track to turn into such a debate. I don't know, I suspect there can be something to it... :) Why are abstractions second class citizens in your opinion? Maybe if I had ever stated that, I could answer you to that question. What you could ask me without putting words in my mouth is: why do I think Peak Level detection should come as a function in a compiled class in Pd Vanilla, when you can do it as an abstraction or when there's a couple of objects in Pd-Extended that'll do it for you. Well, I think it is such a basic feature that deserves to be out of the box from Pd Vanilla in an object like [env~], and I guess I'm repeating myself... Thing is I have very little knowledge in C and compiling objects, so doing abstractions is All I do... I think it's great people like me can get by with them... but you know, eventually some stuff will get you thinking hmm, this could have already been made available out of Vanilla objects... Moreover, I mentioned [vu] (a vanilla GUI) in my first message and how it receives peak level, but no vanilla object does that job. That looks like something missing or incomplete in Vanilla. I really hope to see [env~] handling that issue soon. That'll make my day and think the world is a better place. Cheers 2014-03-11 6:40 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Mon, 2014-03-10 at 21:31 -0300, Alexandre Torres Porres wrote: What is the difference between using an abstraction or a compiled class? well, I assume they can be more efficient, but my only point here is what I said already and that you agree with - peak level should be available, seems like lots of trouble to need to make an abstraction for it. So, basically you are saying it is less trouble to make an external than an abstraction? The fact that neither I nor you made an external indicates otherwise. I know there's an external around, I give you an abstraction and you say you're still looking for the external? Why are abstractions second class citizens in your opinion? but I mean it deserves to be in vanilla. Agreed, but I still have difficulties in understanding why you desperately need it to be a compiled class (I am certainly not against it, though). Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] log function in slider
Thanks Jonathan. Unfortunately, my C expertise is kinda poor and I'm still lost. I see it's got something to do with [exp] but haven't got my head around the function needed to emulate it. I'm making extensive documentation about Pd, so I'd like to write about it. I find it worth noting. In the patch I'm sending, which was my attempt to get this right before reaching the list, I was able to emulate a bit reasonably with [expr pow($f1, 0.25)]. Cheers 2014-03-06 21:56 GMT-03:00 Jonathan Wilkes jancs...@yahoo.com: From g_vslider.c: if(x-x_lin0_log1) out = x-x_min*exp(x-x_k*(double)(x-x_val)*0.01); Where x-x_k is: log(x-x_max/x-x_min)/(double)(x-x_gui.x_h - 1); And x-x_gui.x_h is the height of the slider -Jonathan On Thursday, March 6, 2014 7:37 PM, Alexandre Torres Porres por...@gmail.com wrote: hi folks, out of curiosity, what's the exact log function used in the slider? I'd like to emulate it. cheers ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list slider.pd Description: Binary data ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Peak Level detect in Vanilla
What is the difference between using an abstraction or a compiled class? well, I assume they can be more efficient, but my only point here is what I said already and that you agree with - peak level should be available, seems like lots of trouble to need to make an abstraction for it. I know there's an external around, but I mean it deserves to be in vanilla. cheers 2014-03-10 4:32 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Sun, 2014-03-09 at 22:32 -0300, Alexandre Torres Porres wrote: Why not an abstraction in my point of view? Well, looks kinda cumbersome for that particular goal. I am with you in that I think it makes sense to extend [env~]. Regarding abstractions, I don't see what is cumbersome. What is the difference between using an abstraction or a compiled class? Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Peak Level detect in Vanilla
As far as Vanilla goes it does seem like a great solution. Thanks a lot for that, seems to do the trick! But was really hoping for or even asking for a [peakenv~] like object. I didn't find anything and I thought I wouldn't be missing it if there was, but came here to ask anyway. Maybe an update to the [env~] object where it could have a second outlet for peaks. How feasible is that Miller? Seems there's a bit of a whole here where we can't easily send the peak values to [vu]. I think it'd be nice to have a way. Cheers 2014-03-08 21:11 GMT-03:00 peiman khosravi peimankhosr...@gmail.com: This may not be the best solution but I did this by reading the DSP block into an array, on every block, and calculating the absolute peak value stored in the array on each iteration. I've attached the abstract. P *www.peimankhosravi.co.uk http://www.peimankhosravi.co.uk || RSS Feed http://peimankhosravi.co.uk/miscposts.rss || Concert News http://spectralkimia.wordpress.com/* On 8 March 2014 23:43, Alexandre Torres Porres por...@gmail.com wrote: Hi there, since [vu] accepts a value for Peak Amplitude, is there a way to measure it with Vanilla objects? Cheers ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Peak Level detect in Vanilla
env~ seems incomplete to me if it's only going to compute RMS. Glad you feel how I do :) But wondering where you'd be stuck at, seems like something not too complicated. Anyway, waiting for it someday ;) Why not an abstraction in my point of view? Well, looks kinda cumbersome for that particular goal. Cheers 2014-03-09 18:30 GMT-03:00 Roman Haefeli reduz...@gmail.com: On Son, 2014-03-09 at 14:05 -0700, Miller Puckette wrote: By the way - I just looked, and you can save a great deal of trouble using the array max object (new in Pd 0.25) You mean 0.45, I guess(?) - no need for 'until' horror. Oh, that is great! Thanks for the reminder, I haven't looked at [array] yet. But env~ seems incomplete to me if it's only going to compute RMS. Yeah, I see your and Alexandre's point: Why not extending [env~]? Roman ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Peak Level detect in Vanilla
hmm, that's an idea for another built-in option, so it's completely compatible to [vu] right out of the box :) 2014-03-09 23:35 GMT-03:00 Chris Clepper cgclep...@gmail.com: On Sun, Mar 9, 2014 at 5:05 PM, Miller Puckette m...@ucsd.edu wrote: But env~ seems incomplete to me if it's only going to compute RMS. Can we get the values in dBFS, please? Chris ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] Peak Level detect in Vanilla
Hi there, since [vu] accepts a value for Peak Amplitude, is there a way to measure it with Vanilla objects? Cheers ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] log function in slider
hi folks, out of curiosity, what's the exact log function used in the slider? I'd like to emulate it. cheers ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [PD-announce] Chocolate et Coffee
yeah, I was finding the coffee library to be kind of reductant, these functionalities have already been achieved by other libraries in Pd Extended, but the GUI stuff is gold, I think it's time we could have something like that as an option in Pd Extended! 2014/1/3 IOhannes m zmölnig zmoel...@iem.at On 2014-01-03 09:44, Pierre Guillot wrote: I'm sorry, I didn't want to hurt anybody with this library. I never thought that the name was so important and I'll change it as soon as possible if it's your principal wish. i don't think you've hurt anybody; and so far the only one who has been complaining was me :-) i don't think there's a real problem with your jokes about flavours (coffee, cocoa, whatever), though there might be better - and more specific - names. as jonathan has pointed out, i myself am the author of a dumpster library with a general name: but this library is about 15 years old. (i think) all other libraries i've written since then are targetted at a specific problem (e.g. networking) and have a specific name (e.g. iemnet). as for dupes in coffee: + [c.loadmess] - iemlib's [init] - (iirc, there used to be a kind-of implementation in vanilla as well) + [c.pak] - pdmtl's [list.pak] + [c.patcherargs] - iemgut's [canvasargs] - jonathan's query system - flext + [c.patcherinfos] - iemgut's [canvasname], [canvasinfo] - jonathan's query system + [c.prepend] - vanilla's [list prepend]+[list strip] - iemlib's [prepend] - cyclone's [Prepend] gfdar IOhannes ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] AM by keeping the Carrier (Not Ring Mod)
I find this a bit misleading. Ring Modulation is when both singals are bipolar and that's it. And he's saying something is AM modulation when it's Ring Modulation (but he doesn't say it is so and specifies Ring Modulation as something else). It doesn't hurt to be more accurate. Curtis Roads' Computer Music Tutorial makes it very simple and straightforward. 2013/12/31 Alexandros Drymonitis adr...@gmail.com There's this also http://en.flossmanuals.net/pure-data/audio-tutorials/amplitude-modulation/ On Tue, Dec 31, 2013 at 8:22 PM, Martin Peach martin.pe...@sympatico.cawrote: On 2013-12-31 06:50, Arda Eden wrote: Hi, Most of the AM examples are simply multiplying carrier and modulator outputs, which is also known as Ring Modulation. But in the resulting spectrum the carrier is gone and only the side bands appear. I couldn’t figure out a way to keep the carrier signal in the resulting spectrum (Like as in real AM, not RM). It was easy in Csound for example, since the amplitude value is an input parameter to the oscil function. Any ideas ? Do it the same way as in analog, add a DC offset to one of the signals. [+~ 0.02] Martin ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/ listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [PD-announce] martha~
genious :) 2013/12/29 José Rafael Subía Valdez jsubiaval...@gmail.com Martha.. Sigmund Freud's Wife.. I also was curious. and thanks william for another of your fabulous PD contributions. happy 2014 On Sun, Dec 29, 2013 at 11:14 AM, Alexandre Torres Porres por...@gmail.com wrote: cool, I use one of that too, will try it out, really curious about the name though, why the hell [martha~]? :) cheers 2013/12/27 William Brent william.br...@gmail.com Hi list, Maybe something like this already exists out there, but I just spent some time putting together a convenient abstraction version of some patches I made recently for managing the tracks output of sigmund~ in connection with an oscillator bank. I needed independent glissing/pulsing effects per partial, control over attack/release times, among other things. At the very least it takes care of all the new track/continuing track/dead track bookkeeping and automatically creates an internal oscillator bank. I've used my old messy version in a few performances without problems, but this abstraction edition could likely use some testing for anyone who's interested. I called it [martha~]: http://williambrent.conflations.com/pages/research.html#martha -- William Brent www.williambrent.com “Great minds flock together” Conflations: conversational idiom for the 21st century www.conflations.com ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list -- Lic. José Rafael Subía Valdez www.jrsv.net ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] A (Happy) New Year's Convolution
Sharing My New Year's CONVOLUTION I'm doing the overlap-add method, as nicely described in http://www.dspguide.com/ch18.htm Seems to be working like a charm! Not sure if anyone ever did this in a patch like this, but I know there are some externals around. I remember I discussed once with Brent on how to do this, by the way. What do you think Brent? Nailed it? Anyone else? I'll include this soon in my tutorial patches, but for now you can check it at: https://drive.google.com/file/d/0B3AoiT0xk8fnNU9PRHdldVVFbU0/edit?usp=sharing it runs ok even with insanely huge FFT sizes, but I need to push the latency up as soon as it starts getting FELIZ 2014 ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] A (Happy) New Year's Convolution
Oh yeah, it was partitioned convolution we were talking about back then, now I remember. Cool, I wanna see if I can find the discussion here and get back to that. My main motivation is didactic, but I also think it's cool if things work out just find as Vanilla abstractions. So, next thing on my list for sure! Anyway, I'm also working to add a live input to this patch, instead of just a sample playback, and also working on some other ideas. I thought about saving this FFT operation too, but I was using the same core to do a convolution where both inputs were live inputs. I'm assuming that's the kind of convolution they have on supercollider anyway. They also have an UGen for a fixed kernel where they save the computation of one FFT like that, but it seems to be something else as the FFT is not derived from the impulse length. I have already covered the spectral convolution and other related patches like the vocoder. It's cool to finally be able to get into this other (and more proper) convolution implementations as patches. Well, I ramble Cheers and a Happy 2014 2013/12/31, William Brent william.br...@gmail.com: Seems to be working, nice! I still want to take a stab at making a vanilla patch for partitioned convolution. That way you can have really low latency I/O even if your impulse response is several seconds long. Not a problem to do in C as an external, and seeing your zero padding mask in the overlap 2 sub-patch makes me want to try it out. PS: since the impulse response isn't changing, you could do the transform on it once ahead of time, store the results in tables, then tabreceive them for the convolution multiply. Save an FFT! On Tue, Dec 31, 2013 at 9:58 AM, Alexandre Torres Porres por...@gmail.comwrote: Sharing My New Year's CONVOLUTION I'm doing the overlap-add method, as nicely described in http://www.dspguide.com/ch18.htm Seems to be working like a charm! Not sure if anyone ever did this in a patch like this, but I know there are some externals around. I remember I discussed once with Brent on how to do this, by the way. What do you think Brent? Nailed it? Anyone else? I'll include this soon in my tutorial patches, but for now you can check it at: https://drive.google.com/file/d/0B3AoiT0xk8fnNU9PRHdldVVFbU0/edit?usp=sharing it runs ok even with insanely huge FFT sizes, but I need to push the latency up as soon as it starts getting FELIZ 2014 ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list -- William Brent www.williambrent.com “Great minds flock together” Conflations: conversational idiom for the 21st century www.conflations.com ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] A (Happy) New Year's Convolution
BTW, I meant to say It runs ok even with insanely huge FFT sizes, but Pd's latency needs increase as soon as it starts getting... well... getting biggish 2013/12/31 Alexandre Torres Porres por...@gmail.com Sharing My New Year's CONVOLUTION I'm doing the overlap-add method, as nicely described in http://www.dspguide.com/ch18.htm Seems to be working like a charm! Not sure if anyone ever did this in a patch like this, but I know there are some externals around. I remember I discussed once with Brent on how to do this, by the way. What do you think Brent? Nailed it? Anyone else? I'll include this soon in my tutorial patches, but for now you can check it at: https://drive.google.com/file/d/0B3AoiT0xk8fnNU9PRHdldVVFbU0/edit?usp=sharing it runs ok even with insanely huge FFT sizes, but I need to push the latency up as soon as it starts getting FELIZ 2014 ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] headroom in Pd
I have rem's multiface ii by the way, it says it handles a headrom of 13 db or something, don't really know what it means. It'llbe a while 'til I check anyway, I'm at a very nice beach in Brasil andI just dipped myself into the atlantic ocean LoveTo You All!!! 2013/12/31 Chris Clepper cgclep...@gmail.com It's very, very easy to avoid any sort of clipping processing by using hardware with drivers that don't have any! Avid, Apogee, MOTU, RME, and many others have bit transparent OSX CoreAudio drivers. Also, any DAC worth it's using can reconstruct far beyond 0dBFS without distortion, so hearing volume increase past -1..1 in software is not surprising. I recall the ADI 1955 and equivalent TI part putting out +12dBFS or something ridiculous, but those ain't Wolfson low power headphone codecs neither! On Tue, Dec 31, 2013 at 6:50 PM, Simon Wise simonzw...@gmail.com wrote: On 31/12/13 08:30, Dan Wilcox wrote: Ouch. I guess alot of us don't have serious projects :D (Out of curiosity, does Max do soft clipping also?) the point was that OSX was messing with the sound between the software, presumably any software, and the audio output ... which may perhaps be called a feature while listening to songs in iTunes but is a big worry if you are trying to use the system seriously as a musician. It is a problem that comes up on this list from time to time, I don't recall any reply saying it could be bypassed or turned off. Simon ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/ listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] headroom in Pd
here's the deal, if I have a square wave in Pd running at 1 -1 peak to peak, then you say that should be my maximum output, right? Thing is that if I give it an extra boost (say, multiply it by 2) I can clearly listen an increase in loudness. Hence, something in my system is allowing some headroom to be output. I got a macbook air from 2010 running 10.7.5... if Pd is not responsible for this, maybe my hardware + Mac OS is? here's the patch, try yourselves and tell me what you get please. Cheers #N canvas 653 26 257 182 10; #X obj 79 97 dac~; #X obj 85 41 square~ 440; #X floatatom 125 72 5 0 0 0 - - -; #X obj 85 70 *~; #X connect 1 0 3 0; #X connect 2 0 3 1; #X connect 3 0 0 0; #X connect 3 0 0 1; 2013/12/21, IOhannes m zmölnig zmoel...@iem.at: On 2013-12-21 14:58, peiman khosravi wrote: However, it's probably wise to clip the signal before sending it to dac~. Entirely for health and safety reasons! this really depends...a clipping sine will have loads of high frequencies that might be equally damaging to your audience. if you want to be safe, use math to make sure that your signal won't exceed -1..+1 before sending to the [dac~]. or use a limiter (zexy has a handy one). fgmrdsa IOhannes ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [PD-announce] martha~
cool, I use one of that too, will try it out, really curious about the name though, why the hell [martha~]? :) cheers 2013/12/27 William Brent william.br...@gmail.com Hi list, Maybe something like this already exists out there, but I just spent some time putting together a convenient abstraction version of some patches I made recently for managing the tracks output of sigmund~ in connection with an oscillator bank. I needed independent glissing/pulsing effects per partial, control over attack/release times, among other things. At the very least it takes care of all the new track/continuing track/dead track bookkeeping and automatically creates an internal oscillator bank. I've used my old messy version in a few performances without problems, but this abstraction edition could likely use some testing for anyone who's interested. I called it [martha~]: http://williambrent.conflations.com/pages/research.html#martha -- William Brent www.williambrent.com “Great minds flock together” Conflations: conversational idiom for the 21st century www.conflations.com ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] cartopol~ / poltocar~
I reported the bug as anonymous 2013/12/20 Alexandre Torres Porres por...@gmail.com hi there, I once called for the attention that these objects were buggy, as they were giving inverted values. Anyway, since they were both screwed up in the same way, the conversion back would inverted back and make everything alright, or at least sound correct. Well, for the pd extended 0.43 I see this has been corrected, at least for the control data objects. As for the signal objects, [cartopol~] was corrected, but not [poltocar~]. This means that it now can screw up your sound processing a lot and make some patches - that were actually ok before - sound bad. the way to work around this problem is to invert the imaginary part (multiply it by -1) coming out of [poltocar~] Cheers ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] cartopol~ / poltocar~
hi there, I once called for the attention that these objects were buggy, as they were giving inverted values. Anyway, since they were both screwed up in the same way, the conversion back would inverted back and make everything alright, or at least sound correct. Well, for the pd extended 0.43 I see this has been corrected, at least for the control data objects. As for the signal objects, [cartopol~] was corrected, but not [poltocar~]. This means that it now can screw up your sound processing a lot and make some patches - that were actually ok before - sound bad. the way to work around this problem is to invert the imaginary part (multiply it by -1) coming out of [poltocar~] Cheers ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] headroom in Pd
Hi there, where can I find info about headroom and clipping on Pd. Or can anyone tell me quickly how it goes? Does it always really clip over a maximum of 1, or is there some headroom? Does it depend on the audiocard or something? thanks ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] why overlaps affect frequency of [osc~]?
Howdy, ever tried to compute a hann window inside a subpatch where the FFT is happening? And then if you're overlapping it by 4, do you see that only 1/4 of the cycle from [osc~] came up? That means the [osc~] frequency was 1/4 what it should be... Now, why and how does it happen? I just have no clue at all. Cheers Thanks ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] why overlaps affect frequency of [osc~]?
thanks master well, I was betting it was that, and it actually brings me to more direct questions I should have asked before. So here they go. Simply put: How come and why does overlapping affect the sample rate? the same happens if you raise the samplerate via upsampling. I guess this is what's really confusing, cause I can't seem to get it. If you do upsampling with block, for instance, you don't get this frequency change issue with [osc~]. It'll run the same frequency, no problem... but overlapping will do that somehow. Why the hell the actual upsampling does not affect it? And does this mean that overlap of 4 and upsampling of 4x makes it really run at 16x the sample rate? cheers 2013/11/26 IOhannes m zmölnig zmoel...@iem.at On 2013-11-26 11:19, Alexandre Torres Porres wrote: Howdy, ever tried to compute a hann window inside a subpatch where the FFT is happening? And then if you're overlapping it by 4, do you see that only 1/4 of the cycle from [osc~] came up? That means the [osc~] frequency was 1/4 what it should be... Now, why and how does it happen? I just have no clue at all. that is mainly because the sample rate within the overlapped canvas is higher than the sample rate outside. (e.g. if you are doing an overlap of 2, you are in fact processing the double amount of data in the same time, so your overlapping sample rate is 88200 if the non-overlapping rate is 44100). the same happens if you raise the samplerate via upsampling. [osc~] uses the sample-rate information (within the signal data structure) to calculate the phase of a cosine-table lookup. btw, there has been a long-standing feature request [1] to extend the signal-structure to hold both overlap factor and sample-rate, so signal-processing objects could handle upsampling and overlapping differently. (speaking of which, it would also be nice, if any dsp object could have a notion of the current overlap cycle) gfmasr IOhannes [1] https://sourceforge.net/p/pure-data/feature-requests/16/ ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] why overlaps affect frequency of [osc~]?
[1] https://sourceforge.net/p/pure-data/feature-requests/16/ Not sure if I got what the request was requesting. the parameter s-s_sr isn't defined properly, as s-s_sr=(fs*overlap) has nothing to do with the actual sampling interval applied to the audio data. Is this bit just saying overlap in [block~] is done wrong and shouldn't affect sample rate? Cause I'd be right there with it... 2013/11/26 IOhannes m zmölnig zmoel...@iem.at On 2013-11-26 11:19, Alexandre Torres Porres wrote: Howdy, ever tried to compute a hann window inside a subpatch where the FFT is happening? And then if you're overlapping it by 4, do you see that only 1/4 of the cycle from [osc~] came up? That means the [osc~] frequency was 1/4 what it should be... Now, why and how does it happen? I just have no clue at all. that is mainly because the sample rate within the overlapped canvas is higher than the sample rate outside. (e.g. if you are doing an overlap of 2, you are in fact processing the double amount of data in the same time, so your overlapping sample rate is 88200 if the non-overlapping rate is 44100). the same happens if you raise the samplerate via upsampling. [osc~] uses the sample-rate information (within the signal data structure) to calculate the phase of a cosine-table lookup. btw, there has been a long-standing feature request [1] to extend the signal-structure to hold both overlap factor and sample-rate, so signal-processing objects could handle upsampling and overlapping differently. (speaking of which, it would also be nice, if any dsp object could have a notion of the current overlap cycle) gfmasr IOhannes [1] https://sourceforge.net/p/pure-data/feature-requests/16/ ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] spectral mapping, anyone?
well, let me tell you how I did it, I can send some of my last work, but, as usual, needs some cleaning up and documenting. But basically I'm using [sigmund~], then getting tracks output to use all the partial information to feed an oscillator bank for resynthesis. This is pretty much what you can call a phase vocoder, hence you can tweak with it and mess around with partials. I also have a patch where you can control the partials individually and very arbitrarily. So, for spectral mapping, what I do is I try to map all the harmonic relationship from partials and detune them according to a different harmonic series. It's a lot of work getting all of the data mapped and in order, then apply the math and stuff. It's also tricky because you need the right tuning of [sigmund~] to get better results according to the kind of musical audio signal that is coming through... Anyway, anyone got a better idea than that? I think that if you use FFT you will go crazy trying yo get this right, and I assume that [sigmund~] does work in the best way for this and it is based on FFT anywy (Am I right?). Cheers 2013/11/26 peiman khosravi peimankhosr...@gmail.com Hello, Yes, your description of warp is correct. Partial detection is more tricky because often the energy in 4 or more FFT bins amounts to one partial. So firstly, you need to derive the partials from the FFT data, then you need to quantise the partials' frequencies. One possible cheat would be to trace the loudest FFT-bins and then transfer their energy to the bins whose frequencies are nearest to the harmonics of a given fundamental. If I'm not mistaken, at a sampling rate of 44100 and an FFT size of 4096, the frequency of bin 10 would be calculated as (44100/4096)*10=107.66. Just note that only FFT-size/2+1 bins are usable. That's the Nyquist frequency (half of the sampling frequency). If you take 107.66 as your fundamental (and zero all the bins below that) then you can do the following: For each analysis window... 1- Detect the next FFT bin whose magnitude is above a certain threshold 2- Transfer the frequency and amplitude content of this bin to the nearest harmonic of the fundamental. So for input bin 15 (and a fundamental frequency of 107.66) this would be bin 20. The bin number to frequency mapping is linear so it's easy to calculate. Even, using fiddle~, you can get the fundamental frequency from the input and have it change dynamically from window to window. You're likely to get some bubbly artefacts thought, but once you have a basic working patch you should be able to fine tune it. So you may want to group the bins so that you transfer not just the energy in one bin but also the bins around it. You might also want to do some averaging of the amplitude of 6 windows or so to avoid rapidly changing values, before you pass the signal into a threshold detector. I can do this in Csound but I'm not that familiar with how FFT works in PD and I don't have a patch that does this. If I get the time I might make one next weekend though and post it here. P *www.peimankhosravi.co.uk http://www.peimankhosravi.co.uk || RSS Feed http://peimankhosravi.co.uk/miscposts.rss || Concert News http://spectralkimia.wordpress.com/* On 26 November 2013 11:48, Eran Sachs eransa...@hotmail.com wrote: Peiman, It works great! I've been messing various sounds all day now, plus there's a thing in my computer with Barry Vercoe's name on it which I find oddly elevating. However, if I understand the wrap function correctly, it substitutes bin values for values of other bins through whatever function you apply. But the bins are still all derived from the FFT procedure. Or am I missing something there? What I would like to do is to move from bins to partials, so that they are essentially mapped to harmonic overtones of a given fundamental according to nearest match. Like a clever phase-vocoder Autotune of some kind. Is there a way to do that, to the best of anyone's knowledge? Much obliged, E. -- Date: Mon, 25 Nov 2013 15:12:50 + Subject: Re: [PD] spectral mapping, anyone? From: peimankhosr...@gmail.com To: eransa...@hotmail.com CC: por...@gmail.com; jaime.oliv...@gmail.com; pd-list@iem.at yes csound6 should work on windows too as far as I know. *www.peimankhosravi.co.uk http://www.peimankhosravi.co.uk || RSS Feed http://peimankhosravi.co.uk/miscposts.rss || Concert News http://spectralkimia.wordpress.com/* On 24 November 2013 22:06, Eran Sachs eransa...@hotmail.com wrote: Thanks Peiman. Alas, I'm living the life of a PC/Windows user. AFAICT, no csound6? Z -- Date: Sun, 24 Nov 2013 20:27:39 + Subject: Re: [PD] spectral mapping, anyone? From: peimankhosr...@gmail.com To: eransa...@hotmail.com CC: por...@gmail.com; jaime.oliv...@gmail.com; pd-list@iem.at With spectral warping you can do any frequency-based manipulation,
Re: [PD] why overlaps affect frequency of [osc~]?
hope this clears things a bit. I can't see how it could be any clear :D thanks so much for the detailed explanation, really appreciate it I finally know how overlapping is actually done behind the scenes now, cool And yeah, objects like [osc~] should totally be aware of this matter and do it correctly On the other hand, I'm getting really nice and distorted wicked sounds from this error, and I'm gonna use it! haha All the best 2013/11/26 IOhannes m zmölnig zmoel...@iem.at On 2013-11-26 19:37, Alexandre Torres Porres wrote: [1] https://sourceforge.net/p/pure-data/feature-requests/16/ Not sure if I got what the request was requesting. the parameter s-s_sr isn't defined properly, as s-s_sr=(fs*overlap) has nothing to do with the actual sampling interval applied to the audio data. the question is how you define samplerate. a simplisitic approach simply takes the number of samples processed within e.g. 1 second. if you do overlap by 2, you process each incoming sample twice, so the number of samples that passes through the object is doubled, and thus the sample rate is doubled as well. this however doesn't really make sense, if you use that samplerate to calculate the period of a periodic signal, like [osc~] does. e.g. an [osc~ 689.062] will have a period length of 64 samples (@44.1kHz). when we do upsampling, the internal samplerate is 88.2kHz, thus the period length is 128 samples. when going back to the original samplesize, you need to do downsampling, which basically means to only take every second sample (in the most simple form), so you end up with half of the samples discarded and the period size of 64 again. however, with overlapping things are not as simple. the internal samplerate is again 88.2kHz, the period length 128 samples. but this gives us two problems: - imagine that the blocksize was still 64 samples (both in the parent canvas and in the reblocked (overlapped) sub-canvas). but [osc~] will create a continuous signal between two calls, as it doesn't know anything about overlapping. this is plain wrong for overlapping signals, where the odd frames should be considered continous, and the even frames are continuous, but not both together. - when going back to the non-overlapping parent canvas, we again have to reduce the number of samples by a factor-of-two. but this time the algorithm used is to align the half-blocks and sum the up. but this means, that you still have a period size of 128 samples. which will make ~344Hz in the parent patch...(and the odd artifacts you get from the problem #1) hope this clears things a bit. the statement in the feature-request/bugtracker kind of addresses this: in Pd the signal-block's sample rate is not the inverse of the actual sampling interval (think nyquist and the like) but the number of samples processed in a given time - which simply isn't the same if you do overlapping fmdsar IOhannes ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] spectral mapping, anyone?
oh, and the thing about the FFTease object is that it always fits the partials into a fixed scale. I mean the frequencies are always the same, and the scale isn't transposed according to a continuous fundamental. Maybe it's because it's using and dealing with the fixed bins in the FFT... not sure. Now I'm trying to do that according to the fundamental in a more loose and free way. 2013/11/26 Alexandre Torres Porres por...@gmail.com well, let me tell you how I did it, I can send some of my last work, but, as usual, needs some cleaning up and documenting. But basically I'm using [sigmund~], then getting tracks output to use all the partial information to feed an oscillator bank for resynthesis. This is pretty much what you can call a phase vocoder, hence you can tweak with it and mess around with partials. I also have a patch where you can control the partials individually and very arbitrarily. So, for spectral mapping, what I do is I try to map all the harmonic relationship from partials and detune them according to a different harmonic series. It's a lot of work getting all of the data mapped and in order, then apply the math and stuff. It's also tricky because you need the right tuning of [sigmund~] to get better results according to the kind of musical audio signal that is coming through... Anyway, anyone got a better idea than that? I think that if you use FFT you will go crazy trying yo get this right, and I assume that [sigmund~] does work in the best way for this and it is based on FFT anywy (Am I right?). Cheers 2013/11/26 peiman khosravi peimankhosr...@gmail.com Hello, Yes, your description of warp is correct. Partial detection is more tricky because often the energy in 4 or more FFT bins amounts to one partial. So firstly, you need to derive the partials from the FFT data, then you need to quantise the partials' frequencies. One possible cheat would be to trace the loudest FFT-bins and then transfer their energy to the bins whose frequencies are nearest to the harmonics of a given fundamental. If I'm not mistaken, at a sampling rate of 44100 and an FFT size of 4096, the frequency of bin 10 would be calculated as (44100/4096)*10=107.66. Just note that only FFT-size/2+1 bins are usable. That's the Nyquist frequency (half of the sampling frequency). If you take 107.66 as your fundamental (and zero all the bins below that) then you can do the following: For each analysis window... 1- Detect the next FFT bin whose magnitude is above a certain threshold 2- Transfer the frequency and amplitude content of this bin to the nearest harmonic of the fundamental. So for input bin 15 (and a fundamental frequency of 107.66) this would be bin 20. The bin number to frequency mapping is linear so it's easy to calculate. Even, using fiddle~, you can get the fundamental frequency from the input and have it change dynamically from window to window. You're likely to get some bubbly artefacts thought, but once you have a basic working patch you should be able to fine tune it. So you may want to group the bins so that you transfer not just the energy in one bin but also the bins around it. You might also want to do some averaging of the amplitude of 6 windows or so to avoid rapidly changing values, before you pass the signal into a threshold detector. I can do this in Csound but I'm not that familiar with how FFT works in PD and I don't have a patch that does this. If I get the time I might make one next weekend though and post it here. P *www.peimankhosravi.co.uk http://www.peimankhosravi.co.uk || RSS Feed http://peimankhosravi.co.uk/miscposts.rss || Concert News http://spectralkimia.wordpress.com/* On 26 November 2013 11:48, Eran Sachs eransa...@hotmail.com wrote: Peiman, It works great! I've been messing various sounds all day now, plus there's a thing in my computer with Barry Vercoe's name on it which I find oddly elevating. However, if I understand the wrap function correctly, it substitutes bin values for values of other bins through whatever function you apply. But the bins are still all derived from the FFT procedure. Or am I missing something there? What I would like to do is to move from bins to partials, so that they are essentially mapped to harmonic overtones of a given fundamental according to nearest match. Like a clever phase-vocoder Autotune of some kind. Is there a way to do that, to the best of anyone's knowledge? Much obliged, E. -- Date: Mon, 25 Nov 2013 15:12:50 + Subject: Re: [PD] spectral mapping, anyone? From: peimankhosr...@gmail.com To: eransa...@hotmail.com CC: por...@gmail.com; jaime.oliv...@gmail.com; pd-list@iem.at yes csound6 should work on windows too as far as I know. *www.peimankhosravi.co.uk http://www.peimankhosravi.co.uk || RSS Feed http://peimankhosravi.co.uk/miscposts.rss || Concert News http://spectralkimia.wordpress.com/* On 24
Re: [PD] spectral mapping, anyone?
haven't tried this warp thing, but will definately try it when I get the chance thanks! 2013/11/26 Eran Sachs eransa...@hotmail.com Peiman, It works great! I've been messing various sounds all day now, plus there's a thing in my computer with Barry Vercoe's name on it which I find oddly elevating. However, if I understand the wrap function correctly, it substitutes bin values for values of other bins through whatever function you apply. But the bins are still all derived from the FFT procedure. Or am I missing something there? What I would like to do is to move from bins to partials, so that they are essentially mapped to harmonic overtones of a given fundamental according to nearest match. Like a clever phase-vocoder Autotune of some kind. Is there a way to do that, to the best of anyone's knowledge? Much obliged, E. -- Date: Mon, 25 Nov 2013 15:12:50 + Subject: Re: [PD] spectral mapping, anyone? From: peimankhosr...@gmail.com To: eransa...@hotmail.com CC: por...@gmail.com; jaime.oliv...@gmail.com; pd-list@iem.at yes csound6 should work on windows too as far as I know. *www.peimankhosravi.co.uk http://www.peimankhosravi.co.uk || RSS Feed http://peimankhosravi.co.uk/miscposts.rss || Concert News http://spectralkimia.wordpress.com/* On 24 November 2013 22:06, Eran Sachs eransa...@hotmail.com wrote: Thanks Peiman. Alas, I'm living the life of a PC/Windows user. AFAICT, no csound6? Z -- Date: Sun, 24 Nov 2013 20:27:39 + Subject: Re: [PD] spectral mapping, anyone? From: peimankhosr...@gmail.com To: eransa...@hotmail.com CC: por...@gmail.com; jaime.oliv...@gmail.com; pd-list@iem.at With spectral warping you can do any frequency-based manipulation, depending on the transfer function. I have one for pd but it requires Csound to be installed and a couple of other externals. See attached. On an intel mac and with pd vanilla 4.5.3/4 this should just work out of the box as long as you have csound 6 installed. P *www.peimankhosravi.co.uk http://www.peimankhosravi.co.uk || RSS Feed http://peimankhosravi.co.uk/miscposts.rss || Concert News http://spectralkimia.wordpress.com/* On 24 November 2013 20:12, Eran Sachs eransa...@hotmail.com wrote: oops, I messed up the names. sorry. Once more, with feeling: Josep, Making harmonic sounds sound inharmonic can be down with spectral shifting. Try looking at Hilbert~ or at spec2_shift~ on extended. But Alexandre, I'd also would be interested in stuff that can manipulate the spectrum. I also made a little graphic control to all the cross-synthesis objects in FFTease. if anyone is interested I can post. A few years ago I tried to replicate the technique that Trevor Wishart refers to as Spectral Focusing, namely - one that moves the other way - from inharmonic to harmonic sonds, by moving from bins to partials (a little like FFTease's pvtune~, but moving bins to nearest matching partial ). I'm still looking for such an object. Does anyone have any suggestions? Zax. -- From: eransa...@hotmail.com To: por...@gmail.com; jaime.oliv...@gmail.com Date: Sun, 24 Nov 2013 21:58:50 +0200 CC: pd-list@iem.at Subject: Re: [PD] spectral mapping, anyone? Alexandre, Making harmonic sounds sound inharmonic can be down with spectral shifting. Try looking at Hilbert~ or at spec2_shift~ on extended. But Jaime, I'd also would be interested in that. A few years ago I tried to replicate the technique that Trevor Wishart refers to as Spectral Focusing, namely - one that moves the other way - from inharmonic to harmonic sonds, by moving from bins to partials (a little like FFTease's pvtune~, but moving bins to nearest matching partial ). I'm still looking for such an object. Does anyone have any suggestions? Zax. -- Date: Sun, 24 Nov 2013 01:05:29 -0200 From: por...@gmail.com To: jaime.oliv...@gmail.com CC: pd-list@iem.at Subject: Re: [PD] spectral mapping, anyone? Hi, I'm Alexandre, I can send you stuff cheers 2013/11/11 Jaime E Oliver jaime.oliv...@gmail.com These are older, but I understand E. Lyon might re-release them? http://www.somasa.qub.ac.uk/~elyon/LyonSoftware/MaxMSP/FFTease/ J On Nov 11, 2013, at 7:23 AM, Jeppi Jeppi jepp...@hotmail.com wrote: Hi, just looking for some ready to be used spectral mapping effects implemented in pd, anything available? Specifically, just a way to slightly remap harmonics to make pitched sounds inharmonic. There is a paper by Alexandre http://www.uni-weimar.de/medien/wiki/images/Dissonance_Model_Toolbox_in_Pure_Data.pdf but I couldn't find the link to the sources. Many thanks in advance! Josep m ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] spectral mapping, anyone?
Hi, I'm Alexandre, I can send you stuff cheers 2013/11/11 Jaime E Oliver jaime.oliv...@gmail.com These are older, but I understand E. Lyon might re-release them? http://www.somasa.qub.ac.uk/~elyon/LyonSoftware/MaxMSP/FFTease/ J On Nov 11, 2013, at 7:23 AM, Jeppi Jeppi jepp...@hotmail.com wrote: Hi, just looking for some ready to be used spectral mapping effects implemented in pd, anything available? Specifically, just a way to slightly remap harmonics to make pitched sounds inharmonic. There is a paper by Alexandre http://www.uni-weimar.de/medien/wiki/images/Dissonance_Model_Toolbox_in_Pure_Data.pdf but I couldn't find the link to the sources. Many thanks in advance! Josep m ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Cheap audio USB device with Raspberry PI -- works!
Anyway, I ended up buying this, tried it out, did the terminal tweaking, but... doesn't work properly at all :P what could I be missing? thanks 2013/5/21 Alexandre Torres Porres por...@gmail.com hi there, so I'm buying this thing. I dindt understand this last message. Anyway, did you see this thing handles AC-3 files. That's cool huh? Any of you use it in linux? Is there a way to use AC-3 in pd? That'd be cool. cheers 2013/5/5 Alexandre Castonguay acastong...@artengine.ca Hiya, I didn't see a post by André but yes, he told me the 'dwc_otg.speed=1 added to /boot/cmdline.txt' had no effect. ttys, a Le 2013-05-04 18:48, Alexandre Torres Porres a écrit : Yeah, Deal Extreme, Great, Free Shipping to Brazil :) 2013/4/30 me.grimm megr...@gmail.com That's without dwc_otg.speed=1 added to /boot/cmdline.txt *m* On Apr 30, 2013, at 5:08 PM, Julian Brooks jbee...@gmail.com wrote: Blimey:) Could be really useful for workshops etc. £1.81 and free shipping to U.K (takes a while tho', so plan ahead). Nice find. Julian On 30 April 2013 21:54, Max abonneme...@revolwear.com wrote: i've added this info to https://puredata.info/docs/raspberry-pi/FrontPage it has no vendor/brand name, but the model is: HY544 Am 30.04.2013 um 22:14 schrieb Alexandre Castonguay acastong...@artengine.ca: Hi all, This card works (audio i/o) with the Raspberry PI (Raspbian). You just need to type 'amixer -c 1 set Mic 80% cap' in a term window to enable to Mic. In PD, under preferences, choose 'Alsa' as output and under 'audio configuration', select 'input Generic AudioUSB Device (hardware) Channels 1' and 'output Generic USB Audio Device (plug-in) Channels 2'. This is the beast :-) - http://dx.com/p/usb-3d-sound-adapter-color-assorted-5831 (2.80 USD!) Have fun, * Merci à André Girard! Alexandre ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [biquad~] as cyclone's [allpass~]?
awesome, thanks a lot, really helpful. I was suspecting something like that, but couldn't get to this implementation. And then, one question, doesn't the feedback given by tabsend theoretically count as a second delay line? cheers 2013/10/6 Mike Moser-Booth mmoserbo...@gmail.com It's not that either implementation is wrong, they are just two ways of doing the same thing. The version that uses two delay lines is the Direct Form I. By doing some rearranging of the filter, you convert it to the Direct Form II, which only uses one delay line. The end results are the same, just one is more efficient. Look inside [pd allpass] in the attached patch for an ASCII art illustration of it. On Sat, Oct 5, 2013 at 3:35 PM, Alexandre Torres Porres por...@gmail.comwrote: on curtis roads' computer music tutorial, page 418, it shows the same formula, but the figure of the design seems to contradict it. I'm confused. I don't seem to get the same result with one delay line. maybe if you send me a patch that sounds the same as cyclone's allpass I can check it. cheers 2013/10/5 Alexandre Torres Porres por...@gmail.com i dont think there is one way or proper way of doing this, and it is a general form, from an equation you can find in other references. So, I don't know why, but Max/Cyclone's allpass use this one: y(n) = -g x(n) + x(n)-(DR/1000) + g y(n)-(DR/1000) 2013/10/5 Chris Clepper cgclep...@gmail.com That means cyclone's allpass~ is not done properly. Why not do it the standard and more efficient way? When it comes time to do dozens of allpasses it will make a difference. On Sat, Oct 5, 2013 at 1:00 PM, Alexandre Torres Porres por...@gmail.com wrote: but this way it won't be the same as cyclone's [allpass~], the way I did it is equivalent to it (and max's). cheers 2013/10/3 Chris Clepper cgclep...@gmail.com You only need one delay line for the allpass. feedforward = input * -gain feedback = delayout * gain delayin = input + feedback output = delayout + feedforward http://www.spinsemi.com/knowledge_base/effects.html#Reverberation On Thu, Oct 3, 2013 at 11:29 AM, Alexandre Torres Porres por...@gmail.com wrote: i hope i guess i figured it out on how to implement it with delay lines. see attachment. And I realize you can't do this with [fexpr~] or [biquad~] because the sample delay length is kinda big for that, right? cheers 2013/10/3 Alexandre Torres Porres por...@gmail.com cool, but do you know how to implement cyclone's [allpass~] with it? It's really unclear to me what is the relation of this pass filter with the one you can generate with biquad coefficients, or with raw poles/zeros objects for that matter. Well, one way or another, it's also unclear to me how to do it with delay lines. seems that it is related to a comb filter, right? cheers 2013/10/2 Chris Clepper cgclep...@gmail.com Allpass for reverb is easy to do with delwrite~ and vd~. I used 32 of them today to recreate a famous 'deep space' reverb. On Wed, Oct 2, 2013 at 1:53 AM, Alexandre Torres Porres por...@gmail.com wrote: hi there, i see the biquad's coefficients can be set as an allpass filter, generated by frequency and Q parameters. But can it do the same as cyclone's [allpass~] filer? If yes, them how since the parameters for [allpass~] are different (delaytime and such). One way or another, I guess that my real question is: how to implement [allpass~] from vanilla objects? thanks ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [biquad~] as cyclone's [allpass~]?
cool, could you readapt the patch then? I'd appreciate that a lot as I'm just not being able to nail it. It'd be really careful. Thanks 2013/10/6 Mike Moser-Booth mmoserbo...@gmail.com Yeah, I tend to use them for feedback loops because they only need to be the block size. Though now that I think about it, you don't need them in this case. You can just feed [vd~] in to [delwrite~] without that silly order forcing I did. .mmb On Sun, Oct 6, 2013 at 8:43 PM, Alexandre Torres Porres por...@gmail.comwrote: awesome, thanks a lot, really helpful. I was suspecting something like that, but couldn't get to this implementation. And then, one question, doesn't the feedback given by tabsend theoretically count as a second delay line? cheers 2013/10/6 Mike Moser-Booth mmoserbo...@gmail.com It's not that either implementation is wrong, they are just two ways of doing the same thing. The version that uses two delay lines is the Direct Form I. By doing some rearranging of the filter, you convert it to the Direct Form II, which only uses one delay line. The end results are the same, just one is more efficient. Look inside [pd allpass] in the attached patch for an ASCII art illustration of it. On Sat, Oct 5, 2013 at 3:35 PM, Alexandre Torres Porres por...@gmail.com wrote: on curtis roads' computer music tutorial, page 418, it shows the same formula, but the figure of the design seems to contradict it. I'm confused. I don't seem to get the same result with one delay line. maybe if you send me a patch that sounds the same as cyclone's allpass I can check it. cheers 2013/10/5 Alexandre Torres Porres por...@gmail.com i dont think there is one way or proper way of doing this, and it is a general form, from an equation you can find in other references. So, I don't know why, but Max/Cyclone's allpass use this one: y(n) = -g x(n) + x(n)-(DR/1000) + g y(n)-(DR/1000) 2013/10/5 Chris Clepper cgclep...@gmail.com That means cyclone's allpass~ is not done properly. Why not do it the standard and more efficient way? When it comes time to do dozens of allpasses it will make a difference. On Sat, Oct 5, 2013 at 1:00 PM, Alexandre Torres Porres por...@gmail.com wrote: but this way it won't be the same as cyclone's [allpass~], the way I did it is equivalent to it (and max's). cheers 2013/10/3 Chris Clepper cgclep...@gmail.com You only need one delay line for the allpass. feedforward = input * -gain feedback = delayout * gain delayin = input + feedback output = delayout + feedforward http://www.spinsemi.com/knowledge_base/effects.html#Reverberation On Thu, Oct 3, 2013 at 11:29 AM, Alexandre Torres Porres por...@gmail.com wrote: i hope i guess i figured it out on how to implement it with delay lines. see attachment. And I realize you can't do this with [fexpr~] or [biquad~] because the sample delay length is kinda big for that, right? cheers 2013/10/3 Alexandre Torres Porres por...@gmail.com cool, but do you know how to implement cyclone's [allpass~] with it? It's really unclear to me what is the relation of this pass filter with the one you can generate with biquad coefficients, or with raw poles/zeros objects for that matter. Well, one way or another, it's also unclear to me how to do it with delay lines. seems that it is related to a comb filter, right? cheers 2013/10/2 Chris Clepper cgclep...@gmail.com Allpass for reverb is easy to do with delwrite~ and vd~. I used 32 of them today to recreate a famous 'deep space' reverb. On Wed, Oct 2, 2013 at 1:53 AM, Alexandre Torres Porres por...@gmail.com wrote: hi there, i see the biquad's coefficients can be set as an allpass filter, generated by frequency and Q parameters. But can it do the same as cyclone's [allpass~] filer? If yes, them how since the parameters for [allpass~] are different (delaytime and such). One way or another, I guess that my real question is: how to implement [allpass~] from vanilla objects? thanks ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [biquad~] as cyclone's [allpass~]?
but this way it won't be the same as cyclone's [allpass~], the way I did it is equivalent to it (and max's). cheers 2013/10/3 Chris Clepper cgclep...@gmail.com You only need one delay line for the allpass. feedforward = input * -gain feedback = delayout * gain delayin = input + feedback output = delayout + feedforward http://www.spinsemi.com/knowledge_base/effects.html#Reverberation On Thu, Oct 3, 2013 at 11:29 AM, Alexandre Torres Porres por...@gmail.com wrote: i hope i guess i figured it out on how to implement it with delay lines. see attachment. And I realize you can't do this with [fexpr~] or [biquad~] because the sample delay length is kinda big for that, right? cheers 2013/10/3 Alexandre Torres Porres por...@gmail.com cool, but do you know how to implement cyclone's [allpass~] with it? It's really unclear to me what is the relation of this pass filter with the one you can generate with biquad coefficients, or with raw poles/zeros objects for that matter. Well, one way or another, it's also unclear to me how to do it with delay lines. seems that it is related to a comb filter, right? cheers 2013/10/2 Chris Clepper cgclep...@gmail.com Allpass for reverb is easy to do with delwrite~ and vd~. I used 32 of them today to recreate a famous 'deep space' reverb. On Wed, Oct 2, 2013 at 1:53 AM, Alexandre Torres Porres por...@gmail.com wrote: hi there, i see the biquad's coefficients can be set as an allpass filter, generated by frequency and Q parameters. But can it do the same as cyclone's [allpass~] filer? If yes, them how since the parameters for [allpass~] are different (delaytime and such). One way or another, I guess that my real question is: how to implement [allpass~] from vanilla objects? thanks ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] [biquad~] as max's phaseshift? (was [biquad~] as cyclone's [allpass~]?)
Anyway, next on my list is finding out how to implement max's [phaseshift~], which is also an allpass filter. There's no Pd clone for it so it seems, right? Well, it doesn't really what it is other than a 2nd order filter. From that I could think you can generate it with [biquad~], but the phase response given in phaseshift's help file suggest otherwise. any contributions welcome thanks a lot 2013/10/5 Alexandre Torres Porres por...@gmail.com but this way it won't be the same as cyclone's [allpass~], the way I did it is equivalent to it (and max's). cheers 2013/10/3 Chris Clepper cgclep...@gmail.com You only need one delay line for the allpass. feedforward = input * -gain feedback = delayout * gain delayin = input + feedback output = delayout + feedforward http://www.spinsemi.com/knowledge_base/effects.html#Reverberation On Thu, Oct 3, 2013 at 11:29 AM, Alexandre Torres Porres por...@gmail.com wrote: i hope i guess i figured it out on how to implement it with delay lines. see attachment. And I realize you can't do this with [fexpr~] or [biquad~] because the sample delay length is kinda big for that, right? cheers 2013/10/3 Alexandre Torres Porres por...@gmail.com cool, but do you know how to implement cyclone's [allpass~] with it? It's really unclear to me what is the relation of this pass filter with the one you can generate with biquad coefficients, or with raw poles/zeros objects for that matter. Well, one way or another, it's also unclear to me how to do it with delay lines. seems that it is related to a comb filter, right? cheers 2013/10/2 Chris Clepper cgclep...@gmail.com Allpass for reverb is easy to do with delwrite~ and vd~. I used 32 of them today to recreate a famous 'deep space' reverb. On Wed, Oct 2, 2013 at 1:53 AM, Alexandre Torres Porres por...@gmail.com wrote: hi there, i see the biquad's coefficients can be set as an allpass filter, generated by frequency and Q parameters. But can it do the same as cyclone's [allpass~] filer? If yes, them how since the parameters for [allpass~] are different (delaytime and such). One way or another, I guess that my real question is: how to implement [allpass~] from vanilla objects? thanks ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [biquad~] as cyclone's [allpass~]?
i dont think there is one way or proper way of doing this, and it is a general form, from an equation you can find in other references. So, I don't know why, but Max/Cyclone's allpass use this one: y(n) = -g x(n) + x(n)-(DR/1000) + g y(n)-(DR/1000) 2013/10/5 Chris Clepper cgclep...@gmail.com That means cyclone's allpass~ is not done properly. Why not do it the standard and more efficient way? When it comes time to do dozens of allpasses it will make a difference. On Sat, Oct 5, 2013 at 1:00 PM, Alexandre Torres Porres por...@gmail.comwrote: but this way it won't be the same as cyclone's [allpass~], the way I did it is equivalent to it (and max's). cheers 2013/10/3 Chris Clepper cgclep...@gmail.com You only need one delay line for the allpass. feedforward = input * -gain feedback = delayout * gain delayin = input + feedback output = delayout + feedforward http://www.spinsemi.com/knowledge_base/effects.html#Reverberation On Thu, Oct 3, 2013 at 11:29 AM, Alexandre Torres Porres por...@gmail.com wrote: i hope i guess i figured it out on how to implement it with delay lines. see attachment. And I realize you can't do this with [fexpr~] or [biquad~] because the sample delay length is kinda big for that, right? cheers 2013/10/3 Alexandre Torres Porres por...@gmail.com cool, but do you know how to implement cyclone's [allpass~] with it? It's really unclear to me what is the relation of this pass filter with the one you can generate with biquad coefficients, or with raw poles/zeros objects for that matter. Well, one way or another, it's also unclear to me how to do it with delay lines. seems that it is related to a comb filter, right? cheers 2013/10/2 Chris Clepper cgclep...@gmail.com Allpass for reverb is easy to do with delwrite~ and vd~. I used 32 of them today to recreate a famous 'deep space' reverb. On Wed, Oct 2, 2013 at 1:53 AM, Alexandre Torres Porres por...@gmail.com wrote: hi there, i see the biquad's coefficients can be set as an allpass filter, generated by frequency and Q parameters. But can it do the same as cyclone's [allpass~] filer? If yes, them how since the parameters for [allpass~] are different (delaytime and such). One way or another, I guess that my real question is: how to implement [allpass~] from vanilla objects? thanks ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [biquad~] as max's phaseshift? (was [biquad~] as cyclone's [allpass~]?)
the phase response given in phaseshift's help file suggest otherwise. it's more like the response from miller's H14 example... So I guess you can have a 2nd order one (lie phaseshift) by putting two of these together, right? And I suspect it doesn't really need to have anything to do biquad just for being 2nd order, huh? cheers 2013/10/5 Alexandre Torres Porres por...@gmail.com Anyway, next on my list is finding out how to implement max's [phaseshift~], which is also an allpass filter. There's no Pd clone for it so it seems, right? Well, it doesn't really what it is other than a 2nd order filter. From that I could think you can generate it with [biquad~], but the phase response given in phaseshift's help file suggest otherwise. any contributions welcome thanks a lot 2013/10/5 Alexandre Torres Porres por...@gmail.com but this way it won't be the same as cyclone's [allpass~], the way I did it is equivalent to it (and max's). cheers 2013/10/3 Chris Clepper cgclep...@gmail.com You only need one delay line for the allpass. feedforward = input * -gain feedback = delayout * gain delayin = input + feedback output = delayout + feedforward http://www.spinsemi.com/knowledge_base/effects.html#Reverberation On Thu, Oct 3, 2013 at 11:29 AM, Alexandre Torres Porres por...@gmail.com wrote: i hope i guess i figured it out on how to implement it with delay lines. see attachment. And I realize you can't do this with [fexpr~] or [biquad~] because the sample delay length is kinda big for that, right? cheers 2013/10/3 Alexandre Torres Porres por...@gmail.com cool, but do you know how to implement cyclone's [allpass~] with it? It's really unclear to me what is the relation of this pass filter with the one you can generate with biquad coefficients, or with raw poles/zeros objects for that matter. Well, one way or another, it's also unclear to me how to do it with delay lines. seems that it is related to a comb filter, right? cheers 2013/10/2 Chris Clepper cgclep...@gmail.com Allpass for reverb is easy to do with delwrite~ and vd~. I used 32 of them today to recreate a famous 'deep space' reverb. On Wed, Oct 2, 2013 at 1:53 AM, Alexandre Torres Porres por...@gmail.com wrote: hi there, i see the biquad's coefficients can be set as an allpass filter, generated by frequency and Q parameters. But can it do the same as cyclone's [allpass~] filer? If yes, them how since the parameters for [allpass~] are different (delaytime and such). One way or another, I guess that my real question is: how to implement [allpass~] from vanilla objects? thanks ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [biquad~] as cyclone's [allpass~]?
on curtis roads' computer music tutorial, page 418, it shows the same formula, but the figure of the design seems to contradict it. I'm confused. I don't seem to get the same result with one delay line. maybe if you send me a patch that sounds the same as cyclone's allpass I can check it. cheers 2013/10/5 Alexandre Torres Porres por...@gmail.com i dont think there is one way or proper way of doing this, and it is a general form, from an equation you can find in other references. So, I don't know why, but Max/Cyclone's allpass use this one: y(n) = -g x(n) + x(n)-(DR/1000) + g y(n)-(DR/1000) 2013/10/5 Chris Clepper cgclep...@gmail.com That means cyclone's allpass~ is not done properly. Why not do it the standard and more efficient way? When it comes time to do dozens of allpasses it will make a difference. On Sat, Oct 5, 2013 at 1:00 PM, Alexandre Torres Porres por...@gmail.com wrote: but this way it won't be the same as cyclone's [allpass~], the way I did it is equivalent to it (and max's). cheers 2013/10/3 Chris Clepper cgclep...@gmail.com You only need one delay line for the allpass. feedforward = input * -gain feedback = delayout * gain delayin = input + feedback output = delayout + feedforward http://www.spinsemi.com/knowledge_base/effects.html#Reverberation On Thu, Oct 3, 2013 at 11:29 AM, Alexandre Torres Porres por...@gmail.com wrote: i hope i guess i figured it out on how to implement it with delay lines. see attachment. And I realize you can't do this with [fexpr~] or [biquad~] because the sample delay length is kinda big for that, right? cheers 2013/10/3 Alexandre Torres Porres por...@gmail.com cool, but do you know how to implement cyclone's [allpass~] with it? It's really unclear to me what is the relation of this pass filter with the one you can generate with biquad coefficients, or with raw poles/zeros objects for that matter. Well, one way or another, it's also unclear to me how to do it with delay lines. seems that it is related to a comb filter, right? cheers 2013/10/2 Chris Clepper cgclep...@gmail.com Allpass for reverb is easy to do with delwrite~ and vd~. I used 32 of them today to recreate a famous 'deep space' reverb. On Wed, Oct 2, 2013 at 1:53 AM, Alexandre Torres Porres por...@gmail.com wrote: hi there, i see the biquad's coefficients can be set as an allpass filter, generated by frequency and Q parameters. But can it do the same as cyclone's [allpass~] filer? If yes, them how since the parameters for [allpass~] are different (delaytime and such). One way or another, I guess that my real question is: how to implement [allpass~] from vanilla objects? thanks ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [biquad~] as max's phaseshift? (was [biquad~] as cyclone's [allpass~]?)
hi mmb, thanks for showing up :) h, my problem was that the phase response graph generated from your Pd patch based on RBJ looks different than the one from max's phaseshift. But it just occurred to me that one thing about it might only be a matter of normalizing it and displaying in the same way. For example, your patch gives us a drop from 0 to -1 and then from 1 to 0, while phaseshift in Max is from 0 to -2pi continuously. I'm now considering that both behaviours could be related, only that your patch wraps it around -1 back to 1. What do you think? But even so, there's also the issue of getting the Q parameter to behave in the same way. Max's phaseshift, when set to Q = 0.1 and freq = 4KHz will give you a linear drop from 0 to -2pi. Now, I can't seem to get that based on RBJ's cookbook formulas and your patch. But then, another thing I haven't thought of might be a difference in the scale plot... One way or another, the Q parameter seems off. So, as you can see, there are these plotting differences, but I know what you mean, that is what I was suspecting too, it sure looks like the same thing at a first glance, meaning you can get to it from a biquad coefficient perspective. The problem is that max's phaseshift isn't very clear about what it really is, other than saying it is a second order filter. But that doesn't have to imply it is the same as a second order biquad, does it? Thanks 2013/10/5 Mike Moser-Booth mmoserbo...@gmail.com From looking at the helpfile for [phaseshift~], this sounds very much like the all-pass filter from Robert Bristow-Johnson's EQ Cookbook. You can calculate the biquad coefficients for it like this: w0 = 2*pi*frequency_in_Hz / sample_rate alpha = sin(w0)*sinh(ln(2)/2*Q*w0/sin(w0)) fb1 = 2*cos(w0) / (1+alpha) fb2 = (-1+alpha) / (1+alpha) ff1 = -fb2 ff2 = -fb1 ff3 = 1 .mmb On Sat, Oct 5, 2013 at 12:31 PM, Alexandre Torres Porres por...@gmail.com wrote: the phase response given in phaseshift's help file suggest otherwise. it's more like the response from miller's H14 example... So I guess you can have a 2nd order one (lie phaseshift) by putting two of these together, right? And I suspect it doesn't really need to have anything to do biquad just for being 2nd order, huh? cheers 2013/10/5 Alexandre Torres Porres por...@gmail.com Anyway, next on my list is finding out how to implement max's [phaseshift~], which is also an allpass filter. There's no Pd clone for it so it seems, right? Well, it doesn't really what it is other than a 2nd order filter. From that I could think you can generate it with [biquad~], but the phase response given in phaseshift's help file suggest otherwise. any contributions welcome thanks a lot 2013/10/5 Alexandre Torres Porres por...@gmail.com but this way it won't be the same as cyclone's [allpass~], the way I did it is equivalent to it (and max's). cheers 2013/10/3 Chris Clepper cgclep...@gmail.com You only need one delay line for the allpass. feedforward = input * -gain feedback = delayout * gain delayin = input + feedback output = delayout + feedforward http://www.spinsemi.com/knowledge_base/effects.html#Reverberation On Thu, Oct 3, 2013 at 11:29 AM, Alexandre Torres Porres por...@gmail.com wrote: i hope i guess i figured it out on how to implement it with delay lines. see attachment. And I realize you can't do this with [fexpr~] or [biquad~] because the sample delay length is kinda big for that, right? cheers 2013/10/3 Alexandre Torres Porres por...@gmail.com cool, but do you know how to implement cyclone's [allpass~] with it? It's really unclear to me what is the relation of this pass filter with the one you can generate with biquad coefficients, or with raw poles/zeros objects for that matter. Well, one way or another, it's also unclear to me how to do it with delay lines. seems that it is related to a comb filter, right? cheers 2013/10/2 Chris Clepper cgclep...@gmail.com Allpass for reverb is easy to do with delwrite~ and vd~. I used 32 of them today to recreate a famous 'deep space' reverb. On Wed, Oct 2, 2013 at 1:53 AM, Alexandre Torres Porres por...@gmail.com wrote: hi there, i see the biquad's coefficients can be set as an allpass filter, generated by frequency and Q parameters. But can it do the same as cyclone's [allpass~] filer? If yes, them how since the parameters for [allpass~] are different (delaytime and such). One way or another, I guess that my real question is: how to implement [allpass~] from vanilla objects? thanks ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list
Re: [PD] [biquad~] as cyclone's [allpass~]?
i hope i guess i figured it out on how to implement it with delay lines. see attachment. And I realize you can't do this with [fexpr~] or [biquad~] because the sample delay length is kinda big for that, right? cheers 2013/10/3 Alexandre Torres Porres por...@gmail.com cool, but do you know how to implement cyclone's [allpass~] with it? It's really unclear to me what is the relation of this pass filter with the one you can generate with biquad coefficients, or with raw poles/zeros objects for that matter. Well, one way or another, it's also unclear to me how to do it with delay lines. seems that it is related to a comb filter, right? cheers 2013/10/2 Chris Clepper cgclep...@gmail.com Allpass for reverb is easy to do with delwrite~ and vd~. I used 32 of them today to recreate a famous 'deep space' reverb. On Wed, Oct 2, 2013 at 1:53 AM, Alexandre Torres Porres por...@gmail.com wrote: hi there, i see the biquad's coefficients can be set as an allpass filter, generated by frequency and Q parameters. But can it do the same as cyclone's [allpass~] filer? If yes, them how since the parameters for [allpass~] are different (delaytime and such). One way or another, I guess that my real question is: how to implement [allpass~] from vanilla objects? thanks ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list allpass.pd Description: Binary data ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] [biquad~] as cyclone's [allpass~]?
cool, but do you know how to implement cyclone's [allpass~] with it? It's really unclear to me what is the relation of this pass filter with the one you can generate with biquad coefficients, or with raw poles/zeros objects for that matter. Well, one way or another, it's also unclear to me how to do it with delay lines. seems that it is related to a comb filter, right? cheers 2013/10/2 Chris Clepper cgclep...@gmail.com Allpass for reverb is easy to do with delwrite~ and vd~. I used 32 of them today to recreate a famous 'deep space' reverb. On Wed, Oct 2, 2013 at 1:53 AM, Alexandre Torres Porres por...@gmail.comwrote: hi there, i see the biquad's coefficients can be set as an allpass filter, generated by frequency and Q parameters. But can it do the same as cyclone's [allpass~] filer? If yes, them how since the parameters for [allpass~] are different (delaytime and such). One way or another, I guess that my real question is: how to implement [allpass~] from vanilla objects? thanks ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] [biquad~] as cyclone's [allpass~]?
hi there, i see the biquad's coefficients can be set as an allpass filter, generated by frequency and Q parameters. But can it do the same as cyclone's [allpass~] filer? If yes, them how since the parameters for [allpass~] are different (delaytime and such). One way or another, I guess that my real question is: how to implement [allpass~] from vanilla objects? thanks ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] from poles/zeros to biquad coefficients - how to? (something like max's z-plane)
This is the online tool: http://kmt.hku.nl/~pieter/cgi-bin/resp/nph-PZT.cgi. damn, it says it cant load it here :P but this seems like a simple formula to try out, from what you copied here. If that's all, and if I got what it means, I can see a patch coming right now :) let's see! thanks 2013/9/24 Funs Seelen funssee...@gmail.com Hi Alexandre, This is the online tool: http://kmt.hku.nl/~pieter/cgi-bin/resp/nph-PZT.cgi. It starts with an example and every time you refresh the page it gives you a new one. If you scroll down there's a link that tells you how the coefficients were calculated, e.g.: 2 zeros give 3 coefficients: *a0* = G *a1* = -G(Z0 + Z1) *a2* = G(Z0*Z1) 2 poles give 3 coefficients: *b0* = 1 *b1* = -(P0 + P1) *b2* = (P0*P1) The linear difference equation is derived from these as you can see. Regards, --Funs On Tue, Sep 24, 2013 at 7:36 AM, Alexandre Torres Porres por...@gmail.com wrote: for what i see, it's not some sort of straight formula, right? seems a bit more complicated than that. cheers 2013/9/23 Funs Seelen funssee...@gmail.com On Mon, Sep 23, 2013 at 5:35 PM, Alexandre Torres Porres por...@gmail.com wrote: thanks, here's a pic of what I have so far https://fbcdn-sphotos-g-a.akamaihd.net/hphotos-ak-prn1/11212_10151872996046683_1825736206_n.jpg Cool. For extra inspiration you could have a look at PoZeTools It sure does look like what I need. Thanks. But extracting what I need to know about the math of converting from coordinates to coefficients was just over my head :P unfortunately, sorry. I was hoping for something simpler, like just the operations needed. If the info is in code, I need it to more explicit. I'd really appreciate if anyone knows how to read from this and just points it out for me so I can put it in a patch. I'm assuming it's rather simple math I remember I once learned how to do this but never repeated the practice. If I find time to do that I would gladly try to figure it out again, but if someone more experienced feels the urge to chime in before that time I would be very happy too :). ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] from poles/zeros to biquad coefficients - how to? (something like max's z-plane)
one doubt emerges really soon anyway. Since they are complex (there are two coordinate numbers for each pole and zero) how do I get only one number by, for example, summing or multiplying one pole to the other? as in: *b1* = -(P0 + P1) *b2* = (P0*P1) cheers! 2013/9/24 Alexandre Torres Porres por...@gmail.com This is the online tool: http://kmt.hku.nl/~pieter/cgi-bin/resp/nph-PZT.cgi. damn, it says it cant load it here :P but this seems like a simple formula to try out, from what you copied here. If that's all, and if I got what it means, I can see a patch coming right now :) let's see! thanks 2013/9/24 Funs Seelen funssee...@gmail.com Hi Alexandre, This is the online tool: http://kmt.hku.nl/~pieter/cgi-bin/resp/nph-PZT.cgi. It starts with an example and every time you refresh the page it gives you a new one. If you scroll down there's a link that tells you how the coefficients were calculated, e.g.: 2 zeros give 3 coefficients: *a0* = G *a1* = -G(Z0 + Z1) *a2* = G(Z0*Z1) 2 poles give 3 coefficients: *b0* = 1 *b1* = -(P0 + P1) *b2* = (P0*P1) The linear difference equation is derived from these as you can see. Regards, --Funs On Tue, Sep 24, 2013 at 7:36 AM, Alexandre Torres Porres por...@gmail.com wrote: for what i see, it's not some sort of straight formula, right? seems a bit more complicated than that. cheers 2013/9/23 Funs Seelen funssee...@gmail.com On Mon, Sep 23, 2013 at 5:35 PM, Alexandre Torres Porres por...@gmail.com wrote: thanks, here's a pic of what I have so far https://fbcdn-sphotos-g-a.akamaihd.net/hphotos-ak-prn1/11212_10151872996046683_1825736206_n.jpg Cool. For extra inspiration you could have a look at PoZeTools It sure does look like what I need. Thanks. But extracting what I need to know about the math of converting from coordinates to coefficients was just over my head :P unfortunately, sorry. I was hoping for something simpler, like just the operations needed. If the info is in code, I need it to more explicit. I'd really appreciate if anyone knows how to read from this and just points it out for me so I can put it in a patch. I'm assuming it's rather simple math I remember I once learned how to do this but never repeated the practice. If I find time to do that I would gladly try to figure it out again, but if someone more experienced feels the urge to chime in before that time I would be very happy too :). ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list