<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><br></div><div>I'll check out the settings. &nbsp;As for running this, its a script, you can just run it on the Terminal. &nbsp;On GNU/Linux, it should just work. &nbsp;On Mac OS X, you'll probably need to have run it like this:</div><div><br></div><div>/usr/bin/wish filterview.tcl</div><div><br></div><div>.hc</div><br><div><div>On Feb 7, 2011, at 11:20 PM, Mike Moser-Booth wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite">I don't really know how to test this and I don't really know tcl, but I tried looking at the code to see if I could make some sense of it anyway, because why the hell not. ;-) Anyway, the only part I really understood was the calculation of the coefficients, and I noticed something wrong. You are calculating alpha for bandwidth instead of Q. I'm guessing you're just borrowing what is in the ggee externals (given the code's comments), because it's done the same way there, but it's not really conventional for a lowpass filter. That's really more for bandpass, notch, and peaking filters. Using Q is also a simpler calculation: alpha = sin(omega)/(2*Q). With Q set to .7071 (or -3 dBfs), you have a filter with no resonance, which makes sense because the cutoff frequency for a lowpass filter is defined as the frequency where the response falls be 3 dB. This is also how Max's [filtergraph~] works.<div> <br></div><div>It's all defined here in Robert Bristow-Johnson's Cookbook:</div><div><br></div><div><a href="http://www.musicdsp.org/files/Audio-EQ-Cookbook.txt">http://www.musicdsp.org/files/Audio-EQ-Cookbook.txt</a></div> <div><br></div><div>The ggee externals, as far as I can tell, are all based on this cookbook, though with mistakes like using BW instead of Q.</div><div><br></div><div>Hope that helps,</div><div>.mmb<br><br><div class="gmail_quote"> On Mon, Feb 7, 2011 at 10:03 PM, Hans-Christoph Steiner <span dir="ltr">&lt;<a href="mailto:hans@at.or.at">hans@at.or.at</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"> <div class="im"><br> On Feb 7, 2011, at 8:35 PM, Spencer Russell wrote:<br> <br> <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"> On Sun, Feb 6, 2011 at 11:15 PM, Mathieu Bouchard &lt;<a href="mailto:matju@artengine.ca" target="_blank">matju@artengine.ca</a>&gt; wrote:<br> <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"> On Sun, 6 Feb 2011, Spencer Russell wrote:<br> <br> <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"> [1] gives the magnitude frequency response given the biquad<br> coefficents, and it linked to from several places around the net. Is<br> this the sort of thing you're looking for?<br> [1] <a href="http://bit.ly/eFck4j" target="_blank">http://bit.ly/eFck4j</a><br> </blockquote> <br> This link got me directly to :<br> <br> &nbsp;USB complete: everything you need to develop custom USB peripherals<br> &nbsp;Par Jan Axelson<br> &nbsp;Chapitre 12<br> &nbsp;Page 364<br> <br> and nothing else. (??)<br> <br> </blockquote> <br> Whoops, I meant to send this: <a href="http://bit.ly/gUCBu4" target="_blank">http://bit.ly/gUCBu4</a>. Sorry.<br> <br> Here he's basically just taken the transfer function of a biquad and<br> made the z = exp(j*w/Fs) as Mike suggested, followed by taking the<br> magnitude and log-scaling for dB, but he's done the algebraic legwork.<br> Just note that w (lower-case omega) is 2*pi*f and you should be good<br> to go. He's also done some trig-substitution for more numerical<br> precision.<br> </blockquote> <br></div> I'm making good progress, but now am getting lost in the filter math meeting the pixel math. &nbsp;Can someone mathy check my math? &nbsp;Or even try it out?<div class="im"><br> <br> <a href="https://github.com/pd-projects/filterview" target="_blank">https://github.com/pd-projects/filterview</a><br> <br> .hc<br> <br> <br> ----------------------------------------------------------------------------<br> <br></div> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;ˇEl pueblo unido jamás será vencido!<div><div></div><div class="h5"><br> <br> <br> <br> _______________________________________________<br> <a href="mailto:Pd-list@iem.at" target="_blank">Pd-list@iem.at</a> mailing list<br> UNSUBSCRIBE and account-management -&gt; <a href="http://lists.puredata.info/listinfo/pd-list" target="_blank">http://lists.puredata.info/listinfo/pd-list</a><br> </div></div></blockquote></div><br><br clear="all"><br>-- <br>Mike Moser-Booth<br><a href="mailto:mmoserbooth@gmail.com">mmoserbooth@gmail.com</a><br> </div></blockquote></div><br><div apple-content-edited="true"> <span class="Apple-style-span" style="font-size: 12px; "><div><br class="Apple-interchange-newline">----------------------------------------------------------------------------<br></div></span><div><br></div><div>"A cellphone to me is just an opportunity to be irritated wherever you are." - Linus Torvalds</div> </div><br></body></html>