home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 35 Internet / 35-Internet.zip / sox1217s.zip / sox.txt < prev    next >
Text File  |  2000-11-19  |  43KB  |  1,321 lines

  1.  
  2.  
  3.  
  4. SoX(1)                               SoX(1)
  5.  
  6.  
  7. NAME
  8.        sox - Sound eXchange : universal sound sample translator
  9.  
  10. SYNOPSIS
  11.        sox infile outfile
  12.  
  13.        sox [ general options ] [ format options ] infile
  14.        -e effect [ effect options ]
  15.  
  16.        sox [ general options ] [ format options ] infile
  17.        [ format options ] outfile
  18.        [ effect [ effect options ] ... ]
  19.  
  20.        General options:
  21.        [ -h ] [ -p ] [ -v volume ] [ -V ]
  22.  
  23.        Format options:
  24.        [ -t filetype ] [ -r rate ] [ -s/-u/-U/-A/-a/-i/-g ]
  25.        [ -b/-w/-l/-f/-d/-D ]
  26.        [ -c channels ] [ -x ] [ -e ]
  27.  
  28.        Effects:
  29.        avg [ -l | -r ]
  30.        band [ -n ] center [ width ]
  31.        bandpass frequency bandwidth
  32.        bandreject frequency bandwidth
  33.        chorus gain-in gain out delay decay speed depth
  34.           -s | -t [ delay decay speed depth -s | -t ]
  35.        compand attack1,decay1[,attack2,decay2...]
  36.            in-dB1,out-dB1[,in-dB2,out-dB2...]
  37.            [ gain ] [ initial-volume ]
  38.        copy
  39.        cut
  40.        deemph
  41.        earwax
  42.        echo gain-in gain-out delay decay [ delay decay ... ]
  43.        echos gain-in gain-out delay decay [ delay decay ... ]
  44.        fade [ type ] fade-in-length
  45.         [ stop-time [ fade-out-length ] ]
  46.        filter [ low ]-[ high ] [ window-len [ beta ]]
  47.        flanger gain-in gain-out delay decay speed < -s | -t >
  48.        highp frequency
  49.        highpass frequency
  50.        lowp frequency
  51.        lowpass frequency
  52.        map
  53.        mask
  54.        pan direction
  55.        phaser gain-in gain-out delay decay speed < -s | -t >
  56.        pick [ -1 | -2 | -3 | -4 | -l | -r ]
  57.        pitch shift [ width interpole fade ]
  58.        polyphase [ -w < nut / ham > ]
  59.              [    -width < long / short / # > ]
  60.              [ -cutoff # ]
  61.  
  62.  
  63.  
  64.               July 24, 2000                1
  65.  
  66.  
  67.  
  68.  
  69.  
  70. SoX(1)                               SoX(1)
  71.  
  72.  
  73.        rate
  74.        resample [ -qs | -q | -ql ] [ rolloff [ beta ] ]
  75.        reverb gain-out reverb-time delay [ delay ... ]
  76.        reverse
  77.        speed factor
  78.        split
  79.        stat [ -s n ] [ -rms ] [ -v ] [ -d ]
  80.        stretch [ factor [ window fade shift fading ]
  81.        swap [ 1 2 | 1 2 3 4 ]
  82.        trim start [ length ]
  83.        vibro speed [ depth ]
  84.        vol gain [ type [ limitergain ] ]
  85.  
  86. DESCRIPTION
  87.        SoX  is a command line program that can convert most popu¡
  88.        lar audio files to most other popular audio file     formats.
  89.        It  can    optionally  change the audio sample data type and
  90.        apply one or more sound effects to the  file  during  this
  91.        translation.
  92.  
  93.        There  are  two    types of audio files formats that SoX can
  94.        work with.  The first are  self-describing  file     formats.
  95.        These  contain a header that completely describe the char¡
  96.        acteristics of the audio data that follows.
  97.  
  98.        The second type are headerless data, or    sometimes  called
  99.        raw  data.   A user must pass enough information to SoX on
  100.        the command line so that it knows what  type  of     data  it
  101.        contains.
  102.  
  103.        Audio  data can usually be totally described by four char¡
  104.        acteristics:
  105.  
  106.        rate     The sample rate is in samples per  second.   For
  107.          example, CD sample rates are at 44100.
  108.  
  109.        data size The precision the data is stored in.  Most popu¡
  110.          lar are 8-bit bytes or 16-bit words.
  111.  
  112.        data encoding
  113.          What encoding the data type uses.  Examples  are
  114.          u-law, ADPCM, or signed linear data.
  115.  
  116.        channels     How  many  channels  are  contained in the audio
  117.          data.    Mono and Stereo are the two most  common.
  118.  
  119.        Please  refer  to  the  soxexam(1)  manual page for a long
  120.        description with examples on how to use sox  with  various
  121.        types of file formats.
  122.  
  123. OPTIONS
  124.        The option syntax is a little grotty, but in essence:
  125.  
  126.         sox file.au file.wav
  127.  
  128.  
  129.  
  130.               July 24, 2000                2
  131.  
  132.  
  133.  
  134.  
  135.  
  136. SoX(1)                               SoX(1)
  137.  
  138.  
  139.        translates  a  sound  file  in SUN Sparc .AU format into a
  140.        Microsoft .WAV file, while
  141.  
  142.         sox -v 0.5 file.au -r 12000 file.wav mask
  143.  
  144.        does the same  format  translation  but    also  lowers  the
  145.        amplitude  by  1/2,  changes  the  sampling  rate to 12000
  146.        hertz, and applies the mask  sound  effect  to  the  audio
  147.        data.
  148.  
  149.        Format options:
  150.  
  151.        Format  options effect the audio samples that they immedi¡
  152.        ately preceed.  If they are placed before the  input  file
  153.        name  then they effect the input data.  If they are placed
  154.        before the output file name then they will effect the out¡
  155.        put data.  By taking advantage of this, you can override a
  156.        input file's corrupted header or produce     an  output  file
  157.        that  is     totally different style then the input file.  It
  158.        is also how sox is informed about the format of raw  input
  159.        data.
  160.  
  161.        -t filetype
  162.          gives the type of the sound sample file.  Useful
  163.          when file extension is not standard or for spec¡
  164.          ifying the .auto file type.
  165.  
  166.        -r rate     Gives    the sample rate in Hertz of the file.  To
  167.          cause the output file to have a different sample
  168.          rate than the input file, include this option as
  169.          a part of the output options.
  170.          If the input and  output  files  have    different
  171.          rates    then  a sample rate change effect must be
  172.          ran.  If a sample rate changing  effect  is  not
  173.          specified  then a default one will internally be
  174.          ran by sox using its default parameters.
  175.  
  176.        -s/-u/-U/-A/-a/-i/-g
  177.          The sample data encoding is signed  linear  (2's
  178.          complement),  unsigned     linear, U-law (logarith¡
  179.          mic), A-law (logarithmic), ADPCM, IMA_ADPCM,  or
  180.          GSM.
  181.          U-law    (actually shorthand for mu-law) and A-law
  182.          are the U.S.  and  international  standards  for
  183.          logarithmic  telephone     sound compression.  When
  184.          uncompressed it has  roughly  the  precision  of
  185.          12-byte PCM audio.
  186.          ADPCM    is  form  of sound compression that has a
  187.          good compromise between good sound  quality  and
  188.          fast  encoding/decoding  time.      It  is used for
  189.          telephone sound compression and places were full
  190.          fidelity is not as important.    When uncompressed
  191.          it has     roughly  the  precision  of  16-bit  PCM
  192.          audio.      Popular version of ADPCM include G.726,
  193.  
  194.  
  195.  
  196.               July 24, 2000                3
  197.  
  198.  
  199.  
  200.  
  201.  
  202. SoX(1)                               SoX(1)
  203.  
  204.  
  205.          MS ADPCM, and IMA ADPCM.  The -a flag    has  dif¡
  206.          ferent     meanings in different file handlers.  In
  207.          .wav files it represents MS ADPCM files, in  all
  208.          others     it  means  G.726  ADPCM.  IMA ADPCM is a
  209.          specific form    of  adpcm  compression,     slightly
  210.          simpler   and     slightly   lower  fidelity  than
  211.          Microsoft's flavor of ADPCM.  IMA ADPCM is  also
  212.          called DVI ADPCM.
  213.          GSM  is a standard used for telephone sound com¡
  214.          pression in European countries and  its  gaining
  215.          popularity  because  of its quality.  It usually
  216.          is CPU intensive to work with GSM audio data.
  217.  
  218.        -b/-w/-l/-f/-d/-D
  219.          The sample data size is in bytes, 16-bit  words,
  220.          32-bit     longwords,  32-bit floats, 64-bit double
  221.          floats, or 80-bit IEEE floats.     Floats and  dou¡
  222.          ble floats are in native machine format.
  223.  
  224.        -x     The  sample  data is in XINU format; that is, it
  225.          comes from a  machine    with  the  opposite  word
  226.          order    than  yours and must be swapped according
  227.          to the word-size given above.    Only  16-bit  and
  228.          32-bit     integer  data    may be swapped.     Machine-
  229.          format     floating-point     data  is  not    portable.
  230.          IEEE floats are a fixed, portable format.
  231.  
  232.        -c channels
  233.          The  number  of sound channels in the data file.
  234.          This may be 1, 2, or 4;  for  mono,  stereo,  or
  235.          quad  sound  data.   To cause the output file to
  236.          have a different number  of  channels    than  the
  237.          input    file, include this option with the output
  238.          file options.    If the input and output file have
  239.          a  different  number  of  channels  then the avg
  240.          effect must be used.  If the avg effect  is  not
  241.          specified on the command line it will be invoked
  242.          internally with default parameters.
  243.  
  244.        -e     When used after the input filename (so     that  it
  245.          applies  to  the  output  file) it allows you to
  246.          avoid giving an output     filename  and    will  not
  247.          produce an output file.  It will apply any spec¡
  248.          ified effects to the input file.  This is mainly
  249.          useful with the stat effect but can be used with
  250.          others.
  251.  
  252.        General options:
  253.  
  254.        -h     Print version number and usage information.
  255.  
  256.        -p     Run in preview mode and  run  fast.   This  will
  257.          somewhat speed up sox when the output format has
  258.          a different number of channels and  a    different
  259.  
  260.  
  261.  
  262.               July 24, 2000                4
  263.  
  264.  
  265.  
  266.  
  267.  
  268. SoX(1)                               SoX(1)
  269.  
  270.  
  271.          rate  than  the  input     file.     Currently,  this
  272.          defaults to using the rate effect instead of the
  273.          resample effect for sample rate changes.
  274.  
  275.        -v volume Change amplitude (floating point); less than 1.0
  276.          decreases, greater than 1.0 increases.     May  use
  277.          a  negative  number  to  invert the phase of the
  278.          audio data.  It is interesting to note     that  we
  279.          percieve volume logarithmically but this adjusts
  280.          the amplitude linearly.
  281.          Note: see the stat  effect  for  information  on
  282.          finding  the maximum value that can be used with
  283.          this option without causing  audio  data  be  be
  284.          clipped.
  285.  
  286.        -V     Print    a description of processing phases.  Use¡
  287.          ful for figuring out exactly how sox is mangling
  288.          your sound samples.
  289.  
  290. FILE TYPES
  291.        SoX  uses  the file extension of the input and output file
  292.        to determine what type of file format to use.  This can be
  293.        overridden  by  specifying  the "-t" option on the command
  294.        line.
  295.  
  296.        The input and output files may be read  from  standard  in
  297.        and  out.  This is done by specifying '-' as the filename.
  298.  
  299.        File formats which  have     headers  are  checked,     if  that
  300.        header  doesn't    seem  right,  the  program  exits with an
  301.        appropriate message.
  302.  
  303.        The following file formats are supported:
  304.  
  305.  
  306.        .8svx     Amiga 8SVX musical instrument    description  for¡
  307.          mat.
  308.  
  309.        .aiff     AIFF  files  used  on    Apple  IIc/IIgs     and SGI.
  310.          Note: the AIFF format    supports  only    one  SSND
  311.          chunk.      It  does  not     support  multiple  sound
  312.          chunks, or the 8SVX musical instrument     descrip¡
  313.          tion format.  AIFF files are multimedia archives
  314.          and can have multiple audio and picture  chunks.
  315.          You  may  need     a separate archiver to work with
  316.          them.
  317.  
  318.        .au     SUN Microsystems AU files.  There are apparently
  319.          many  types  of  .au files; DEC has invented its
  320.          own with  a  different     magic    number    and  word
  321.          order.     The .au handler can read these files but
  322.          will not write them.  Some .au files have  valid
  323.          AU  headers  and  some     do  not.  The latter are
  324.          probably original SUN    u-law  8000  hz     samples.
  325.  
  326.  
  327.  
  328.               July 24, 2000                5
  329.  
  330.  
  331.  
  332.  
  333.  
  334. SoX(1)                               SoX(1)
  335.  
  336.  
  337.          These    can  be     dealt    with using the .ul format
  338.          (see below).
  339.  
  340.        .avr     Audio Visual Research
  341.          The AVR format is produced by a number     of  com¡
  342.          mercial packages on the Mac.
  343.  
  344.        .cdr     CD-R
  345.          CD-R  files  are used in mastering music on Com¡
  346.          pact Disks.  The audio data on a CD-R disk is    a
  347.          raw  audio  file  with a format of stereo 16-bit
  348.          signed samples at a 44khz sample rate.     There is
  349.          a  special blocking/padding oddity at the end of
  350.          the audio file and is why it needs its own  han¡
  351.          dler.
  352.  
  353.        .cvs     Continuously Variable Slope Delta modulation
  354.          Used  to  compress speech audio for applications
  355.          such as voice mail.
  356.  
  357.        .dat     Text Data files
  358.          These files contain a textual representation  of
  359.          the  sample  data.   There  is     one  line at the
  360.          beginning that contains the sample rate.  Subse¡
  361.          quent    lines contain two numeric data items: the
  362.          time since the beginning of the first sample and
  363.          the sample value.  Values are normalized so that
  364.          the maximum and  minimum  are    1.00  and  -1.00.
  365.          This  file  format  can  be  used to create data
  366.          files for external programs such as FFT  analyz¡
  367.          ers  or  graph routines.  SoX can also convert a
  368.          file in this format back into one of  the  other
  369.          file formats.
  370.  
  371.        .gsm     GSM 06.10 Lossy Speech Compression
  372.          A  standard for compressing speech which is used
  373.          in the Global Standard for Mobil  telecommunica¡
  374.          tions    (GSM).    Its good for its purpose, shrink¡
  375.          ing audio data size, but it will introduce  lots
  376.          of  noise  when  a given sound sample is encoded
  377.          and decoded multiple times.  This format is used
  378.          by  some  voice mail applications.  It is rather
  379.          CPU intensive.
  380.          GSM in sox is optional and requires access to an
  381.          external  GSM    library.  To see if there is sup¡
  382.          port for gsm run sox -h and look  for    it  under
  383.          the list of supported file formats.
  384.  
  385.        .hcom     Macintosh  HCOM  files.   These are (apparently)
  386.          Mac FSSD files with some variant of Huffman com¡
  387.          pression.   The Macintosh has wacky file formats
  388.          and this format handler apparently doesn't  han¡
  389.          dle all the ones it should.  Mac users will need
  390.          your usual arsenal of file  converters     to  deal
  391.  
  392.  
  393.  
  394.               July 24, 2000                6
  395.  
  396.  
  397.  
  398.  
  399.  
  400. SoX(1)                               SoX(1)
  401.  
  402.  
  403.          with an HCOM file under Unix or DOS.
  404.  
  405.        .maud     An Amiga format
  406.          An IFF-conform sound file type, registered by MS
  407.          MacroSystem Computer GmbH, published along  with
  408.          the  "Toccata"     sound-card on the Amiga.  Allows
  409.          8bit linear, 16bit linear, A-Law, u-law in  mono
  410.          and stereo.
  411.  
  412.        ossdsp     OSS /dev/dsp device driver
  413.          This is a pseudo-file type and can be optionally
  414.          compiled into Sox.  Run sox -h     to  see  if  you
  415.          have  support    for  this  file     type.    When this
  416.          driver is used it allows you to open up the  OSS
  417.          /dev/dsp  file     and configure it to use the same
  418.          data format as passed in to  /fBSoX.    It  works
  419.          for  both  playing  and recording sound samples.
  420.          When playing sound files it attempts to  set  up
  421.          the  OSS  driver  to  use the same format as the
  422.          input file.  It is suggested to always     override
  423.          the  output  values  to  use the highest quality
  424.          samples your sound card can handle.  Example: -t
  425.          ossdsp -w -s /dev/dsp
  426.  
  427.        .sf     IRCAM Sound Files.
  428.          Sound    Files are used by academic music software
  429.          such as the  CSound  package,    and  the  MixView
  430.          sound sample editor.
  431.  
  432.        .sph
  433.          SPHERE     (SPeech HEader Resources) is a file for¡
  434.          mat defined by NIST (National Institute of Stan¡
  435.          dards    and  Technology)  and is used with speech
  436.          audio.     SoX can read these files when they  con¡
  437.          tain  ulaw  and  PCM  data.   It will ignore any
  438.          header information that says the  data     is  com¡
  439.          pressed using shorten compression and will treat
  440.          the data as either ulaw or PCM.  This will allow
  441.          SoX  and  the command line shorten program to be
  442.          ran together using pipes to uncompress the  data
  443.          and  then pass the result to SoX for processing.
  444.  
  445.        .smp     Turtle Beach SampleVision files.
  446.          SMP files are for use with  the  PC-DOS  package
  447.          SampleVision  by  Turtle  Beach  Softworks. This
  448.          package is for     communication    to  several  MIDI
  449.          samplers.  All sample rates are supported by the
  450.          package, although not all are supported  by  the
  451.          samplers  themselves.    Currently loop points are
  452.          ignored.
  453.  
  454.        .snd
  455.          Under DOS this file format is the  same  as  the
  456.          .sndt    format.      Under all other platforms it is
  457.  
  458.  
  459.  
  460.               July 24, 2000                7
  461.  
  462.  
  463.  
  464.  
  465.  
  466. SoX(1)                               SoX(1)
  467.  
  468.  
  469.          the same as the .au format.
  470.  
  471.        .sndt     SoundTool files.
  472.          This is an older DOS file format.
  473.  
  474.        sunau     Sun /dev/audio device driver
  475.          This is a pseudo-file type and can be optionally
  476.          compiled  into     Sox.    Run  sox -h to see if you
  477.          have support for  this     file  type.   When  this
  478.          driver     is  used  it allows you to open up a Sun
  479.          /dev/audio file and configure it to use the same
  480.          data  type  as     passed     in to Sox.  It works for
  481.          both playing and recording sound samples.   When
  482.          playing  sound     files    it attempts to set up the
  483.          audio driver to use the same format as the input
  484.          file.     It  is     suggested to always override the
  485.          output values to use the highest quality samples
  486.          your  hardware can handle.  Example: -t sunau -w
  487.          -s /dev/audio or -t sunau -U -c 1 /dev/audio for
  488.          older sun equipment.
  489.  
  490.        .txw     Yamaha TX-16W sampler.
  491.          A  file  format  from a Yamaha sampling keyboard
  492.          which wrote IBM-PC format 3.5"     floppies.   Han¡
  493.          dles reading of files which do not have the sam¡
  494.          ple rate field set to one  of    the  expected  by
  495.          looking  at  some other bytes in the attack/loop
  496.          length fields, and defaulting to  33kHz  if  the
  497.          sample rate is still unknown.
  498.  
  499.        .vms     More info to come.
  500.          Used  to  compress speech audio for applications
  501.          such as voice mail.
  502.  
  503.        .voc     Sound Blaster VOC files.
  504.          VOC files are    multi-part  and     contain  silence
  505.          parts,     looping,  and different sample rates for
  506.          different chunks.  On input, the  silence  parts
  507.          are  filled  out, loops are rejected, and sample
  508.          data  with  a    new  sample  rate  is    rejected.
  509.          Silence  with    a different sample rate is gener¡
  510.          ated appropriately.  On output, silence  is  not
  511.          detected, nor are impossible sample rates.
  512.  
  513.        .wav     Microsoft .WAV RIFF files.
  514.          These    appear    to  be very similar to IFF files,
  515.          but not the same.  They  are  the  native  sound
  516.          file format of Windows.  (Obviously, Windows was
  517.          of such incredible importance    to  the     computer
  518.          industry  that it just had to have its own sound
  519.          file format.)    Normally .wav files have all for¡
  520.          matting  information in their headers, and so do
  521.          not need any format  options  specified  for  an
  522.          input    file.  If any are, they will override the
  523.  
  524.  
  525.  
  526.               July 24, 2000                8
  527.  
  528.  
  529.  
  530.  
  531.  
  532. SoX(1)                               SoX(1)
  533.  
  534.  
  535.          file header, and you  will  be     warned     to  this
  536.          effect.  You had better know what you are doing!
  537.          Output format options will cause a  format  con¡
  538.          version,  and    the  .wav  will written appropri¡
  539.          ately.     Sox currently can read PCM, ULAW,  ALAW,
  540.          MS  ADPCM, and IMA (or DVI) ADPCM.  It can write
  541.          all of these formats including (NEW!)    the ADPCM
  542.          encoding.
  543.  
  544.        .wve     Psion 8-bit alaw
  545.          These    are  8-bit a-law 8khz sound files used on
  546.          the Psion palmtop portable computer.
  547.  
  548.        .raw     Raw files (no header).
  549.          The sample rate, size    (byte,    word,  etc),  and
  550.          encoding (signed, unsigned, etc.)  of the sample
  551.          file must be  given.    The  number  of     channels
  552.          defaults to 1.
  553.  
  554.        .ub, .sb, .uw, .sw, .ul, .al, .sl
  555.          These    are  several  suffices    which  serve as a
  556.          shorthand for raw files with a     given    size  and
  557.          encoding.   Thus, ub, sb, uw, sw, ul and sl cor¡
  558.          respond  to  "unsigned     byte",     "signed   byte",
  559.          "unsigned  word",  "signed word", "ulaw" (byte),
  560.          "alaw" (byte), and "signed  long".   The  sample
  561.          rate  defaults to 8000 hz if not explicitly set,
  562.          and the number of channels (as always)     defaults
  563.          to  1.     There are lots of Sparc samples floating
  564.          around in u-law format with no header and  fixed
  565.          at  a    sample    rate  of 8000 hz.  (Certain sound
  566.          management software cheerfully ignores the head¡
  567.          ers.)     Similarly,  most  Mac sound files are in
  568.          unsigned byte format with a sample rate of 11025
  569.          or 22050 hz.
  570.  
  571.        .auto     This  is  a  ``meta-type'': specifying this type
  572.          for an input file triggers some code that  tries
  573.          to  guess  the     real  type  by looking for magic
  574.          words in the  header.     If  the  type    can't  be
  575.          guessed,  the    program     exits with an error mes¡
  576.          sage.    The input must be a  plain  file,  not    a
  577.          pipe.    This type can't be used for output files.
  578.  
  579. EFFECTS
  580.        Multiple effects may be applied to the audio data by spec¡
  581.        ifying  them  one  after another at the end of the command
  582.        line.
  583.  
  584.        avg [ -l | -r ]
  585.          Reduce the number of channels by  averaging  the
  586.          samples,  or  duplicate channels to increase the
  587.          number of channels.  This  effect  is    automati¡
  588.          cally    used  when  the     number of input channels
  589.  
  590.  
  591.  
  592.               July 24, 2000                9
  593.  
  594.  
  595.  
  596.  
  597.  
  598. SoX(1)                               SoX(1)
  599.  
  600.  
  601.          differ from the number of output channels.  When
  602.          reducing  the    number of channels it is possible
  603.          to manually specify the avg effect and     use  the
  604.          -l  and  -r  options  to select only the left or
  605.          right channel for the output instead of  averag¡
  606.          ing the two channels.
  607.  
  608.        band [ -n ] center [ width ]
  609.          Apply     a   band-pass     filter.   The    frequency
  610.          response drops logarithmically around the center
  611.          frequency.   The  width  gives     the slope of the
  612.          drop.    The frequencies at  center  +  width  and
  613.          center     -  width  will be half of their original
  614.          amplitudes.  Band defaults to a mode oriented to
  615.          pitched signals, i.e. voice, singing, or instru¡
  616.          mental music.    The -n (for  noise)  option  uses
  617.          the   alternate  mode    for  un-pitched     signals.
  618.          Warning: -n introduces     a  power-gain    of  about
  619.          11dB  in  the    filter, so beware of output clip¡
  620.          ping.    Band introduces noise in the shape of the
  621.          filter, i.e. peaking at the center frequency and
  622.          settling around it.  See filter for  a     bandpass
  623.          effect with steeper shoulders.
  624.  
  625.        bandpass frequency bandwidth
  626.          Butterworth  bandpass filter. Description coming
  627.          soon!
  628.  
  629.        bandreject frequency bandwidth
  630.          Butterworth bandreject filter.     Description com¡
  631.          ing soon!
  632.  
  633.        chorus gain-in gain-out delay decay speed depth
  634.  
  635.           -s | -t [ delay decay speed depth -s | -t ... ]
  636.          Add  a chorus to a sound sample.  Each quadtuple
  637.          delay/decay/speed/depth gives the delay in  mil¡
  638.          liseconds  and     the  decay (relative to gain-in)
  639.          with a modulation speed in  Hz     using    depth  in
  640.          milliseconds.    The modulation is either sinodial
  641.          (-s) or triangular (-t).  Gain-out is the volume
  642.          of the output.
  643.  
  644.        compand attack1,decay1[,attack2,decay2...]
  645.  
  646.            in-dB1,out-dB1[,in-dB2,out-dB2...]
  647.  
  648.            [gain] [initial-volume]
  649.          Compand  (compress  or expand) the dynamic range
  650.          of a sample.  The attack and decay time  specify
  651.          the  integration  time     over  which the absolute
  652.          value of  the    input  signal  is  integrated  to
  653.          determine  its volume.     Where more than one pair
  654.          of attack/decay parameters are     specified,  each
  655.  
  656.  
  657.  
  658.               July 24, 2000                   10
  659.  
  660.  
  661.  
  662.  
  663.  
  664. SoX(1)                               SoX(1)
  665.  
  666.  
  667.          channel  is treated separately and the number of
  668.          pairs must agree with the number of input  chan¡
  669.          nels.     The second parameter is a list of points
  670.          on the compander's transfer  function    specified
  671.          in  dB     relative  to the maximum possible signal
  672.          amplitude.   The  input  values  must    be  in    a
  673.          strictly increasing order but the transfer func¡
  674.          tion does not have to be  monotonically  rising.
  675.          The  special  value -inf may be used to indicate
  676.          that the input volume should be associated  out¡
  677.          put  volume.    The  points -inf,-inf and 0,0 are
  678.          assumed; the latter may be overridden,     but  the
  679.          former     may not.  The third (optional) parameter
  680.          is a postprocessing gain in dB which is  applied
  681.          after    the  compression  has  taken  place;  the
  682.          fourth (optional) parameter is an initial volume
  683.          to  be     assumed for each channel when the effect
  684.          starts.  This permits the user to supply a nomi¡
  685.          nal  level  initially,     so  that, for example, a
  686.          very large gain is not applied to initial signal
  687.          levels before the companding action has begun to
  688.          operate: it is quite probable that  in     such  an
  689.          event,     the  output  would  be     severely clipped
  690.          while    the  compander    gain   properly      adjusts
  691.          itself.
  692.  
  693.        copy     Copy the input file to the output file.  This is
  694.          the default effect if both files have    the  same
  695.          sampling rate.
  696.  
  697.        cut loopnumber
  698.          Extract loop #N from a sample.
  699.  
  700.        deemph     Apply    a  treble  attenuation shelving filter to
  701.          samples  in  audio  cd     format.   The    frequency
  702.          response  of pre-emphasized recordings is recti¡
  703.          fied.    The filtering is defined in the     standard
  704.          document ISO 908.
  705.  
  706.        earwax     Makes    sound  easier to listen to on headphones.
  707.          Adds audio-cues to samples in audio cd format so
  708.          that  when  listened to on headphones the stereo
  709.          image is moved from inside your  head    (standard
  710.          for  headphones)  to outside and in front of the
  711.          listener (standard for speakers). See
  712.          www.geocities.com/beinges for    a  full     explana¡
  713.          tion.
  714.  
  715.        echo gain-in gain-out delay decay [ delay decay ... ]
  716.          Add echoing to a sound sample.     Each delay/decay
  717.          part gives the delay  in  milliseconds     and  the
  718.          decay (relative to gain-in) of that echo.  Gain-
  719.          out is the volume of the output.
  720.  
  721.  
  722.  
  723.  
  724.               July 24, 2000                   11
  725.  
  726.  
  727.  
  728.  
  729.  
  730. SoX(1)                               SoX(1)
  731.  
  732.  
  733.        echos gain-in gain-out delay decay [ delay decay ... ]
  734.          Add a sequence of echos to a sound sample.  Each
  735.          delay/decay part gives the delay in milliseconds
  736.          and the decay    (relative  to  gain-in)     of  that
  737.          echo.    Gain-out is the volume of the output.
  738.  
  739.        fade [ type ] fade-in-length
  740.  
  741.         [ stop-time [ fade-out-length ] ]
  742.          Add a fade effect to the beginning, end, or both
  743.          of the audio data.
  744.  
  745.          For fade-ins, this starts from the first  sample
  746.          and ramps the volume of the audio from 0 to full
  747.          volume over fade-in-length seconds.   Specify    0
  748.          seconds if no fade-in is wanted.
  749.  
  750.          For  fade-outs,  the audio data will be trucated
  751.          at the stop-time and the volume will  be  ramped
  752.          from full volume down to 0 starting at fade-out-
  753.          length seconds before the stop-time.    No  fade-
  754.          out is performed if these options are not speci¡
  755.          fied.
  756.  
  757.          An optional type can be specified to change  the
  758.          type  of envelope.  Choices are q for quarter of
  759.          a sinewave, h for half a sinewave, t for  linear
  760.          slope,     l  for     logarithmic,  and p for inverted
  761.          parabola.  The default is a linear slope.
  762.  
  763.        filter [ low ]-[ high ] [ window-len [ beta ] ]
  764.          Apply    a  Sinc-windowed  lowpass,  highpass,  or
  765.          bandpass  filter  of  given window length to the
  766.          signal.  low refers  to  the  frequency  of  the
  767.          lower    6dB corner of the filter.  high refers to
  768.          the frequency of the upper  6dB  corner  of  the
  769.          filter.
  770.  
  771.          A  lowpass  filter  is     obtained  by leaving low
  772.          unspecified,  or  0.    A  highpass   filter   is
  773.          obtained  by  leaving high unspecified, or 0, or
  774.          greater than or equal to the Nyquist  frequency.
  775.  
  776.          The window-len, if unspecified, defaults to 128.
  777.          Longer windows give a    sharper     cutoff,  smaller
  778.          windows a more gradual cutoff.
  779.  
  780.          The  beta, if unspecified, defaults to 16.  This
  781.          selects a Kaiser window.  You can select a  Nut¡
  782.          tall  window by specifying anything <= 2.0 here.
  783.          For more discussion  of  beta,     look  under  the
  784.          resample effect.
  785.  
  786.  
  787.  
  788.  
  789.  
  790.               July 24, 2000                   12
  791.  
  792.  
  793.  
  794.  
  795.  
  796. SoX(1)                               SoX(1)
  797.  
  798.  
  799.        flanger gain-in gain-out delay decay speed < -s | -t >
  800.          Add  a     flanger  to a sound sample.  Each triple
  801.          delay/decay/speed gives the delay  in    millisec¡
  802.          onds  and the decay (relative to gain-in) with a
  803.          modulation  speed  in    Hz.   The  modulation  is
  804.          either     sinodial (-s) or triangular (-t).  Gain-
  805.          out is the volume of the output.
  806.  
  807.        highp frequency
  808.          Apply a single pole recursive high-pass  filter.
  809.          The  frequency     response  drops  logarithmically
  810.          with I frequency in the middle of the drop.  The
  811.          slope of the filter is quite gentle.  See filter
  812.          for a highpass effect with sharper cutoff.
  813.  
  814.        highpass frequency
  815.          Butterworth highpass filter.    Description  com¡
  816.          ming soon!
  817.  
  818.        lowp frequency
  819.          Apply    a  single pole recursive low-pass filter.
  820.          The  frequency     response  drops  logarithmically
  821.          with  frequency  in the middle of the drop.  The
  822.          slope of the filter is quite gentle.  See filter
  823.          for a lowpass effect with sharper cutoff.
  824.  
  825.        lowpass frequency
  826.          Butterworth  lowpass filter.  Description coming
  827.          soon!
  828.  
  829.        map     Display a list of loops in a sample, and miscel¡
  830.          laneous loop info.
  831.  
  832.        mask     Add  "masking    noise"    to  signal.   This effect
  833.          deliberately adds white  noise     to  a    sound  in
  834.          order    to  mask quantization effects, created by
  835.          the process of playing a  sound  digitally.   It
  836.          tends    to  mask buzzing voices, for example.  It
  837.          adds 1/2 bit of noise to the sound file  at  the
  838.          output bit depth.
  839.  
  840.        pan direction
  841.          Pan  the sound of an audio file from one channel
  842.          to another.  This is done by changing the volume
  843.          of  the  input     channels so that it fades out on
  844.          one channel and fades-in  on  another.      If  the
  845.          number     of  input channels is different then the
  846.          number of output channels then this effect tries
  847.          to  intelligently handle this.     For instance, if
  848.          the input contains 1 channel and the output con¡
  849.          tains    2 channels, then it will create the miss¡
  850.          ing channel itself.  The direction  is     a  value
  851.          from  -1.0 to 1.0.  -1.0 represents far left and
  852.          1.0 represents far right.   Numbers  in  between
  853.  
  854.  
  855.  
  856.               July 24, 2000                   13
  857.  
  858.  
  859.  
  860.  
  861.  
  862. SoX(1)                               SoX(1)
  863.  
  864.  
  865.          will start the pan effect without totally muting
  866.          the opposite channel.
  867.  
  868.        phaser gain-in gain-out delay decay speed < -s | -t >
  869.          Add a phaser to a  sound  sample.   Each  triple
  870.          delay/decay/speed  gives  the delay in millisec¡
  871.          onds and the decay (relative to gain-in) with    a
  872.          modulation  speed  in    Hz.   The  modulation  is
  873.          either sinodial (-s) or  triangular  (-t).   The
  874.          decay should be less than 0.5 to avoid feedback.
  875.          Gain-out is the volume of the output.
  876.  
  877.        pick [ -1 | -2 | -3 | -4 | -l | -r ]
  878.          Select the left or right  channel  of    a  stereo
  879.          sample,  or  one  of  four channels in a quadro¡
  880.          phonic sample. The -l and -r  options    represent
  881.          either      the  left  or     right    channel.   It  is
  882.          required that you use    the  -c     1  command  line
  883.          option in order to force the output file to con¡
  884.          tain only 1 channel.
  885.  
  886.        pitch shift [ width interpole fade ]
  887.          Change the pitch of file without  affecting  its
  888.          duration by cross-fading shifted samples.  shift
  889.          is given in cents. Use a positive value to shift
  890.          to  treble,  negative    value  to  shift to bass.
  891.          Default shift is 0.  width of window is  in  ms.
  892.          Default  width is 20ms. Try 30ms to lower pitch,
  893.          and 10ms to raise pitch.  interpole option,  can
  894.          be "cubic" or "linear". Default is "cubic".  The
  895.          fade option, can be "cos",  "hamming",     "linear"
  896.          or "trapezoid".  Default is "cos".
  897.  
  898.        polyphase [ -w < nut / ham > ]
  899.  
  900.          [  -width <  long  / short  / # > ]
  901.  
  902.          [ -cutoff #  ]
  903.          Translate input sampling rate to output sampling
  904.          rate via polyphase interpolation,  a  DSP  algo¡
  905.          rithm.      This    method    is  slow and uses lots of
  906.          RAM, but gives much better results than rate.
  907.  
  908.          -w < nut / ham > : select either a  Nuttal  (~90
  909.          dB  stopband)    or Hamming (~43 dB stopband) win¡
  910.          dow.  Default is nut.
  911.  
  912.          -width long / short / # : specify the    (approxi¡
  913.          mate)    width  of  the filter.    long is 1024 sam¡
  914.          ples; short is 128 samples.   Alternatively,  an
  915.          exact number can be used.  Default is long.  The
  916.          short option is not recommended, as it     produces
  917.          poor quality results.
  918.  
  919.  
  920.  
  921.  
  922.               July 24, 2000                   14
  923.  
  924.  
  925.  
  926.  
  927.  
  928. SoX(1)                               SoX(1)
  929.  
  930.  
  931.          -cutoff  # : specify the filter cutoff frequency
  932.          in terms of  fraction    of  frequency  bandwidth,
  933.          also  know as the Nyquist frequency.  Please see
  934.          the resample effect for further  information  on
  935.          Nyquist  frequency.  If upsampling, then this is
  936.          the fraction of the original signal that  should
  937.          go  through.  If downsampling, this is the frac¡
  938.          tion of  the  signal  left  after  downsampling.
  939.          Default is 0.95.  Remember that this is a float.
  940.  
  941.  
  942.        rate     Translate input sampling rate to output sampling
  943.          rate  via linear interpolation to the Least Com¡
  944.          mon Multiple of the two sampling rates.  This is
  945.          the default effect if the two files have differ¡
  946.          ent sampling rates and the preview  options  was
  947.          specified.  This is fast but noisy: the spectrum
  948.          of the original sound will  be     shifted  upwards
  949.          and  duplicated faintly when up-translating by a
  950.          multiple.
  951.  
  952.          Lerp-ing is acceptable     for  cheap  8-bit  sound
  953.          hardware,  but     for  CD-quality sound you should
  954.          instead use either resample  or  polyphase.   If
  955.          you are wondering which rate changing effects to
  956.          use, you will want to read a  detailed     analysis
  957.          of  all  of  them  at    http://eakaw2.et.tu-dres¡
  958.          den.de/~wilde/resample/resample.html
  959.  
  960.        resample [ -qs | -q | -ql ] [ rolloff [ beta ] ]
  961.          Translate input sampling rate to output sampling
  962.          rate  via  simulated  analog  filtration.   This
  963.          method is slower than rate, but gives much  bet¡
  964.          ter results.
  965.  
  966.          By default, linear interpolation is used, with a
  967.          window width about 45 samples at  the    lower  of
  968.          the  two  rate.  This gives an accuracy of about
  969.          16 bits, but insufficient stopband rejection  in
  970.          the  case  that you want to have rolloff greater
  971.          than about 0.80 of the Nyquist frequency.
  972.  
  973.          The -q* options will change the  default  values
  974.          for  rolloff  and  beta as well as use quadratic
  975.          interpolation of filter coefficients,    resulting
  976.          in about 24 bits precision.  The -qs, -q, or -ql
  977.          options specify increased accuracy at    the  cost
  978.          of  lower  execution  speed.    It is optional to
  979.          specify rolloff and beta parameters  when  using
  980.          the -q* options.
  981.  
  982.          Following  is a table of the reasonable defaults
  983.          which are built-in to sox:
  984.  
  985.  
  986.  
  987.  
  988.               July 24, 2000                   15
  989.  
  990.  
  991.  
  992.  
  993.  
  994. SoX(1)                               SoX(1)
  995.  
  996.  
  997.             Option  Window rolloff beta interpolation
  998.             ------  ------ ------- ---- -------------
  999.             (none)    45    0.80    16       linear
  1000.               -qs     45    0.80    16      quadratic
  1001.               -q      75    0.875   16      quadratic
  1002.               -ql    149    0.94    16      quadratic
  1003.             ------  ------ ------- ---- -------------
  1004.  
  1005.          -qs, -q, or -ql use window lengths of 45, 75, or
  1006.          149  samples, respectively, at the lower sample-
  1007.          rate of the two files.     This means progressively
  1008.          sharper  stop-band  rejection, at proportionally
  1009.          slower execution times.
  1010.  
  1011.          rolloff refers to the cut-off frequency  of  the
  1012.          low  pass  filter  and     is given in terms of the
  1013.          Nyquist frequency for    the  lower  sample  rate.
  1014.          rolloff  therefore  should  be something between
  1015.          0.0 and 1.0, in practice 0.8-0.95.  The defaults
  1016.          are indicated above.
  1017.  
  1018.          The Nyquist frequency is equal to (sample rate /
  1019.          2).  Logically, this is  because  the    A/D  con¡
  1020.          verter     needs    at  least  2  samples to detect 1
  1021.          cycle at  the    Nyquist     frequency.   Frequencies
  1022.          higher     then the Nyquist will actually appear as
  1023.          lower frequencies to the A/D  converter  and  is
  1024.          called aliasing.  Normally, A/D converts run the
  1025.          signal through a highpass filter first to  avoid
  1026.          these problems.
  1027.  
  1028.          Similar  problems  will  happen in software when
  1029.          reducing the sample rate of an audio file  (fre¡
  1030.          quencies  above the new Nyquist frequency can be
  1031.          aliased to  lower  frequencies).   Therefore,    a
  1032.          good  resample     effect will remove all frequency
  1033.          information above the new Nyquist frequency.
  1034.  
  1035.          The rolloff refers to how close to  the  Nyquist
  1036.          frequency this cutoff is, with closer being bet¡
  1037.          ter.  When increasing    the  sample  rate  of  an
  1038.          audio file you would not expect to have any fre¡
  1039.          quencies  exist  that    are  past  the     original
  1040.          Nyquist  frequency.  Because of resampling prop¡
  1041.          erties, it is common to have alaising data  cre¡
  1042.          ated  that  is     above the old Nyquist frequency.
  1043.          In that case the rolloff refers to how close  to
  1044.          the original Nyquist frequency to use a highpass
  1045.          filter to remove this false  data,  with  closer
  1046.          also being better.
  1047.  
  1048.          The beta parameter determines the type of filter
  1049.          window used.  Any value greater than 2.0 is  the
  1050.          beta for a Kaiser window.  Beta <= 2.0 selects a
  1051.  
  1052.  
  1053.  
  1054.               July 24, 2000                   16
  1055.  
  1056.  
  1057.  
  1058.  
  1059.  
  1060. SoX(1)                               SoX(1)
  1061.  
  1062.  
  1063.          Nuttall window.  If unspecified, the default  is
  1064.          a Kaiser window with beta 16.
  1065.  
  1066.          In the case of Kaiser window (beta > 2.0), lower
  1067.          betas produce a somewhat faster transition  from
  1068.          passband  to stopband, at the cost of noticeable
  1069.          artifacts.  A beta of 16 is  the  default,  beta
  1070.          less  than 10 is not recommended.  If you want a
  1071.          sharper cutoff, don't    use  low  beta's,  use    a
  1072.          longer     sample     window.   A  Nuttall  window  is
  1073.          selected by specifying any 'beta' <= 2, and  the
  1074.          Nuttall  window has somewhat steeper cutoff than
  1075.          the default Kaiser window.   You  will     probably
  1076.          not  need  to    use  the  beta    parameter at all,
  1077.          unless you are just curious about comparing  the
  1078.          effects of Nuttall vs. Kaiser windows.
  1079.  
  1080.          This is the default effect if the two files have
  1081.          different sampling  rates.   Default  parameters
  1082.          are, as indicated above, Kaiser window of length
  1083.          45, rolloff 0.80, beta 16, linear interpolation.
  1084.  
  1085.          NOTE:    -qs  is     only  slightly     slower, but more
  1086.          accurate for 16-bit or higher precision.
  1087.  
  1088.          NOTE: In many cases of up-sampling, no     interpo¡
  1089.          lation     is  needed, as exact filter coefficients
  1090.          can be computed in a reasonable amount of space.
  1091.          To be precise, this is done when
  1092.  
  1093.                 input_rate < output_rate
  1094.                        &&
  1095.            output_rate/gcd(input_rate,output_rate) <= 511
  1096.  
  1097.        reverb gain-out delay [ delay ... ]
  1098.          Add reverberation to a sound sample.  Each delay
  1099.          is  given  in    milliseconds  and its feedback is
  1100.          depending on the  reverb-time    in  milliseconds.
  1101.          Each  delay  should  be  in the range of half to
  1102.          quarter of reverb-time to get a realistic rever¡
  1103.          beration.  Gain-out is the volume of the output.
  1104.  
  1105.        reverse     Reverse the sound sample  completely.     Included
  1106.          for finding Satanic subliminals.
  1107.  
  1108.        speed factor
  1109.          Speed    up  or down the sound, as a magnetic tape
  1110.          with a speed control.    It affects both pitch and
  1111.          time.    A  factor  of 1.0 means no change, and is
  1112.          the  default.     2.0  doubles  speed,  thus  time
  1113.          length     is cut by a half and pitch is one octave
  1114.          higher.  0.5 halves speed thus time length  dou¡
  1115.          bles and pitch is one octave lower.
  1116.  
  1117.  
  1118.  
  1119.  
  1120.               July 24, 2000                   17
  1121.  
  1122.  
  1123.  
  1124.  
  1125.  
  1126. SoX(1)                               SoX(1)
  1127.  
  1128.  
  1129.        split     Turn a mono sample into a stereo sample by copy¡
  1130.          ing the input channel    to  the     left  and  right
  1131.          channels.
  1132.  
  1133.        stat [ -s n ] [-rms ] [ -v ] [ -d ]
  1134.          Do  a    statistical  check on the input file, and
  1135.          print results on the standard error file.  Audio
  1136.          data  is  passed unmodified from input to output
  1137.          file unless used along with the -e option.
  1138.  
  1139.          The "Volume Adjustment:" field in the statistics
  1140.          gives    you  the  argument to the -v number which
  1141.          will make the sample as loud as possible without
  1142.          clipping.
  1143.  
  1144.          The option -v will print out the "Volume Adjust¡
  1145.          ment:" field's     value    only  and  return.   This
  1146.          could    be  of use in scripts to auto convert the
  1147.          volume.
  1148.  
  1149.          The -s n option is used to scale the input  data
  1150.          by  a    given  factor.    The default value of n is
  1151.          the  max  value  of  a     signed      long     variable
  1152.          (0x7fffffff).    Internal effects always work with
  1153.          signed long PCM data and  so  the  value  should
  1154.          relate to this fact.
  1155.  
  1156.          The  -rms option will convert all output average
  1157.          values to root mean square format.
  1158.  
  1159.          There is also an optional parameter -d that will
  1160.          print    out a hex dump of the sound file from the
  1161.          internal buffer that is  in  32-bit  signed  PCM
  1162.          data.     This  is  mainly only of use in tracking
  1163.          down endian problems that creep  in  to  sox  on
  1164.          cross-platform versions.
  1165.  
  1166.  
  1167.        stretch factor [window fade shift fading]
  1168.          Time  stretch    file  by  a  given factor. Change
  1169.          duration without affecting the pitch.    factor of
  1170.          stretching:  >1.0  lengthen,  <1.0 shorten dura¡
  1171.          tion.    window size is in ms.  Default    is  20ms.
  1172.          The  fade option, can be "lin".  shift ratio, in
  1173.          [0.0 1.0]. Default depends  on     stretch  factor.
  1174.          1.0  to  shorten,  0.8     to lengthen.  The fading
  1175.          ratio, in [0.0 0.5].  The  amount  of    a  fade's
  1176.          default depends on factor and shift.
  1177.  
  1178.        swap [ 1 2 | 1 2 3 4 ]
  1179.          Swap  channels     in  multi-channel  sound  files.
  1180.          Optionally, you may specify  the  channel  order
  1181.          you  would like the output in.     This defaults to
  1182.          output channel 2 and then 1 for stereo and 2, 1,
  1183.  
  1184.  
  1185.  
  1186.               July 24, 2000                   18
  1187.  
  1188.  
  1189.  
  1190.  
  1191.  
  1192. SoX(1)                               SoX(1)
  1193.  
  1194.  
  1195.          4,  3 for quad-channels.  An interesting feature
  1196.          is that you may duplicate  a  given  channel  by
  1197.          overwriting  another.    This is done by repeating
  1198.          an output channel  on    the  command  line.   For
  1199.          example,  swap 2 2 will overwrite channel 1 with
  1200.          channel 2's data; creating a  stereo  file  with
  1201.          both channels containing the same audio data.
  1202.  
  1203.        trim start [ length ]
  1204.          Trim  can  trim off unwanted audio data from the
  1205.          beginning and end of the audio file.  Audio sam¡
  1206.          ples are not sent to the output stream until the
  1207.          start location is reached.  start is a     floating
  1208.          point number that tells the number of seconds to
  1209.          wait before starting.    If you    know  the  sample
  1210.          number     you would like to start at then the sec¡
  1211.          onds can be obtained by  multiply  (sample  #    *
  1212.          sample rate).
  1213.          The  optional    length parameter tells the number
  1214.          of samples to output after the start sample  and
  1215.          is  used  to trim off the back side of the audio
  1216.          data.    Using a value of 0 for the start  parame¡
  1217.          ter  will allow trimming off the back side only.
  1218.  
  1219.        vibro speed  [ depth ]
  1220.          Add the world-famous  Fender  Vibro-Champ  sound
  1221.          effect to a sound sample by using a sine wave as
  1222.          the volume knob.  Speed gives the Hertz value of
  1223.          the  wave.   This must be under 30.  Depth gives
  1224.          the amount the volume is cut into  by    the  sine
  1225.          wave,    ranging 0.0 to 1.0 and defaulting to 0.5.
  1226.  
  1227.        vol gain [ type [ limitergain ] ]
  1228.          The vol effect is much     like  the  command  line
  1229.          option     -v.   It allows you to adjust the volume
  1230.          of an input file and allows you to  specify  the
  1231.          adjustment  in     relation to amplitude, power, or
  1232.          dB.  If type is not specified then  it     defaults
  1233.          to amplitude.
  1234.          When  type  is amplitude then a linear change of
  1235.          the amplitude is performed based  on  the  gain.
  1236.          Therefore,  a    value of 1.0 will keep the volume
  1237.          the same, 0.0 to < 1.0 will cause the volume  to
  1238.          decrease and values of > 1.0 will cause the vol¡
  1239.          ume to increase.  Beware of clipping audio  data
  1240.          when  the  gain is greater then 1.0.  A negative
  1241.          value performs the same  adjustment  while  also
  1242.          changing the phase.
  1243.          When  type  is     power    then  a value of 1.0 also
  1244.          means no change in volume.
  1245.          When type is dB the amplitude is  changed  loga¡
  1246.          rithmically.    0.0  is constant while +6 doubles
  1247.          the amplitude.
  1248.          An optional limitergain value can  be    specified
  1249.  
  1250.  
  1251.  
  1252.               July 24, 2000                   19
  1253.  
  1254.  
  1255.  
  1256.  
  1257.  
  1258. SoX(1)                               SoX(1)
  1259.  
  1260.  
  1261.          and  should  be  a  value much less then 1.0 (ie
  1262.          0.05 or 0.02) and is used only on peaks to  pre¡
  1263.          vent  clipping.   Not    specifying this parameter
  1264.          will cause no limiter to be  used.   In  verbose
  1265.          mode, this effect will display the percentage of
  1266.          audio data that needed to be limited.
  1267.  
  1268. BUGS
  1269.        The syntax is horrific.    Thats the breaks when  trying  to
  1270.        handle all things from the command line.
  1271.  
  1272.        Please  report  any  bugs  found in this version of sox to
  1273.        Chris Bagwell (cbagwell@sprynet.com)
  1274.  
  1275. FILES
  1276. SEE ALSO
  1277.        play(1), rec(1), soxexam(1)
  1278.  
  1279. NOTICES
  1280.        The version of Sox that accompanies this     manual     page  is
  1281.        support    by  Chris Bagwell (cbagwell@sprynet.com).  Please
  1282.        refer any questions regarding it to this address.  You may
  1283.        obtain    the   latest   version     at   the  the    web  site
  1284.        http://home.sprynet.com/~cbagwell/sox.html
  1285.  
  1286.  
  1287.  
  1288.  
  1289.  
  1290.  
  1291.  
  1292.  
  1293.  
  1294.  
  1295.  
  1296.  
  1297.  
  1298.  
  1299.  
  1300.  
  1301.  
  1302.  
  1303.  
  1304.  
  1305.  
  1306.  
  1307.  
  1308.  
  1309.  
  1310.  
  1311.  
  1312.  
  1313.  
  1314.  
  1315.  
  1316.  
  1317.  
  1318.               July 24, 2000                   20
  1319.  
  1320.  
  1321.