Split Stereo Track Into 2 Mono Tracks

I would like to suggest an improvement to the Audacity “split stereo track feature”: Instead of splitting the Stereo track into Left and Right tracks as it does now, it should split into 2 Mono tracks.

I have already made this modification by compiling from Source Code on Linux and find it an excellent feature which saves loads of tedious mouse clicking.

If anyone would like my amended source code (for version 1.3.6) just email psilocybin@stoned.com. It is just one line of code in TrackPanel.cpp

If some users prefer the existing method, how about 2 seperate menu items “Split Stereo Track” and “Split into 2 Mono Tracks”?


In most situations you can just select “Stereo Tracks to mono” from the Tracks menu.

I have tried “stereo track to mono” and it doesnt do what I want. It creates one single mono track, but I want 2 different mono tracks.

I am doing 2 track recording using a stereo mixing desk, so I need to convert a single stereo track into 2 seperate mono tracks. At the moment this involves doing “split stereo track” then changing both tracks from “left” and “right” to “mono”. This works, but is very irritating because of the amount of mouse acrobatics involved every time you do it!


:smiley: That’s why I said “most situations”.
That’s the time when an extra couple of mouse clicks are needed (unless you hack the code as you have done).
As a matter of interest, what exactly did you change? (I’m not a programmer, but I’ve built Audacity from source a couple of times so I might try out your modification and see if it works on 1.3.8).

This is my modification to Audacity 1.3.6

TrackPanel.cpp, Line 6,132, add the following:

//make the split tracks mono

Make sure this occurs before the call to MakeParentPushState() otherwise undo/redo wont work properly.

I would be really happy if this or similar modification was included in the official audacity, because its a feature I cant live without and Id rather not have to build from source every time. However I do realise its not a priority for anyone other than myself!


Well I’ve just amazed myself - knowing nothing about coding I had a play and hacked it around a bit…

Building from cvs (Audacity ® 1.3.8-alpha_Feb 16 2009),
I Changed the TrackPanel.cpp to this:

[attachment=]Temporarily removed while I test a minor change to it[/attachment]

And in TrackPanel.h

After (line 338)

   void OnSplitStereo(wxCommandEvent &event);


   void OnSplitStereoMono(wxCommandEvent &event);

The result is this:
And it works :open_mouth:

Thanks for the input Tim. With your skills I’m sure that the Audacity developers would welcome you with open arms. If you are interested in developing Audacity, you can sign up to the Audacity Developers mailing list here: https://lists.sourceforge.net/lists/listinfo/audacity-devel

I think that an option to split a stereo track into 2 mono tracks is an excellent idea for exactly the reasons that you give. I don’t know how many users would find this feature useful (but then again, what % of Audacity users ever use “hh:mm:ss + NTSC non-drop frames”?) Certainly I will find it useful from time to time. I’ll suggest it on the audacity-devel list and see what they say.

Made a slight change so that the undo history works correctly.

The patch file is attached.
This has been tested on Audacity 1.3.8 alpha but I think it will work on 1.3.7 (release) as well. (I’m testing that now)

For any other users that may want to try this patch:
To use the patch file, unzip it into the same directory as the unpacked tarball. The unpacked audacity folder should be named “audacity” or the patch file edited appropriately. In a terminal, cd to the directory that contains both the audacity folder and the patch file and enter

 patch -p0 <patchfile.diff

[Edit]Have now tested on Audacity 1.3.7 in Ubuntu 8.10 and it works fine[/Edit]
patchfile.diff.zip (1.19 KB)

Hi Steve, I am delighted to hear that the Split To Mono feature is being considered. Hope it makes it into the next version.

As to me doing dev work for Audacity: I have already contributed to the project some years ago when I helped with the “Precise Volume Controls” feature.

I would like to do more work for Audacity, but unfortunately I have a problem with my eyes. After years of being a C/C++ developer I now get bad pain in my eyes and head if I use a computer monitor.

I can use this computer only for a few hours per week, using a projector screen instead of a monitor. I will also be off line completely for several months starting Friday 20th Feb.

So basically Id like to help more, but it looks a bit impractical for now. Maybe in the future though? Email me privately if you wish to discuss this. Thanks.


You’ll be pleased to know that the patch has been added to cvs so it is now available when you build the 1.3.8alpha version. (Audacity 1.3.8 has a couple of other tasty new features also).