Author Topic: Writing my own software audio mixer  (Read 1892 times)

Offline paulscode

  • double
  • *****
  • Posts: 863
    • View Profile
    • PaulsCode.Com
Writing my own software audio mixer
« on: August 23, 2010, 03:14:44 am »
Hello, all.  My next big project is to write my own software audio mixer, so that I can play multiple audio inputs on a single output line.  This will not only solve the latency and mixer-compatibility issues with Java Sound, but I could potentially use the same algorithms to write a sound library for the Android.  I thought I'd post here in case anyone has some knowledge about these topics.

I would need to be able to do the following things with PCM audio data:

1) Mixing multiple inputs into one 2-channel (left/right) output, maintaining synchronization between the channels
2) Converting between (or mixing directly) various audio formats (different sample rates/sample sizes/channels)
3) Changing frequency (pitch)
4) Changing gain (volume) independently on each channel

I want to be able to do this in pure Java, completely programatically (i.e. no linking with 3rd-party libraries except to initially acquire the PCM data and then to actually play the output).  I'm looking for all tips, source code, tutorials, that kind of thing.  I am proficient in several programming languages, so references don't necessarily have to be written specifically for Java.  I've googled up a few promising things already, but the more information I can get, the easier my job will be.