DtBlkFx Revision 0.9

VST audio effect plugin by Darrell Tam

User Guide

Compile date Jan 21 2006, Microsoft Windows version

This software incorporates code from fastest-fourier-transform-in-the-west 2.1.3 and Steinberg VST plugin SDK 2.3
VST is a trademark of Steinberg Media Technologies GmbH


The Description

DtBlkFx is a Fast-Fourier-Transform (FFT) based Virtual Sound Technology (VST) plug-in for use in audio software supporting such stuff.

It combines elements of distortion, filtering and synthesis in order to make you smile. It has an easy to use interface and lets you do all kinds of things - examples are:

DtBlkFx is freely distributable and is covered by the terms of the GNU licensing agreement.

Some really short theory

This effect works differently to most others - instead of filtering or distorting audio data directly, it finds the frequency spectrum via a fast-fourier-transform and then does stuff to that.

The steps are:

  1. Cut input sample data is into overlapping blocks
  2. Transform each block to the frequency spectrum
  3. Apply some effects to the spectrum
  4. Inverse transformed the frequency spectrum back to sample data
  5. You feel satisfied

Note: since blocks are involved, the audio must be delayed by at least the length of a block.

The Installation

No installer... manually copy DtBlkFx.dll to the VST plug-ins directory of your music software.

The Tour

Here's the user interface and it is very colourful.

What is all that stuff? Read on...

Overall Params 

MixBack Percentage mix back of original sound. Set this to 100% to save CPU if you don't want any effect apart from delay.
Delay

Since DtBlkFx processes audio in blocks it must delay the sound to operate. Delay controls the amount of delay introduced in music-beats.

Hopefully this isn't too painful because if you shift your audio track forward by the same number of beats then all the timing is back to normal.

The maximum block size that can be processed is limited by the delay that you specify (i.e. small delays will only allow small block sizes).

Overlap Percentage overlap of blocks to use. A large overlap results in a smooth transit ions between blocks but more CPU while a smaller overlap can give interesting effects.
BlkSync

If BlkSync is turned on then DtBlkFx will try align the blocks with the song tempo and with any parameter changes. If it is turned off then the position of blocks will have no particular relationship with the song tempo.

BlkLen Maximum block length to use. If the specified Delay is sufficient then the requested BlkLen will be used otherwise the largest possible will be used and the displayed value marked with an asterisk (*).

Longer block lengths give a higher frequency resolution but need more delay and more CPU. Short block lengths can introduce interesting artefacts.

 
The MixBack, Delay and Overlap params are changed by clicking and dragging the mouse to the left or right. The right mouse button gives you fine control while the left gives you course control.

Spectrograms

The spectrograms show the frequency content of the sound before (Input Spectrogram) and after (Output Spectrogram) processing by DtBlkFx.
 
Move the mouse over either to see a frequency and note display. Click the mouse on a display to toggle whether it is disabled or not. Disabling lets you inspect it more conveniently and saves CPU.
 
How does it work? Each line of the spectrogram is generated from one block (or more for small block sizes) of FFT'd data. The vertical axis is time with most recent data scrolling in at the bottom. The horizontal axis shows frequency with 0Hz on the far left and the maximum frequency (i.e. 22050Hz for 44.1Khz sampling) on the far right. The colour indicates the power level of each frequency: red is -13 dB, black is -80 dB.
 
Notice that the horizontal scaling is linear over "octaves" (which is how we perceive sound) instead of "Hz" (it is logarithmic over "Hz" meaning that high frequencies are closer together than low frequencies). Since FFT's work linearly over "Hz", there is less frequency resolution (i.e. wider "bins") at low frequencies.

Effects

Up to 4 DtBlkFx effects can be applied to the frequency spectrum. The effects are applied in series.
 
Each effect is controlled by the following GUI part:
 

FreqA / FreqB

Use these sliders to select a frequency range for the effect. For most effects when FreqA is less than FreqB then the range between the sliders is selected otherwise it is excluded.

Amp Amplitude controls the relative amplitude of the effect. It is relative because raising the Amplitude of the selected frequency range effectively decreases that of the other frequencies.
Type Type controls which effect will be run.
Value The meaning of value depends on which effect type has been selected.

The FreqA, FreqB and Value sliders drag normally when left clicked, drag slowly on right click and creep when left-clicked away from handle. FreqA & FreqB right-click away from handle allow you to drag both at once both while the value slider creeps slowly for the same action.

Effect types

There are 2 categories of effects as described below: Normal and Masking.

Normal Effects

Filter

This effect allows you to adjust the amplitude of the frequency range specified. Most other effects have this capability but will tend to use more CPU if this is all you want to do.

This is the most basic effect and does not use the effect value control. 

Contrast

This effect smoothly changes the contrast or dynamic range of frequencies present in the sound.

Positive contrast results in the reduction of noise and softer frequency components. Small amounts are useful for reducing distortion and un-muddying sound. When applied heavily only the loudest tones remain but can end up sounding like nasty audio compression on dodgey web videos.

