Become a Site Supporter and Never see Ads again!

Author Topic: Linux mid/side mixing software?  (Read 5038 times)

0 Members and 1 Guest are viewing this topic.

Offline SmokinJoe

  • Trade Count: (63)
  • Needs to get out more...
  • *****
  • Posts: 4212
  • Gender: Male
  • "75 and sunny"... life is so much simpler.
    • uploads to archive.org
Linux mid/side mixing software?
« on: May 03, 2007, 07:47:09 AM »
I just bought an LSD2 mic, which can do mid/side recording.  So I'll have to play with it.  ;D  I don't have a special preamp, so I figure I just record the mid track and side track seperately and then try to mix them at home.

I'm a linux geek, and prefer command line programs (like sox or ssrc) which just run without interaction, and then I can glue them together in a script, let it run and walk away.  I can use audacity if I have to, but would prefer not to.  I'm not fluent in ecasound, but recognize that may be the solution.  I'm running Debian sarge and etch, and prefer apt-get'able apps, but can build from source too.

I can envision a process something like this, which should be easily scriptable with a bunch of sox one-liners, but I can't figure out the right commands for sox:
- take a whole set, isolate 1 song to experiment with... call it 1song.wav
- split 1song.wav into left track and right track, i.e. mid and side track, called mid.wav and side.wav
- invert side.wav into inverted.wav
- run a mix of 75%/25% mid/side > left7525.wav
- run a mix of 75%/25% mid/inverted > right7525.wav
- combine left7525.wav and right7525.wav into a stereo track 7525mix.wav
- repeat the last 3 steps for various mixes like 40/60, 50/50, 60/40, etc.
then
- listen to the various mixes, and decide which one I like the best.
then
- repeat the split, invert, mix, combine for the whole set(s) to get a left/right mix to the preferred ratio.
then
- track out out like any other Left/right mix.

Any experience and ideas out there?


Mics: Schoeps MK4 & CMC5's / Gefell M200's & M210's / ADK-TL / DPA4061's
Pres: V3 / ST9100
Decks: Oade Concert Mod R4Pro / R09 / R05
Photo: Nikon D700's, 2.8 Zooms, and Zeiss primes
Playback: Raspberry Pi > Modi2 Uber > Magni2 > HD650

Offline ghellquist

  • Trade Count: (0)
  • Taperssection Member
  • ***
  • Posts: 477
  • Gender: Male
Re: Linux mid/side mixing software?
« Reply #1 on: May 03, 2007, 04:12:52 PM »
Well, that is one way to do it.

Here is how I generally do it.
a) Start my program (Samplitude in Windows), takes a few seconds.
b) Import the wave file (one command, takes a minute or so to build the graphic representation).
c) Add the MSED plugin (a few clicks).
-- varying the width of the MS while listening. When happy, there is where I go.
  (generally I also do normalize which is one command, remove some low frequency with a filter and adds a limiter on the output just to be sure)

d) Divide the session up into song, each an object (one click with the mouse and Ctrl-T)
e) Set track indices on object edges (one command in the menu).
f) Make CD (one command, a few OK-s) -- CD is burned, takes about 8 minutes.
or as alternative
f) Export as mp3, tick option "Each CD track in a file" -- creates one mp3 per song, takes a bit of time (same procedure for wave file export).

g) saves the "VIP" which has all the settings but none of the audio files (they are not copied unless you request it) for later tweaking.

There is a batch facilitiy in Samplitude but I have never had any need for using it.

To me Sam has a clearly superior workflow compared to all other programs. (Same features are awailable in Magix Music studio at a rather low price, again only windows though).

Gunnar

Offline it-goes-to-eleven

  • Trade Count: (58)
  • Needs to get out more...
  • *****
  • Posts: 6695
Re: Linux mid/side mixing software?
« Reply #2 on: May 03, 2007, 08:31:50 PM »
The good news is a new version of sox was released in feb which adds 24 bit support. That was always a big limitation on a very useful tool.. So what you want to do gets a lot easier.  There is also some mention of dither in the man page so that will be worth looking at.

