Csound Csound-dev Csound-tekno Search About

tdf2 biquad

Date2016-04-22 02:44
FromSteven Yi
Subjecttdf2 biquad
Hi All,

I was recently looking at filter code and and implemented a UDO called
tdf2 that uses the Transposed Direct Form II version of the biquad.
It is available at:

https://github.com/kunstmusik/libsyi

There's an .inc file that has the UDO and a test csd files in the
tests folder.  It's a translation of Nigel Redmon's C++ code available
at:

http://www.earlevel.com/main/2012/11/26/biquad-c-source-code/

The tdf2 UDO has the following arguments:

   INPUT
     asig - input signal
     ifilter_type - filter type:
        0 - Low Pass
        1 - High Pass
        2 - Band Pass
        3 - Notch
        4 - Peaking
        5 - Low Shelf
        6 - High Shelf
     acutoff - cutoff frequency
     aQ - Q value
     again - gain (used by peaking, low shelf, and high shelf)


All inputs besides filter_type are a-rate.  If you want to pass in a
constant value, you can use a(value) as the argument.

Any comments, feedback, and bug reports are welcome.

Also, I have posted some UDOs over the past years here to the list.  I
am planning to include and organize previous and new UDOs of mine in
this GIT repo over time.

Thanks!
steven

Csound mailing list
Csound@listserv.heanet.ie
https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND
Send bugs reports to
        https://github.com/csound/csound/issues
Discussions of bugs and features can be posted here

Date2016-04-22 04:31
FromSteven Yi
SubjectRe: tdf2 biquad
And... I was just searching for other things and came across the rbjeq
opcode. tdf2 should give the same results as the existing rbjeq,
though rbjeq uses a different form of biquad.

On Thu, Apr 21, 2016 at 9:44 PM, Steven Yi  wrote:
> Hi All,
>
> I was recently looking at filter code and and implemented a UDO called
> tdf2 that uses the Transposed Direct Form II version of the biquad.
> It is available at:
>
> https://github.com/kunstmusik/libsyi
>
> There's an .inc file that has the UDO and a test csd files in the
> tests folder.  It's a translation of Nigel Redmon's C++ code available
> at:
>
> http://www.earlevel.com/main/2012/11/26/biquad-c-source-code/
>
> The tdf2 UDO has the following arguments:
>
>    INPUT
>      asig - input signal
>      ifilter_type - filter type:
>         0 - Low Pass
>         1 - High Pass
>         2 - Band Pass
>         3 - Notch
>         4 - Peaking
>         5 - Low Shelf
>         6 - High Shelf
>      acutoff - cutoff frequency
>      aQ - Q value
>      again - gain (used by peaking, low shelf, and high shelf)
>
>
> All inputs besides filter_type are a-rate.  If you want to pass in a
> constant value, you can use a(value) as the argument.
>
> Any comments, feedback, and bug reports are welcome.
>
> Also, I have posted some UDOs over the past years here to the list.  I
> am planning to include and organize previous and new UDOs of mine in
> this GIT repo over time.
>
> Thanks!
> steven

Csound mailing list
Csound@listserv.heanet.ie
https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND
Send bugs reports to
        https://github.com/csound/csound/issues
Discussions of bugs and features can be posted here

Date2016-04-22 10:05
FromRory Walsh
SubjectRe: tdf2 biquad
Thanks for sharing. Made me wonder whether we shouldn't include UDOs in the manual? If people submit a manual page in the correct xml format, there really shouldn't be any issues with including them?  

On 22 April 2016 at 04:31, Steven Yi <stevenyi@gmail.com> wrote:
And... I was just searching for other things and came across the rbjeq
opcode. tdf2 should give the same results as the existing rbjeq,
though rbjeq uses a different form of biquad.