Negative values increase of lower level frequency components. This tends to flatten the frequency spectrum and increase noise. Small to medium amounts are useful for adding "body" to samples.

Smear

This effect randomizes the phase of the spectrum data which results in a flattening of the sound envelope. Sound smearing can be used to remove loop clicks and give a sustain effect. It is similar to reverb in other plugins except that it effectively operates both forwards and backwards!

Thresh

The threshold effect allows you to change the amplitude of frequencies above or below a particular threshold.

In previous versions of DtBlkFx this was known as "Weed".

Clip

Clip causes frequency components greater than a particular level to be clipped to that level.

Mirror

Mirror reverses the order of frequencies within the range. The effect value lets you control the percentage of mirrored and non-mirrored mixing.

In general this does weird things.

Resample Resample is just the same as what resample normally does - it changes the pitch and the speed together.

ShiftAdd
ShiftAddD
ShiftRepl
ShiftReplD
ShiftMove
ShiftMoveD

The various shift effects all modify the pitch of the selected spectrum in one of 2 ways: pitch shift or constant . The constant shift mode can sound similar to frequency modulating effects or listening to single-side-band CB radios.

In pitch shift mode the spectrum is shifted by a particular number of notes while in constant mode it is shifted a constant number of Hertz .

The 6 shift effect variants are: Add versions add the shifted data to whatever it lands on, Repl versions replace the destination range, Move versions add  the shifted data to the destination range and clear the source range. Variants not ending in "D" shift data out of range specified while those ending in "D" shift data into the range.

Shift accuracy is affected by the block length - longer lengths result in higher shifting resolution.

HarmFilt

HarmFilt (Harmonic Filter) is a comb filter that modifies the amplitude at regular intervals or harmonics but leave the gaps between unchanged. You can use this to control the amplitude of particular notes and to produce interesting sweeping effects.

The fundamental frequency is set by which ever frequency slider has a lower frequency.  The effect value controls the width around each harmonic and which harmonics you want to modify, that is all harmonics, only odd, only even or in between harmonics.

To make this effect do something, be sure to set the effect Amp to be non-0 dB (e.g. try -inf or +40 dB).

AutoHarm

AutoHarm is similar to Harmonic except the fundamental frequency is automatically determined to be centred on what ever tone is loudest in the selected frequency range. This means that DtBlkFx can automatically track a pitched sound and change its amplitude.

The effect value is the same as that for HarmFilt.

Triangles
Squares
Saws
Pointy
Sweep

These effects are similar to vocoding and cause the timbre of a pitched input sound to match various built-in sounds. Like AutoHarm, they track the loudest tone within the selected frequency range and operate on the harmonics.

Use the effect value to sweep over variants of the built-in sound. When used in conjunction with the AutoHarmMask effect (described below) you can control the width of harmonics. 

Mask Effects

Mask effects don't change the sound in anyway by themselves but affect which frequencies a normal effect immediately following will be applied.  For example if you set the first effect as ThreshMask and the second effect as Contrast you can now choose to apply Contrast only to frequency components above or below the threshold.

Note: A normal effect can only have one mask (i.e. if you set 2 masks in a row then the first mask will have no effect).

HarmMask

HarmMask is the masking version of HarmFilt and allows you to apply any normal effect to the harmonics of a particular note.

AutoHarmMask AutoHarmMask is the masking version of AutoHarm and has the same effect value meaning.
ASubH1Mask
ASubH2Mask
ASubH3Mask
These effects are all variants of AutoHarmMask differing in that the fundamental frequency is taken as 1/2 (ASubH1Mask), 1/3 (ASubH2Mask) or 1/4 (ASubH3Mask) of the loudest frequency within the selected range.
ThreshMask Thresh mask is the masking version of "Thresh" and lets you apply the following normal effect to only frequencies above or below a particular threshold.

Source

DtBlkFx is freely distributable and is covered by the same terms as the GNU licensing agreement.
 
Full source code is included - feel free to modify and experiment with the source code. It would be nice if someone could do a Macintosh port. DtBlkFx was compiled using Microsoft Visual C++ .NET 2003.
 
The Fastest-Fourier-Transform-in-the-West (version 2.1.3) is used to perform frequency transforms. I have not included the source - download this from www.fftw.org but you don't need it to recompile DtBlkFx under Windows because the lib file is included. Many thanks to the guys that made FFTW.
 
I plan on implementing the following stuff in a future version of DtBlkFx

Hosts tested on:

Can someone tell me how DtBlkFx goes under cubase, cakewalk & others??

Contact

Please send me bug reports, comments and suggestions.

Author Darrell Tam
Email darrell.barrell@gmail.com

About Me

I live in Canberra, Australia, with my wife Yvette and 2 children Asher and Jasper. I have been writing computer music and music software for about 17 years, starting on the Amiga using various trackers.

I am open for consulting work and collaborative free software development. I have 13 years experience in hardware (VHDL for FPGAs, microcontrollers) and software (C, C++, perl) development. Projects have included digital signal processing, digital demodulation, high-speed demultiplexing, parallel data processing, Microsoft Windows device driver development and system architecture design.