Sunday, September 27, 2009

First Hack - Compressor

This first hack adds a slider to adjust compressor knee -- nothing amazing. This is also the introduction of the finalized compressor fix.

The tarball may be downloaded here:

Should be able to extract, enter the top directory and
make install

Please post a comment if there is a problem compiling. Be sure to install all dev packages relating to dependencies reported as missing in configure output, or make output. The README lists dependencies.

If you simply want to apply the compressor fix to a release of Rakarrack already compiled & installed on your computer, then do the following:
Enter the /src directory. Copy the following files into this directory, and select "ok" to replace the file of the same name:

go back into the source package main directory and
make install

This will re-compile the changed source files and install this to your system.

Tuesday, September 22, 2009

Development Computer

People often are interested in the development platform being used. Here is my current setup:

Debian GNU/Linux : Squeeze (Testing)
iBook G4 (14")
--1G RAM
--1.33 MHz CPU

I am a novice programmer, and my roots in programming are in my C and C++ classes in college, where we were instructed using a text editor like vi or nano and constructed our own make files, and compiling from the command line. My development tool has progressed from nano to Gedit. It has color mapping and brace/bracket/parentheses matching for most programming languages, which is all I need. I haven't yet attempted an SDK of any sort since my current commandline based environment has become comfortable.

Software most used (in no particular order):
qjackctl for control of jackd
Hydrogen Drum Kit

...and of course

Some people are afraid of switching to Linux because they have to sacrifice many familiar Windows applications. In my experience, I sacrificed little and gained much by switching to Linux.

RakaHack Welcome

I have recently taken interest to hacking Rakarrack ( ) in the way of improving features or fixing/modifying the DSP algroithms within the source code.

My intent is to contribute any fruits of my labor back to the project, but also know that some things will not be included in any releases if the "hacks" do not fit into the project goals.

As a result, this blog will catalog my hacks, and provide instructions for modifying the source code for those who wish to have their own version of RakaHack.

For example, I got started with this when I determined the compressor doesn't behave as expected. I dug into the DSP algorithm within Compressor.C and found some faulty math. This fix has been submitted and included in CVS.

However, on the side I added a slider to the GUI to make the compressor knee user-adjustable. This feature was not added to the project CVS, so perhaps in my next blog I will provide instructions and/or rakarrack.cxx hacked file to add this feature to your own version of Rakarrack.

Now I have it in my mind to continue hacking the effects. Here are some ideas:
1) The distortion function needs up-sampling to reduce digital aliasing artifacts.
2) I want to add a compression-type distortion element (sort of a dynamic tube-like curve, but not really intended to be a tube emulator).
3) Model the phaser after an analog circuit.
4) Add a multiplyer cell for things like ring modulation -- many interesting things can be done here.
5) Split envelope detection to left channel only, so one can use external modulation sources to control the wah-wah. For example, a Crybaby can be used as a volume pedal by feeding high-pass filtered white noise into the Crybaby, then crybaby into the left channel. Guitar into the right channel. The compressor code is hacked to only detect input level on the left channel. Set compressor threshold quite low, and work the crybaby. As the filtered white noise changes in amplitude, the compressor modulates gain on the audio signal, and voila! a volume pedal. This same technique could be used to use your real Crybaby wah pedal to sweep the rakarrack wah.

See how much fun hacking can be?