shithub: sox

Download patch

ref: e60dbd620fdf1ca426d1ff12b212aef45be4d3c2
parent: 003122e81840e308f5834577ee5c8b213c95135e
author: Ulrich Klauer <ulrich@chirlu.de>
date: Tue Mar 5 18:20:54 EST 2013

Remove deprecated mixer effect

--- a/ChangeLog
+++ b/ChangeLog
@@ -16,15 +16,9 @@
   14.3.0   O -s/-u/-f              -e
   14.3.0   O -A/-U/-o/-i/-a/-g     -e
   14.4.0   E swap with parameters  remix
+  14.4.0   E mixer                 remix
   14.4.1   OpenMP < 3.0            OpenMP >= 3.0
   14.4.1   F ffmpeg                ffmpeg/avconv via pipe
-
-Previously deprecated features (to be removed in future):
-
-  Deprec-  Feature    [O(ption)]                           Removal
-  ated in  [F(ormat)] [E(ffect)]   Replacement             due after
-  -------  ----------------------  ----------------------  -------
-  14.4.0   E mixer                 remix                   2013-03-04
 
 Effects:
 
--- a/msvc10/LibSoX.vcxproj
+++ b/msvc10/LibSoX.vcxproj
@@ -219,7 +219,6 @@
     <ClCompile Include="..\src\ladspa.c" />
     <ClCompile Include="..\src\loudness.c" />
     <ClCompile Include="..\src\mcompand.c" />
-    <ClCompile Include="..\src\mixer.c" />
     <ClCompile Include="..\src\noiseprof.c" />
     <ClCompile Include="..\src\noisered.c" />
     <ClCompile Include="..\src\output.c" />
--- a/msvc10/LibSoX.vcxproj.filters
+++ b/msvc10/LibSoX.vcxproj.filters
@@ -252,9 +252,6 @@
     <ClCompile Include="..\src\mcompand.c">
       <Filter>Effect Sources</Filter>
     </ClCompile>
-    <ClCompile Include="..\src\mixer.c">
-      <Filter>Effect Sources</Filter>
-    </ClCompile>
     <ClCompile Include="..\src\noiseprof.c">
       <Filter>Effect Sources</Filter>
     </ClCompile>
--- a/msvc9/LibSoX.vcproj
+++ b/msvc9/LibSoX.vcproj
@@ -730,10 +730,6 @@
 				>
 			</File>
 			<File
-				RelativePath="..\src\mixer.c"
-				>
-			</File>
-			<File
 				RelativePath="..\src\noiseprof.c"
 				>
 			</File>
--- a/sox.1
+++ b/sox.1
@@ -4174,66 +4174,6 @@
 for a volume-changing effect with different capabilities, and
 .B compand
 for a dynamic-range compression/expansion/limiting effect.
