A Collection of Useful C++ Classes for Digital Signal Processing - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

A Collection of Useful C++ Classes for Digital Signal Processing

thevinnthevinn Posts: 1Member
Greetings. I would like to offer you my latest creation, an open source MIT-licensed C++ library for implementing IIR (Infinite Impulse Response) digital filters. It is fully documented, and even comes with a graphical/audio demo to showcase it's features. It uses templates. Here it is;

http://code.google.com/p/dspfilterscpp/

"A Collection of Useful C++ Classes for Digital Signal Processing"

By Vincent Falco

"Techniques for digital signal processing are well guarded and held close to the chest, as they have valuable applications for multimedia content. The black art of Infinite Impulse Response ("IIR") filtering has remained shrouded in secrecy with little publicly available source code....until now."

Building on the work of cherished luminaries such as Sophocles Orfanidis, Andreas Antoniou, Martin Holters, and Udo Zolzer, this library harnesses the power of C++ templates to solve a useful problem in digital signal processing: the realization of multichannel IIR filters of arbitrary order and prescribed specifications with various properties such as Butterworth, Chebyshev, Elliptic, and Optimum-L (Legendre) responses. The library is provided under the MIT license and is therefore fully compatible with proprietary usage.

Classes are designed as independent re-usable building blocks. Use some or all of the provided features, or extend the functionality by writing your own objects that plug into the robust framework. Only the code that you need will get linked into your application. Here's a list of features:

* Exclusive focus on IIR filters instead of boring FIR filters
* Complete implementation of all "RBJ Biquad" Cookbook filter formulas
* Butterworth, Chebyshev, Elliptic, Bessel, Legendre designs
* Low Pass, High Pass, Band Pass, Band Stop transformations
* Low, High, and Band Shelf filter implementations for most types
* Smooth interpolation of filter settings, pole/zeros, and biquad coefficients to achieve seamless parameter changes
* Representation of digital filters using poles and zeros
* Realization using Direct Form I, Direct Form II, or user provided class
* Fully factored to minimize template instantiations
* "Design" layer provides runtime introspection into a filter
* Utility template functions for manipulating buffers of sample data
* No calls to malloc or new, great for embedded systems
* No external dependencies, just the standard C++ library!
* Documentation!

Using these filters is easy:

[code] // Create a Chebyshev type I Band Stop filter of order 3
// with state for processing 2 channels of audio.
Dsp::SimpleFilter , 2> f;
f.setup (3, // order
44100,// sample rate
4000, // center frequency
880, // band width
1); // ripple dB
f.process (numSamples, arrayOfChannels);[/code]

An accompanying demonstration program that works on most popular platforms by using the separately licensed Juce application framework (included), exercises all the functionality of the library, including these features:

* Dynamic interface creates itself using filter introspection capabilities
* Audio playback with real time application of a selected filter
* Live time stretching and amplitude modulation without clicks or popping
* Charts to show magnitude, phase response and pole/zero placement
* Thread safety "best practices" for audio applications

Here's a screenshot of the DspFilters Demo

http://dspfilterscpp.googlecode.com/files/dspfiltersdemo.png

If you've been searching in futility on the Internet for some source code for implementing high order filters, then look no further because this is it! Whether you are a student of C++ or digital signal processing, a writer of audio plugins, or even a VST synthesizer coder, "A Collection of Useful C++ Classes for Digital Signal Processing" might have something for you!

Sign In or Register to comment.