Audio Programming: Split Audio Tracks

Makefile | Color Source Listing | split_audio-1.1.tgz

Some audio books use one channel at a time as a means of fitting more on one tape. On a 90 minute tape they can fit 2*90/60=3hrs of audio. The drawback is that you have to listen to the book one speaker at a time, left and then right. This program splits the input audio file (obtained from the audio book) into two output audio files, i.e. left and right channels. The left input channel is copied to both channels of the "left" output file and the right input channel is copied to both channels of the "right" output file.

     Usage:  split_audio  file_name.[raw|wav]

The output file type is the same as the input type.

This program reads in a RAW or WAV format audio file and writes out two files, one for the left and one for the right channel. The tracks are assumed to be in the format:

      MSB Left,  LSB Left
      MSB Right, LSB Right
The output files are the same size as the input file as a result of:

      Left  In  --> Left Out.left  & Right Out.left
      Right In  --> Left Out.right & Right Out.right