<div dir="ltr"><div><div><div><div><div><div>Hi !<br><br></div><div>Thank you Peter for checking the source code !<br><br>Yes I could change my sampling rate.<br></div><div>But, well, I think it's better if pd is able work at different sampling rates, and many standards now prefer 48KHz to 44.1<br></div> (i.e. digital video recorders).<br><br></div>For now, i'll just make a trick/abstraction that gets the working sampling rate with [samplerate~] and corrects the frequency parameter by applying a coefficient (* 44100 / SR)...<br><br></div>However, IMHO, since frequency representation is related to the time and not the sampling rate, I think this should be corrected in the object itself, maybe as Alexandros suggested.<br></div>But I don't have the skills to do that myself... hope Günther will read this.<br><br></div>have a nice day,<br><br></div>Raphaël<br><div><div><div><br><div><br></div></div></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">2015-05-03 5:32 GMT+02:00 Peter P. <span dir="ltr"><<a href="mailto:peterparker@fastmail.com" target="_blank">peterparker@fastmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">* Raphaël Ilias <<a href="mailto:phae.ilias@gmail.com">phae.ilias@gmail.com</a>> [2015-05-02 16:36]:<br>
<div><div class="h5">> Hello,<br>
><br>
> I was testing the [bandpass] and [notch] object's from "ggee" library,<br>
> which compute coefficients values for vanilla's [biquad~] and discovered<br>
> that the center frequency wasn't the one expected, but was shifted<br>
> something like 10%.<br>
><br>
> After a few measurement I found that the real center frequency was around<br>
> 1.08841 upwards the ferquency value set to [bandpass] or to [notch]<br>
> inlets...<br>
><br>
> ...and I later realized that 48000/44100 = 1.088435... and that on my<br>
> computer, pd is working at 48000 Hz.<br>
> So, apparently these objects are calculating the coefficients with an<br>
> supposed samplerate of 44100 Hz.<br>
<br>
</div></div>You are right. I just looked at the source file for one of these<br>
objects, and it contains a line<br>
<br>
x->x_rate = 44100.0;<br>
<br>
So apparently the sample rate for it is hard-coded. I don't know ir<br>
Günther is actively monitoring the pd-list, but perhaps someone else<br>
here might know how to get that code to be more responsive to different<br>
sampling rates...<br>
(you could change your sampling rate to 44100 in the meantime though,<br>
Raphaël)<br>
best, P<br>
</blockquote></div><br></div>