Sonic Field - A New Audio Mastering Package

Sound is made of a field of waves all intermixing
in 3 dimensions,
so this is how we should produce audio.

Copyright: Dr Alexander J Turner.
I like ambition and this project is ambitious. I am hoping to leverage javax.sound and my knowledge of mathematical computing and audio processing to produce a new way of mastering audio.


I considered many different options:
  1. A pure C++ system with an Excel front end.
  2. C++ driving Java with a Swing front end.
  3. C++ or Java with a simple command line interface.
  4. Using Jacob to give Java an Excel front end.
  5. Using JRuby or Ruby with Java or C++.
The first one does not lend its self to the Mac (a big potential target) or working in the cloud. The second would be a good idea, but implementing a language in C++ required more effort as I did not have a good one at hand in a mature state. I liked 3 but I think it limits the project two much. 4 suffers from the same issues as 1. 5 is cool but these languages are far too complex and heavy to implement and learn for the requirements of Sonic Field.

VSPL was designed from the get-go to be really easy to add libraries to. It only has the notion of operators and operands which map to objects under the covers. What makes it all the more appropreate its that its forward only processing model fits nicely with the forward only metaphor on which most audio processing is performed. To put it another way:

  • A volume control as an input and an output.
  • Sf.Volume also has an input and and output.

Finally, this forward based programming model fits well with map/reduce and massively parallel programming. Load->Map->Process->Reduce->Save is a linear, forward only programming model.

Does it work?
So far I have spent a few hours over three days on the project. It can load audio files and convert them to its own high resolution internal format. It can then perform basic operations on them and then save them back out and play the saved file. The following VSPL program does this to add a simple 'small room' reverb to a wav file.


"y:/VSPL/SonicField/Sax-Example.wav" !wavFile
"y:/temp/temp.wav"                   !tempFile
?wavFile Sf.ReadFile !channels
?channels ListDequeue !left
?channels ListDequeue !right

    (30,(?t,10:Prod):Sum Sf.Silence),?left: Sf.Concat !new_left
    (40,(?t,10:Prod):Sum Sf.Silence),?right:Sf.Concat !new_right

    ?new_left, -12:Sf.Volume !new_left
    ?new_right,-12:Sf.Volume !new_right

    ?new_left, ?left: Sf.Add Sf.Normalise !left
    ?new_right,?right:Sf.Add Sf.Normalise !right

{?wavFile, ("Primary Sound Driver" Sf.Mixer):Sf.PlayFile sf.LineWait} Invoke
{?tempFile,("Primary Sound Driver" Sf.Mixer):Sf.PlayFile sf.LineWait} Invoke

A simple delay effect is achieve by concatenating silence to sound data. This is then used with multiple different delays which are fed back and damped to produce the effect of sound reverberating around a small room.

Here is a Youtube Video explaining Sonic Field and demonstrating this simple reverb: