| 1 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" |
| 2 | "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
| 3 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> |
| 4 | <head> |
| 5 | <meta name="generator" content="PSPad editor, www.pspad.com" /> |
| 6 | <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> |
| 7 | <link rel="stylesheet" type="text/css" href="styles/lame.css" /> |
| 8 | <title>Usage of the commandline encoder</title> |
| 9 | </head> |
| 10 | <body> |
| 11 | <div id="menu"> |
| 12 | <ul> |
| 13 | <li><a href="index.html">Index page</a></li> |
| 14 | <li><a href="about.html">About LAME</a></li> |
| 15 | <li><a href="introduction.html">Intro to encoding</a></li> |
| 16 | <li><a style="border: 0" href="usage.html">Usage of LAME</a> |
| 17 | <div id="submenu"> |
| 18 | <ul> |
| 19 | <li><a href="usage.html">Common switches</a></li> |
| 20 | <li><a style="border: 0" href="detailed.html">Detailed Settings</a></li> |
| 21 | </ul> |
| 22 | </div> |
| 23 | </li> |
| 24 | <li><a href="history.html">Version history</a></li> |
| 25 | <li><a href="contributors.html">Coders of LAME</a></li> |
| 26 | <li><a href="contact.html">Contact LAME</a></li> |
| 27 | <li><a style="border: 0" href="links.html">LAME links</a></li> |
| 28 | </ul> |
| 29 | </div> |
| 30 | <div id="container"> |
| 31 | <div id="content"> |
| 32 | <div align="center"> |
| 33 | <img src="images/logo.gif" width="358" height="231" alt="LAME Official Logo" /> |
| 34 | <h2 class="hilight">Common and recommended switches</h2> |
| 35 | </div> |
| 36 | <h3>Common settings</h3> |
| 37 | <pre> |
| 38 | % lame <span class="hilight">[options]</span> inputfile [outputfile] |
| 39 | </pre> |
| 40 | <ul> |
| 41 | <li> |
| 42 | <strong>Constant Bitrate</strong>: <span class="hilight">-b number</span> or |
| 43 | <span class="hilight">--preset cbr number</span> Valid values |
| 44 | for the -b settings depend on the sampling rate<a href="#note1"><sup>1</sup></a>. |
| 45 | <pre>lame -b 128 sample.wav sample.mp3</pre> |
| 46 | </li> |
| 47 | <li> |
| 48 | <strong>Variable Bitrate (<a href="abr.html">ABR</a> mode)</strong>: |
| 49 | <span class="hilight">--abr number</span> or <span class="hilight">--preset number</span> |
| 50 | Valid values for the --abr setting range from 8 to 320. |
| 51 | <pre>lame --abr 128 sample.wav sample.mp3</pre> |
| 52 | </li> |
| 53 | <li> |
| 54 | <strong>Variable Bitrate (<a href="vbr.html">VBR</a> mode)</strong>: |
| 55 | <span class="hilight">-V number</span> Valid values |
| 56 | are from 0 to 9, with decimal values possible, where 0 is the highest quality |
| 57 | while 9.999 is the lowest one. |
| 58 | <pre>lame -V2 sample.wav sample.mp3</pre> |
| 59 | </li> |
| 60 | </ul> |
| 61 | <h3>Hydrogenaudio recommended settings</h3> |
| 62 | <ul> |
| 63 | <strong>Very high quality</strong>, HiFi, home, or quiet listening, with best file size<a href="#note2"></a> : |
| 64 | <span class="hilight">-V0</span> (avg. 245 kbps) or <span class="hilight">-V1</span> |
| 65 | (avg. 225 kbps) or <span class="hilight">-V2</span> (avg. 190 kbps) or <span class="hilight">-V3</span> (avg. 175 kbps). |
| 66 | <p>VBR settings will normally produce transparent results. |
| 67 | Audible differences between these presets may exist, but are rare. |
| 68 | </p> |
| 69 | </li> |
| 70 | <li> |
| 71 | <strong>Very high quality</strong>, HiFi, home, or quiet listening, with maximum file size<a href="#note2"><sup>2</sup></a> : |
| 72 | <span class="hilight">-b 320</span> |
| 73 | <p>This CBR mode will maximize the MP3's bitrate and overall file |
| 74 | size. The extra space may allow for some parts of the audio to be |
| 75 | compressed with fewer sacrifices, but to date, no one has produced |
| 76 | ABX test results demonstrating that perceived quality is ever better |
| 77 | than the highest VBR profiles described above. |
| 78 | </p> |
| 79 | </li> |
| 80 | <li> |
| 81 | <strong>Portable</strong>, listening in noisy conditions, lower bitrate, smaller file size: |
| 82 | <span class="hilight">-V4</span> (avg. 160 kbps) or <span class="hilight">-V5</span> |
| 83 | (avg. 130 kbps) or <span class="hilight"> -V6</span> (avg. 115 kbps) |
| 84 | <p> |
| 85 | -V6 produces an "acceptable" quality, while -V4 should be close to perceptual transparency. |
| 86 | </p> |
| 87 | </li> |
| 88 | <li> |
| 89 | <strong>Very low bitrate, small sizes</strong>, eg. for voice, radio, mono encoding : |
| 90 | <span class="hilight">--abr 80</span> (stereo) or <span class="hilight">--abr 56 -m m</span> (mono) |
| 91 | <p> |
| 92 | For very low bitrates, up to 100kbps, ABR is most often the best solution. |
| 93 | --preset voice is only available in the command line front-end, and |
| 94 | is there for compatibility. It is currently mapped to --abr 56 -mm, |
| 95 | so that means that the recommendation would be to encode in mono, |
| 96 | and use ABR. |
| 97 | </p> |
| 98 | </li> |
| 99 | </ul> |
| 100 | <div id="notes"> |
| 101 | <ol> |
| 102 | <li> |
| 103 | <a name="note1"></a> |
| 104 | <table cellpadding="5"> |
| 105 | <tr> |
| 106 | <th>Codec</th> |
| 107 | <th>sample frequencies (kHz)</th> |
| 108 | <th>bitrates (kbps)</th> |
| 109 | </tr> |
| 110 | <tr> |
| 111 | <td>MPEG-1 layer III </td> |
| 112 | <td>32, 44.1, 48</td> |
| 113 | <td>32 40 48 56 64 80 96 112 128 160 192 224 256 320</td> |
| 114 | </tr> |
| 115 | <tr> |
| 116 | <td>MPEG-2 layer III</td> |
| 117 | <td> 16, 22.05, 24</td> |
| 118 | <td> 8 16 24 32 40 48 56 64 80 96 112 128 144 160</td> |
| 119 | </tr> |
| 120 | <tr> |
| 121 | <td style="border-bottom:0px;">MPEG-2.5 layer III</td> |
| 122 | <td style="border-bottom:0px;"> 8, 11.025, 12</td> |
| 123 | <td style="border-bottom:0px;">8 16 24 32 40 48 56 64</td> |
| 124 | </tr> |
| 125 | </table> |
| 126 | </li> |
| 127 | <li><a name="note2"></a>Lossy codecs, like MP3, should not be used for archiving, |
| 128 | since the nature of lossy encoding always changes the original sound, even if it |
| 129 | sounds transparent. Use lossless codecs for this purpose. |
| 130 | </li> |
| 131 | </ol> |
| 132 | </div> |
| 133 | </div> |
| 134 | <div id="footer"> |
| 135 | |
| 136 | <a href="http://sourceforge.net/projects/lame"><img src="images/sflogo.gif" |
| 137 | alt="Get LAME (Lame Aint an MP3 Encoder) at SourceForge.net. Fast, secure and Free Open Source software downloads" |
| 138 | border="0" height="30" width="120" /></a> |
| 139 | |
| 140 | <a href="http://validator.w3.org/#validate_by_upload"><img src="images/valid-xhtml10.png" |
| 141 | alt="Valid XHTML 1.0 Transitional" border="0" height="31" width="88" /></a> |
| 142 | |
| 143 | <a href="http://jigsaw.w3.org/css-validator/"><img src="images/valid-css.png" |
| 144 | alt="Valid CSS!" border="0" height="31" width="88" /></a> |
| 145 | |
| 146 | <p>HTML markup and design by <a |
| 147 | href="http://www.rarewares.org" target="_blank">Roberto Amorim</a> and <a |
| 148 | href="http://www.maresweb.de" target="_blank">Sebastian Mares</a>. Logo by <a |
| 149 | href="http://www.brightercreative.co.uk">Sam Fisher</a>.</p> |
| 150 | |
| 151 | </div> |
| 152 | </div> |
| 153 | |
| 154 | </body> |
| 155 | </html> |