I don't have any mid-side audio to test with but I think this should be close.


# - take a whole set, isolate 1 song to experiment with... call it 1song.wav
# - split 1song.wav into left track and right track, i.e. mid and side track, called mid.wav and side.wav

ecasound  \
 -a:1,2 -i sweep.wav \
 -a:1 -f:s16_le,1 -o mid.sweep.wav \
 -a:2 -f:s16_le,1 -o side.sweep.wav -erc:2,1


# - invert side.wav into inverted.wav

sox side.sweep.wav -v -1.0 inverted.side.wav


# - run a mix of 75%/25% mid/side > left7525.wav

soxmix -v 0.75 mid.sweep.wav -v 0.25 side.sweep.wav -c 2 left.7525.wav


# - run a mix of 75%/25% mid/inverted > right7525.wav

soxmix -v 0.75 mid.sweep.wav -v 0.25 inverted.side.wav -c 2 right.7525.wav


# - combine left7525.wav and right7525.wav into a stereo track 7525mix.wav

ecasound \
 -a:1 -f:s16_le,1 -i left.7525.wav \
 -a:2 -erc:1,2 -eac:0,1 -f:s16_le,1 -i right.7525.wav \
 -a:1,2 -f:s16_le,2 -o 7525.mix.wav


Offline SmokinJoe

  • Trade Count: (63)
  • Needs to get out more...
  • *****
  • Posts: 4212
  • Gender: Male
  • "75 and sunny"... life is so much simpler.
    • uploads to archive.org
Re: Linux mid/side mixing software?
« Reply #3 on: May 03, 2007, 09:30:06 PM »
That's exactly what I was looking for!  Thanks.
Mics: Schoeps MK4 & CMC5's / Gefell M200's & M210's / ADK-TL / DPA4061's
Pres: V3 / ST9100
Decks: Oade Concert Mod R4Pro / R09 / R05
Photo: Nikon D700's, 2.8 Zooms, and Zeiss primes
Playback: Raspberry Pi > Modi2 Uber > Magni2 > HD650

Offline pigiron

  • Trade Count: (0)
  • Taperssection Member
  • ***
  • Posts: 250
  • Gender: Male
  • I just did what I did
Re: Linux mid/side mixing software?
« Reply #4 on: May 03, 2007, 09:50:30 PM »

a report back on the process/script that works for you would be greatly appreciated... i'm in the same spot... got a LSD2 and use linux exclusively... just simply haven't taken the time to blaze the M/S trail.
skm184, lsd2
v2, sd722, mini-me, jb3

Offline SmokinJoe

  • Trade Count: (63)
  • Needs to get out more...
  • *****
  • Posts: 4212
  • Gender: Male
  • "75 and sunny"... life is so much simpler.
    • uploads to archive.org
Re: Linux mid/side mixing software?
« Reply #5 on: May 09, 2007, 06:47:51 AM »
Not yet.  Soon...
Mics: Schoeps MK4 & CMC5's / Gefell M200's & M210's / ADK-TL / DPA4061's
Pres: V3 / ST9100
Decks: Oade Concert Mod R4Pro / R09 / R05
Photo: Nikon D700's, 2.8 Zooms, and Zeiss primes
Playback: Raspberry Pi > Modi2 Uber > Magni2 > HD650

Offline pigiron

  • Trade Count: (0)
  • Taperssection Member
  • ***
  • Posts: 250
  • Gender: Male
  • I just did what I did
Re: Linux mid/side mixing software?
« Reply #6 on: May 09, 2007, 10:34:45 PM »
I played around a bit with the new sox last night.  I wanted to take a first pass at the resample and dither. Figured out the syntax and my tiny test file went fine. But when I tried a 700MB 24/96 file, it consumed all the memory in my machine..  So I was pretty bummed about that. I'd planned on producing some files for a resample and dither comp.  So I need to figure out where the leak is, whether it relates to amd64 or the rabbit ssrc resample library.

