[PD] C++ for reusable dsp lib - or better use C?

katja katjavetter at gmail.com
Sat Feb 25 01:58:14 CET 2012

Hi all,

Thanks for this very informative discussion. As I had the initial
question 'C++ or C', I wanted to let you know that I've made up my
mind: I'll do it the hard way, plain C. I've rewritten one of my own
C++ library classes into C by way of exercise and comparison. It does
exactly the same thing at the same speed, with not so sweet-looking
code. This doesn't cover all the C/C++ differences, but in the end,
everything can be solved in C one way or another. I'll put up with the
annoyance of writing C, to increase the chances of unproblematic
compilation and linking.

In my (not so huge) coding experience, I've always noticed that code
typing is the least time consuming aspect of a dsp project. To figure
out a good concept takes longer. Testing and bug fixing takes longer.
Optimization takes longer. I've once written an optimized FFT lib (in
C). It took me a month if I remember well, and that was not because of
all the code typing.


More information about the Pd-list mailing list