On Thu, Apr 21, 2016 at 9:44 PM, Steven Yi <stevenyi@gmail.com> wrote:
> Hi All,
>
> I was recently looking at filter code and and implemented a UDO called
> tdf2 that uses the Transposed Direct Form II version of the biquad.
> It is available at:
>
> https://github.com/kunstmusik/libsyi
>
> There's an .inc file that has the UDO and a test csd files in the
> tests folder.  It's a translation of Nigel Redmon's C++ code available
> at:
>
> http://www.earlevel.com/main/2012/11/26/biquad-c-source-code/
>
> The tdf2 UDO has the following arguments:
>
>    INPUT
>      asig - input signal
>      ifilter_type - filter type:
>         0 - Low Pass
>         1 - High Pass
>         2 - Band Pass
>         3 - Notch
>         4 - Peaking
>         5 - Low Shelf
>         6 - High Shelf
>      acutoff - cutoff frequency
>      aQ - Q value
>      again - gain (used by peaking, low shelf, and high shelf)
>
>
> All inputs besides filter_type are a-rate.  If you want to pass in a
> constant value, you can use a(value) as the argument.
>
> Any comments, feedback, and bug reports are welcome.
>
> Also, I have posted some UDOs over the past years here to the list.  I
> am planning to include and organize previous and new UDOs of mine in
> this GIT repo over time.
>
> Thanks!
> steven

Csound mailing list
Csound@listserv.heanet.ie
https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND
Send bugs reports to
        https://github.com/csound/csound/issues
Discussions of bugs and features can be posted here

Csound mailing list Csound@listserv.heanet.ie https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND Send bugs reports to https://github.com/csound/csound/issues Discussions of bugs and features can be posted here

Date2016-04-22 12:15
FromPeter Burgess
SubjectRe: tdf2 biquad
Thanks! Also, earlevel looks like a fantastic resource, thanks for that too!

I like the idea of UDOs in the manual, would be good to have loads of
useful UDOs collected together like that, and would be an extra way to
help people learn Csound/DSP aswell.

On Fri, Apr 22, 2016 at 10:05 AM, Rory Walsh  wrote:
> Thanks for sharing. Made me wonder whether we shouldn't include UDOs in the
> manual? If people submit a manual page in the correct xml format, there
> really shouldn't be any issues with including them?
>
> On 22 April 2016 at 04:31, Steven Yi  wrote:
>>
>> And... I was just searching for other things and came across the rbjeq
>> opcode. tdf2 should give the same results as the existing rbjeq,
>> though rbjeq uses a different form of biquad.
>>
>> On Thu, Apr 21, 2016 at 9:44 PM, Steven Yi  wrote:
>> > Hi All,
>> >
>> > I was recently looking at filter code and and implemented a UDO called
>> > tdf2 that uses the Transposed Direct Form II version of the biquad.
>> > It is available at:
>> >
>> > https://github.com/kunstmusik/libsyi
>> >
>> > There's an .inc file that has the UDO and a test csd files in the
>> > tests folder.  It's a translation of Nigel Redmon's C++ code available
>> > at:
>> >
>> > http://www.earlevel.com/main/2012/11/26/biquad-c-source-code/
>> >
>> > The tdf2 UDO has the following arguments:
>> >
>> >    INPUT
>> >      asig - input signal
>> >      ifilter_type - filter type:
>> >         0 - Low Pass
>> >         1 - High Pass
>> >         2 - Band Pass
>> >         3 - Notch
>> >         4 - Peaking
>> >         5 - Low Shelf
>> >         6 - High Shelf
>> >      acutoff - cutoff frequency
>> >      aQ - Q value
>> >      again - gain (used by peaking, low shelf, and high shelf)
>> >
>> >
>> > All inputs besides filter_type are a-rate.  If you want to pass in a
>> > constant value, you can use a(value) as the argument.
>> >
>> > Any comments, feedback, and bug reports are welcome.
>> >
>> > Also, I have posted some UDOs over the past years here to the list.  I
>> > am planning to include and organize previous and new UDOs of mine in
>> > this GIT repo over time.
>> >
>> > Thanks!
>> > steven
>>
>> Csound mailing list
>> Csound@listserv.heanet.ie
>> https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND
>> Send bugs reports to
>>         https://github.com/csound/csound/issues
>> Discussions of bugs and features can be posted here
>
>
> Csound mailing list Csound@listserv.heanet.ie
> https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND Send bugs reports to
> https://github.com/csound/csound/issues Discussions of bugs and features can
> be posted here