A dither/resample shootout is a great idea!   Here's a comp from 2005 on just resampling, but maybe it'll give you some ideas on measurement techniques:

http://www.mainly.me.uk/resampling/index.html

It caused me to switch from ResampAudio to ssrc... and I've used those two for both dithering and resampling... but I played around with the parameters on both and I'll be damned if I can hear any difference.
skm184, lsd2
v2, sd722, mini-me, jb3

Offline SmokinJoe

  • Trade Count: (63)
  • Needs to get out more...
  • *****
  • Posts: 4212
  • Gender: Male
  • "75 and sunny"... life is so much simpler.
    • uploads to archive.org
Re: Linux mid/side mixing software?
« Reply #7 on: September 24, 2007, 09:52:56 PM »
Well, I finally got around to trying this yesterday.  Works like a charm per Freelunch's instructions above. +T Man!!!

I did an on-stage recording of Garaj Mahal using LSD2 in M/S mode, and it is probably the best tape I have ever pulled with that mic.

I slapped together some rough scripts which I've posted on the web because they are a little long to copy here.   I noticed as things go along they mix loses volume and the end product ended up being about 10db low, so I added a call to another little script I had called "boostlevels".  This doesn't normalize, it just set the highest peak at 98%.  I do this on the raw file, and again on the final mix file.  Take my scripts and do what you want with them.

Linux Mid/Side Matrix Decoding MINI-HOWTO:

1) Record something using an Mid/Side mic.... Mid > Left channel, Figure 8 > Right channel.
2) Find some song to ran samples with... just pick a song, probably less than 16minutes long.
3) sox recording.wav sample.wav trim 4:12 15:48  (starttime length)(Note: CALL IT sample.wav for use in my next script)
4) download http://joe.bouchard.com/generate_midside_samples
    download http://joe.bouchard.com/generate_midside_mix
    download http://joe.bouchard.com/boostlevels
5) Run "generate_midside_samples".  It assumes an input file sample.wav, and generates a 25/75, 40/60, 50/50, 60/40, and 75/25 mix from that sample.
    On my Pentium 3 866 with songs 15:48 this churned away for 10-15 minutes unattended...
6) Burn a CD of those various samples.  Notice that 5 songs less than 16 minutes will fit on a 80minute CD.
7) Listen anywhere you can... living room stereo, in the car, iPod, whatever you got.  Decide which mix you like best.  I chose 40/60.
8) When you are ready to mix the whole set, run "generate_midside_mix  whole_midside_set.wav 40 60" or whatever values you picked.
    On my Pentium 3 866 this took maybe 20 minutes...
9) At this point you will have a file called "midsidemix.wav" which you can track out like you had recorded it in XY or DIN.

Have fun!
Mics: Schoeps MK4 & CMC5's / Gefell M200's & M210's / ADK-TL / DPA4061's
Pres: V3 / ST9100
Decks: Oade Concert Mod R4Pro / R09 / R05
Photo: Nikon D700's, 2.8 Zooms, and Zeiss primes
Playback: Raspberry Pi > Modi2 Uber > Magni2 > HD650

Offline Brian Skalinder

  • Complaint Dept.
  • Trade Count: (28)
  • Needs to get out more...
  • *****
  • Posts: 18872
  • Gender: Male
Re: Linux mid/side mixing software?
« Reply #8 on: September 25, 2007, 11:27:18 AM »
I'd planned on producing some files for a resample and dither comp.

A dither/resample shootout is a great idea!

Regarding a dither shootout, if you use the original master files from my dither comp, for dithering only (haven't done a resample comp, yet), I'll include them in the comp file set.
Milab VM-44 Links > Fostex FR-2LE or
Naiant IPA (tinybox format) > Roland R-05

 

RSS | Mobile
Page created in 0.049 seconds with 33 queries.
© 2002-2025 Taperssection.com
Powered by SMF