-.SS Deprecated Effects
-The following effects have been renamed or have their functionality
-included in another effect; they continue to work in this version of
-SoX but may be removed in future.
-.TP
-\fBmixer\fR [ \fB\-l\fR\^|\^\fB\-r\fR\^|\^\fB\-f\fR\^|\^\fB\-b\fR\^|\^\fB\-1\fR\^|\^\fB\-2\fR\^|\^\fB\-3\fR\^|\^\fB\-4\fR\^|\^\fIn\fR{\fB,\fIn\fR} ]
-Reduce the number of audio channels by mixing or selecting channels,
-or increase the number of channels by duplicating channels.
-Note: this effect operates on the audio
-.I channels
-within the SoX effects processing chain; it should not be confused with the
-.B \-m
-global option (where multiple
-.I files
-are mix-combined before entering the effects chain).
-.SP
-When reducing the number of channels it is possible to
-use the \fB\-l\fR, \fB\-r\fR, \fB\-f\fR, \fB\-b\fR,
-\fB\-1\fR, \fB\-2\fR, \fB\-3\fR, \fB\-4\fR, options to select only
-the left, right, front, back channel(s) or specific channel
-for the output instead of averaging the channels.
-The \fB\-l\fR, and \fB\-r\fR options will do averaging
-in quad-channel files so select the exact channel to prevent this.
-.SP
-The
-.B mixer
-effect can also be invoked with up to 16
-numbers, separated by commas, which specify the proportion (0 = 0% and 1 = 100%)
-of each input channel that is to be mixed into each output channel.
-In two-channel mode, 4 numbers are given: l \*(RA l, l \*(RA r, r \*(RA l, and r \*(RA r,
-respectively.
-In four-channel mode, the first 4 numbers give the proportions for the
-left-front output channel, as follows: lf \*(RA lf, rf \*(RA lf, lb \*(RA lf, and
-rb \*(RA rf.
-The next 4 give the right-front output in the same order, then
-left-back and right-back.
-.SP
-It is also possible to use the 16 numbers to expand or reduce the
-channel count; just specify 0 for unused channels.
-.SP
-Finally, certain reduced combination of numbers can be specified
-for certain input/output channel combinations.
-.ne 7
-.TS
-center;
-cI cI cI lI
-c c c l .
-In Ch	Out Ch	Num	Mappings
-2	1	2	l \*(RA l, r \*(RA l
-2	2	1	adjust balance
-4	1	4	lf \*(RA l, rf \*(RA l, lb \*(RA l, rb \*(RA l
-4	2	2	lf \*(RA l&rf \*(RA r, lb \*(RA l&rb \*(RA r
-4	4	1	adjust balance
-4	4	2	front balance, back balance
-.TE
-.DT
-.SP
-This effect has been superseded by the
-.B remix
-effect that handles any number of channels.
 .SH DIAGNOSTICS
 Exit status is 0 for no error, 1 if there is a problem with the
 command-line parameters, or 2 if an error occurs during file processing.
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -47,7 +47,6 @@
   input
   loudness
   mcompand
-  mixer
   noiseprof
   noisered
   output
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -72,7 +72,7 @@
 	echo.c echos.c effects.c effects.h effects_i.c effects_i_dsp.c \
 	fade.c fft4g.c fft4g.h fifo.h fir.c firfit.c flanger.c gain.c \
 	hilbert.c input.c ladspa.h ladspa.c loudness.c mcompand.c \
-	mcompand_xover.h mixer.c noiseprof.c noisered.c \
+	mcompand_xover.h noiseprof.c noisered.c \
 	noisered.h output.c overdrive.c pad.c phaser.c rate.c \
 	rate_filters.h rate_half_fir.h rate_poly_fir0.h rate_poly_fir.h \
 	remix.c repeat.c reverb.c reverse.c silence.c sinc.c skeleff.c \
--- a/src/effects.h
+++ b/src/effects.h
@@ -51,7 +51,6 @@
   EFFECT(loudness)
   EFFECT(lowpass)
   EFFECT(mcompand)
-  EFFECT(mixer)
   EFFECT(noiseprof)
   EFFECT(noisered)
   EFFECT(norm)
--- a/src/mixer.c
+++ /dev/null
@@ -1,553 +1,0 @@
-/* July 5, 1991
- * Copyright 1991 Lance Norskog And Sundry Contributors
- * This source code is freely redistributable and may be used for
- * any purpose.  This copyright notice must be maintained.
- * Lance Norskog And Sundry Contributors are not responsible for
- * the consequences of using this software.
- *
- * Channel duplication code by Graeme W. Gill - 93/5/18
- * General-purpose panning by Geoffrey H. Kuenning -- 2000/11/28
- */
-
-/*
- * libSoX stereo/quad -> mono mixdown effect file.
- * and mono/stereo -> stereo/quad channel duplication.
- */
-
-#include "sox_i.h"
-#include <ctype.h>
-#include <string.h>
-#include <stdlib.h>
-
-typedef struct {
-        /* How to generate each output channel.  sources[i][j] */
-        /* represents the fraction of channel i that should be passed */
-        /* through to channel j on output, and so forth.  Channel 0 is */
-        /* left front, channel 1 is right front, and 2 and 3 are left */
-        /* and right rear, respectively. (GHK) */
-        double  sources[4][4];
-        int     num_pans;
-        int     mix;                    /* How are we mixing it? */
-} priv_t;
-
-/* MIX_CENTER is shorthand to mix channels together at 50% each */
-#define MIX_CENTER      0
-#define MIX_SPECIFIED   1
-
-
-/*
- * Process options
- */
-static int getopts(sox_effect_t * effp, int argc, char **argv)
-{
-    priv_t * mixer = (priv_t *) effp->priv;
-    double* pans = &mixer->sources[0][0];
-    int i;
-  --argc, ++argv;
-
-    for (i = 0;  i < 16;  i++)
-        pans[i] = 0.0;
-    mixer->mix = MIX_CENTER;
-    mixer->num_pans = 0;
-
-    /* Parse parameters.  Since we don't yet know the number of */
-    /* input and output channels, we'll record the information for */
-    /* later. */
-    if (argc == 1) {
-        if      (!strcmp(argv[0], "-l")) mixer->mix = 'l';
-        else if (!strcmp(argv[0], "-r")) mixer->mix = 'r';
-        else if (!strcmp(argv[0], "-f")) mixer->mix = 'f';
-        else if (!strcmp(argv[0], "-b")) mixer->mix = 'b';
-        else if (!strcmp(argv[0], "-1")) mixer->mix = '1';
-        else if (!strcmp(argv[0], "-2")) mixer->mix = '2';
-        else if (!strcmp(argv[0], "-3")) mixer->mix = '3';
-        else if (!strcmp(argv[0], "-4")) mixer->mix = '4';
-        else if (argv[0][0] == '-' && !isdigit((int)argv[0][1])
-                && argv[0][1] != '.')
-          return lsx_usage(effp);
-        else {
-            int commas;
-            char *s;
-            mixer->mix = MIX_SPECIFIED;
-            pans[0] = atof(argv[0]);
-            for (s = argv[0], commas = 0; *s; ++s) {
-                if (*s == ',') {
-                    ++commas;
-                    if (commas >= 16) {
-                        lsx_fail("mixer can only take up to 16 pan values");
-                        return (SOX_EOF);
-                    }
-                    pans[commas] = atof(s+1);
-                }
-            }
-            mixer->num_pans = commas + 1;
-        }
-    }
-    else if (argc == 0) {
-        mixer->mix = MIX_CENTER;
-    }
-    else
-      return lsx_usage(effp);
-
-    return (SOX_SUCCESS);
-}
-
-/*
- * Start processing
- */
-static int start(sox_effect_t * effp)
-{
-    /*
-       Hmmm, this is tricky.  Lemme think:
-       channel orders are [0][0],[0][1], etc.
-       i.e., 0->0, 0->1, 0->2, 0->3, 1->0, 1->1, ...
-       trailing zeros are omitted
-       L/R balance is x= -1 for left only, 1 for right only
-       1->1 channel effects:
-       changing volume by x is x,0,0,0
-       1->2 channel effects:
-       duplicating everywhere is 1,1,0,0
-       1->4 channel effects:
-       duplicating everywhere is 1,1,1,1
-       2->1 channel effects:
-       left only is 1,0,0,0 0,0,0,0
-       right only is 0,0,0,0 1,0,0,0
-       left+right is 0.5,0,0,0 0.5,0,0,0
-       left-right is 1,0,0,0 -1,0,0,0
-       2->2 channel effects:
-       L/R balance can be done several ways.  The standard stereo
-       way is both the easiest and the most sensible:
-       min(1-x,1),0,0,0 0,min(1+x,1),0,0
-       left to both is 1,1,0,0
-       right to both is 0,0,0,0 1,1,0,0
-       left+right to both is 0.5,0.5,0,0 0.5,0.5,0,0
-       left-right to both is 1,1,0,0 -1,-1,0,0
-       left-right to left, right-left to right is 1,-1,0,0 -1,1,0,0
-       2->4 channel effects:
-       front duplicated into rear is 1,0,1,0 0,1,0,1
-       front swapped into rear (why?) is 1,0,0,1 0,1,1,0
-       front put into rear as mono (why?) is 1,0,0.5,0.5 0,1,0.5,0.5
-       4->1 channel effects:
-       left front only is 1,0,0,0
-       left only is 0.5,0,0,0 0,0,0,0 0.5,0,0,0
-       etc.
-       4->2 channel effects:
-       merge front/back is 0.5,0,0,0 0,0.5,0,0 0.5,0,0,0 0,0.5,0,0
-       selections similar to above
-       4->4 channel effects:
-       left front to all is 1,1,1,1 0,0,0,0
-       right front to all is 0,0,0,0 1,1,1,1
-       left f/r to all f/r is 1,1,0,0 0,0,0,0 0,0,1,1 0,0,0,0
-       etc.
-
-       The interesting cases from above (deserving of abbreviations of
-       less than 16 numbers) are:
-
-       0) n->n volume change (1 number)
-       1) 1->n duplication (0 numbers)
-       2) 2->1 mixdown (0 or 2 numbers)
-       3) 2->2 balance (1 number)
-       4) 2->2 fully general mix (4 numbers)
-       5) 2->4 duplication (0 numbers)
-       6) 4->1 mixdown (0 or 4 numbers)
-       7) 4->2 mixdown (0, or 2 numbers)
-       8) 4->4 balance (1 or 2 numbers)
-
-       The above has one ambiguity: n->n volume change conflicts with
-       n->n balance for n != 1.  In such a case, we'll prefer
-       balance, since there is already a volume effect in vol.c.
-
-       GHK 2000/11/28
-     */
-     priv_t * mixer = (priv_t *) effp->priv;
-     double pans[16];
-     int i, j;
-     int ichan, ochan;
-
-     for (i = 0;  i < 16;  i++)
-         pans[i] = ((double*)&mixer->sources[0][0])[i];
-
-     ichan = effp->in_signal.channels;
-     ochan = effp->out_signal.channels;
-     if (ochan == -1) {
-         lsx_fail("Output must have known number of channels");
-         return(SOX_EOF);
-     }
-
-     if ((ichan != 1 && ichan != 2 && ichan != 4 &&
-          mixer->mix != MIX_CENTER && ochan != 1)
-             ||  (ochan != 1 && ochan != 2 && ochan != 4)) {
-         lsx_fail("Can't mix %d -> %d channels", ichan, ochan);
-         return (SOX_EOF);
-     }
-
-     /* Handle the special-case flags */
-     switch (mixer->mix) {
-         case MIX_CENTER:
-             if (ichan == ochan)
-               return SOX_EFF_NULL;
-             break;             /* Code below will handle this case */
-         case 'l':
-             if (ichan == 2 && ochan == 1)
-             {
-                 pans[0] = 1.0;
-                 pans[1] = 0.0;
-                 mixer->num_pans = 2;
-             }
-             else if (ichan == 4 && ochan == 1)
-             {
-                 pans[0] = 0.5;
-                 pans[1] = 0.0;
-                 pans[2] = 0.5;
-                 pans[3] = 0.0;
-                 mixer->num_pans = 4;
-             }
-             else
-             {
-                 lsx_fail("Can't mix -%c %d -> %d channels", mixer->mix, ichan, ochan);
-                 return SOX_EOF;
-             }
-             break;
-         case 'r':
-             if (ichan == 2 && ochan == 1)
-             {
-                 pans[0] = 0.0;
-                 pans[1] = 1.0;
-                 mixer->num_pans = 2;
-             }
-             else if (ichan == 4 && ochan == 1)
-             {
-                 pans[0] = 0.0;
-                 pans[1] = 0.5;
-                 pans[2] = 0.0;
-                 pans[3] = 0.5;
-                 mixer->num_pans = 4;
-             }
-             else
-             {
-                 lsx_fail("Can't mix -%c %d -> %d channels", mixer->mix, ichan, ochan);
-                 return SOX_EOF;
-             }
-             break;
-         case 'f':
-             if (ichan == 4 && ochan == 2)
-             {
-                 pans[0] = 1.0;
-                 pans[1] = 0.0;
-                 mixer->num_pans = 2;
-             }
-             else if (ichan == 4 && ochan == 1)
-             {
-                 pans[0] = 0.5;
-                 pans[1] = 0.5;
-                 pans[2] = 0.0;
-                 pans[3] = 0.0;
-                 mixer->num_pans = 4;
-             }
-             else
-             {
-                 lsx_fail("Can't mix -%c %d -> %d channels", mixer->mix, ichan, ochan);
-                 return SOX_EOF;
-             }
-             break;
-         case 'b':
-             if (ichan == 4 && ochan == 2)
-             {
-                 pans[0] = 0.0;
-                 pans[1] = 1.0;
-                 mixer->num_pans = 2;
-             }
-             else if (ichan == 4 && ochan == 1)
-             {
-                 pans[0] = 0.0;
-                 pans[1] = 0.0;
-                 pans[2] = 0.5;
-                 pans[3] = 0.5;
-                 mixer->num_pans = 4;
-             }
-             else
-             {
-                 lsx_fail("Can't mix -%c %d -> %d channels", mixer->mix, ichan, ochan);
-                 return SOX_EOF;
-             }
-             break;
-         case '1':
-             if (ichan == 2 && ochan == 1)
-             {
-                 pans[0] = 1.0;
-                 pans[1] = 0.0;
-                 mixer->num_pans = 2;
-             }
-             else if (ichan == 4 && ochan == 1)
-             {
-                 pans[0] = 1.0;
-                 pans[1] = 0.0;
-                 pans[2] = 0.0;
-                 pans[3] = 0.0;
-                 mixer->num_pans = 4;
-             }
-             else
-             {
-                 lsx_fail("Can't mix -%c %d -> %d channels", mixer->mix, ichan, ochan);
-                 return SOX_EOF;
-             }
-             break;
-         case '2':
-             if (ichan == 2 && ochan == 1)
-             {
-                 pans[0] = 0.0;
-                 pans[1] = 1.0;
-                 mixer->num_pans = 2;
-             }
-             else if (ichan == 4 && ochan == 1)
-             {
-                 pans[0] = 0.0;
-                 pans[1] = 1.0;
-                 pans[2] = 0.0;
-                 pans[3] = 0.0;
-                 mixer->num_pans = 4;
-             }
-             else
-             {
-                 lsx_fail("Can't mix -%c %d -> %d channels", mixer->mix, ichan, ochan);
-                 return SOX_EOF;
-             }
-             break;
-
-         case '3':
-             if (ichan == 4 && ochan == 1)
-             {
-                 pans[0] = 0.0;
-                 pans[1] = 0.0;
-                 pans[2] = 1.0;
-                 pans[3] = 0.0;
-                 mixer->num_pans = 4;
-             }
-             else
-             {
-                 lsx_fail("Can't mix -%c %d -> %d channels", mixer->mix, ichan, ochan);
-                 return SOX_EOF;
-             }
-             break;
-
-         case '4':
-             if (ichan == 4 && ochan == 1)
-             {
-                 pans[0] = 0.0;
-                 pans[1] = 0.0;
-                 pans[2] = 0.0;
-                 pans[3] = 1.0;
-                 mixer->num_pans = 4;
-             }
-             else
-             {
-                 lsx_fail("Can't mix -%c %d -> %d channels", mixer->mix, ichan, ochan);
-                 return SOX_EOF;
-             }
-             break;
-
-         case MIX_SPECIFIED:
-             break;
-         default:
-             lsx_fail("Unknown mix option");
-             return SOX_EOF;
-     }
-
-     /* If number of pans is 4 or less then its a shorthand
-      * representation.  If user specified it, then we have
-      * garbage in our sources[][] array.  Need to clear that
-      * now that all data is stored in pans[] array.
-      */
-     if (mixer->num_pans <= 4)
-     {
-         for (i = 0; i < ichan; i++)
-         {
-             for (j = 0; j < ochan; j++)
-             {
-                 mixer->sources[i][j] = 0;
-             }
-         }
-     }
-
-     /* If the number of pans given is 4 or fewer, handle the special */
-     /* cases listed in the comments above.  The code is lengthy but */
-     /* straightforward. */
-     if (mixer->num_pans == 0) {
-         /* CASE 1 */
-         if (ichan == 1 && ochan > ichan) {
-             mixer->sources[0][0] = 1.0;
-             mixer->sources[0][1] = 1.0;
-             mixer->sources[0][2] = 1.0;
-             mixer->sources[0][3] = 1.0;
-         }
-         /* CASE 2, 6 */
-         else if (ochan == 1) {
-             mixer->sources[0][0] = 1.0 / ichan;
-         }
-         /* CASE 5 */
-         else if (ichan == 2 && ochan == 4) {
-             mixer->sources[0][0] = 1.0;
-             mixer->sources[0][2] = 1.0;
-             mixer->sources[1][1] = 1.0;
-             mixer->sources[1][3] = 1.0;
-         }
-         /* CASE 7 */
-         else if (ichan == 4 && ochan == 2) {
-             mixer->sources[0][0] = 0.5;
-             mixer->sources[1][1] = 0.5;
-             mixer->sources[2][0] = 0.5;
-             mixer->sources[3][1] = 0.5;
-         }
-         else {
-             lsx_fail("You must specify at least one mix level when using mixer with an unusual number of channels.");
-             return(SOX_EOF);
-         }
-     }
-     else if (mixer->num_pans == 1) {
-         /* Might be volume change or balance change */
-         /* CASE 3 and CASE 8 */
-         if ((ichan == 2 || ichan == 4) &&  ichan == ochan) {
-             /* -1 is left only, 1 is right only */
-             if (pans[0] <= 0.0) {
-                 mixer->sources[1][1] = pans[0] + 1.0;
-                 if (mixer->sources[1][1] < 0.0)
-                     mixer->sources[1][1] = 0.0;
-                 mixer->sources[0][0] = 1.0;
-             }
-             else {
-                 mixer->sources[0][0] = 1.0 - pans[0];
-                 if (mixer->sources[0][0] < 0.0)
-                     mixer->sources[0][0] = 0.0;
-                 mixer->sources[1][1] = 1.0;
-             }
-             if (ichan == 4) {
-                 mixer->sources[2][2] = mixer->sources[0][0];
-                 mixer->sources[3][3] = mixer->sources[1][1];
-             }
-         }
-         else
-         {
-             lsx_fail("Invalid options while not mixing");
-             return SOX_EOF;
-         }
-     }
-     else if (mixer->num_pans == 2) {
-         /* CASE 2 */
-         if (ichan == 2 && ochan == 1) {
-             mixer->sources[0][0] = pans[0];
-             mixer->sources[1][0] = pans[1];
-         }
-         /* CASE 7 */
-         else if (ichan == 4 && ochan == 2) {
-             mixer->sources[0][0] = pans[0];
-             mixer->sources[1][1] = pans[0];
-             mixer->sources[2][0] = pans[1];
-             mixer->sources[3][1] = pans[1];
-         }
-         /* CASE 8 */
-         else if (ichan == 4 && ochan == 4) {
-             /* pans[0] is front -> front, pans[1] is for back */
-             mixer->sources[0][0] = pans[0];
-             mixer->sources[1][1] = pans[0];
-             mixer->sources[2][2] = pans[1];
-             mixer->sources[3][3] = pans[1];
-         }
-         else
-         {
-             lsx_fail("Invalid options for this channel combination");
-             return SOX_EOF;
-         }
-     }
-     else if (mixer->num_pans == 3) {
-       lsx_fail("Invalid options while not mixing");
-       return SOX_EOF;
-     }
-     else if (mixer->num_pans == 4) {
-         /* CASE 4 */
-         if (ichan == 2 && ochan == 2) {
-             /* Shorthand for 2-channel case */
-             mixer->sources[0][0] = pans[0];
-             mixer->sources[0][1] = pans[1];
-             mixer->sources[1][0] = pans[2];
-             mixer->sources[1][1] = pans[3];
-         }
-         /* CASE 6 */
-         else if (ichan == 4 && ochan == 1) {
-             mixer->sources[0][0] = pans[0];
-             mixer->sources[1][0] = pans[1];
-             mixer->sources[2][0] = pans[2];
-             mixer->sources[3][0] = pans[3];
-         }
-         else
-         {
-             lsx_fail("Invalid options for this channel combination");
-             return SOX_EOF;
-         }
-     }
-
-     if (effp->in_signal.mult) {
-       double max_sum = 0;
-
-       for (j = 0; j < (int)effp->out_signal.channels; ++j) {
-         double sum = 0;
-         for (i = 0; i < (int)effp->in_signal.channels; ++i)
-           sum += fabs(mixer->sources[mixer->mix == MIX_CENTER? 0 : i][j]);
-         max_sum = max(max_sum, sum);
-       }
-       if (max_sum > 1)
-         *effp->in_signal.mult /= max_sum;
-     }
-
-     if (effp->in_signal.channels != effp->out_signal.channels)
-       return SOX_SUCCESS;
-
-     for (i = 0; i < (int)effp->in_signal.channels; ++i)
-       for (j = 0; j < (int)effp->out_signal.channels; ++j)
-         if (mixer->sources[i][j] != (i == j))
-           return SOX_SUCCESS;
-
-     return SOX_EFF_NULL;
-}
-
-/*
- * Process either isamp or osamp samples, whichever is smaller.
- */
-
-static int flow(sox_effect_t * effp, const sox_sample_t *ibuf, sox_sample_t *obuf,
-                size_t *isamp, size_t *osamp)
-{
-    priv_t * mixer = (priv_t *) effp->priv;
-    size_t len, done;
-    int ichan, ochan;
-    int i, j;
-    double samp;
-
-    ichan = effp->in_signal.channels;
-    ochan = effp->out_signal.channels;
-    len = *isamp / ichan;
-    if (len > *osamp / ochan)
-        len = *osamp / ochan;
-    for (done = 0; done < len; done++, ibuf += ichan, obuf += ochan) {
-        for (j = 0; j < ochan; j++) {
-            samp = 0.0;
-            for (i = 0; i < ichan; i++)
-                samp += ibuf[i] * mixer->sources[mixer->mix == MIX_CENTER? 0 : i][j];
-            SOX_SAMPLE_CLIP_COUNT(samp, effp->clips);
-            obuf[j] = samp;
-        }
-    }
-    *isamp = len * ichan;
-    *osamp = len * ochan;
-    return (SOX_SUCCESS);
-}
-
-sox_effect_handler_t const * lsx_mixer_effect_fn(void)
-{
-  static sox_effect_handler_t handler = {
-    "mixer",
-    "[ -l | -r | -f | -b | -1 | -2 | -3 | -4 | n,n,n...,n ]",
-    SOX_EFF_MCHAN | SOX_EFF_CHAN | SOX_EFF_GAIN | SOX_EFF_DEPRECATED,
-    getopts, start, flow, 0, 0, 0, sizeof(priv_t)
-  };
-  return &handler;
-}
--- a/src/sox.c
+++ b/src/sox.c
@@ -1377,7 +1377,7 @@
     {
       /* Not very useful, eh!  Sample though of the place you
        * could change the value to effects options
-       * like vol or speed or mixer.
+       * like vol or speed or remix.
        * Modify values in user_effargs[current_eff_chain][xxx]
        * and then chain will be drain()ed and restarted whence
        * this function is existed.