~ubuntu-branches/ubuntu/lucid/mpg123/lucid

« back to all changes in this revision

Viewing changes to README

Tags: upstream-0.60
ImportĀ upstreamĀ versionĀ 0.60

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
**********************************************************************
2
 
* MPEG 1.0/2.0 _AUDIO_ PLAYER, V0.59n                                * 
3
 
*                                                                    *
4
 
* (full?) MPEG 1.0/2.0, Layer 1,2 and 3 support                      *
5
 
* Layer-3 realtime only with a 'fast' machine                        *
6
 
* Since April 97, 128kbit j-stereo should work on a 486DX4-120.      *
7
 
* With 2:1 down-sampling or using the downmix-mode even a 486DX2-66  *
8
 
* should play such a stream in realtime!                             *
9
 
*                                                                    *
10
 
* I still claim to have the fastest MPEG Audio Player for UNIX ;)    *
11
 
**********************************************************************
12
 
 
13
 
Please read first the important information in the COPYING file.
14
 
 
15
 
written/modfied by:
16
 
   Michael Hipp (email: hippm@informatik.uni-tuebingen.de)
17
 
   Oliver Fromme <oliver.fromme@heim3.tu-clausthal.de>
18
 
    (several enhancements, man pages, Makefile, FreeBSD port, License, etc.)
19
 
 
20
 
Uses code (or at least ideas) from:
21
 
  MPEG Software Simulation Group: reference decoder package
22
 
  Tobias Bading: idea for DCT64 in subband synthesis from maplay package
23
 
  Jeff Tsay and Mikko Tommila: MDCT36 from maplay package
24
 
  Philipp Knirsch <phil@mpik-tueb.mpg.de>: DCT36/manual unroll idea
25
 
  Thomas Woerner <..> (SGI Audio)
26
 
  Damien Clermonte <..> (HP-UX audio fixes)
27
 
  Niclas Lindstrom <nil@wineasy.se>: OS2 port
28
 
  Stefan Bieschewski <stb@acm.org>: Pentium optimizations, decode_i586.s
29
 
  Martin Denn <mdenn@unix-ag.uni-kl.de>: NAS port
30
 
  Niklas Beisert <nbeisert@physik.tu-muenchen.de> MPEG 2.5 tables
31
 
  <mycroft@NetBSD.ORG> and <augustss@cs.chalmers.se>: NetBSD
32
 
  Kevin Brintnall <kbrint@visi.com> BSD patch
33
 
  Tony Million: win32 port
34
 
  Steven Tiger Lang: advanced shuffle
35
 
  Henrik P Johnson: HTTP auth patch
36
 
  Eric B. Mitchell: esd port
37
 
  Ryan R. Prosser <prosser@geocities.com> esd port for Solaris
38
 
  Daniel Kobras <daniel.kobras@student.uni-tuebingen.de>: lot of (DK)-bugfixes
39
 
  and more ....
40
 
 
41
 
current distribution site for new test versions is:
42
 
  http://www-ti.informatik.uni-tuebingen.de/~hippm/mpg123.html
43
 
 
44
 
here's Oliver Fromme's mpg123 page:
45
 
  http://mpg.123.org/
46
 
  (includes information about the mpg123 mailing list)
47
 
 
48
 
and you can get the latest release from here:
49
 
  ftp.tu-clausthal.de:/pub/unix/audio/mpg123
50
 
  http://ftp.tu-clausthal.de/pub/unix/audio/mpg123
51
 
 
52
 
------------------------------------------------------------------------
53
 
 
54
 
This version plays a layer3,112Kbit/s,J-Stereo stream on my AMD 5x86/133Mhz
55
 
with about 66% CPU load. (on the console, NO X11)
56
 
If your machine isn't fast enough you may try the downsampling
57
 
feature (--2to1 and --4to1 options) 
58
 
Playing in '--singlemix' (stero reduced to mono) also saves some
59
 
CPU cycles, though the whole code is optimized for 'full' stereo playing.
60
 
 
61
 
'Benchmarks': (+/- 2%)
62
 
----------------------
63
 
(AMD 486/133MHZ,ASUS SP3G,256KB cache,DIRTY-TAG installed,(BusLogic SCSI))
64
 
(Layer3, 112Kbit/s, Joint-Stereo stream (partially MS stereo, no I-stereo))
65
 
(Compiled with: -DI386_ASSEM -DREAL_IS_FLOAT -DLINUX -Wall -O2 -m486
66
 
   -fomit-frame-pointer -funroll-all-loops -finline-functions -ffast-math)
67
 
 
68
 
  full quality:     (stero)     66% (-> may work on 486DX4-100)
69
 
                    (singlemix) 38% (-> should work on 486DX2-66)
70
 
  2:1 downsampling: (stereo)    48%
71
 
                    (singlemix) 30% (-> should work on 486DX-50)
72
 
 
73
 
---------------------------------------------------------------------
74
 
Description:
75
 
 
76
 
This isn't a new player. It's a fully rewritten version originally based 
77
 
on the mpegaudio (FHG-version) package. The DCT algorithm in the
78
 
synthesis filter is a rewritten version of the DCT first seen in the maplay
79
 
package, which was written by Tobias Bading (bading@cs.tu-berlin.de). The 
80
 
rewrite was neccassary, because the GPL may not allow this copyright mix.
81
 
The mpegaudio package was written by various people from the MPEG/audio
82
 
software simulation group. The maplay is under GPL .. You can find the
83
 
original source code and the mpegaudio package on: ftp.tnt.uni-hannover.de.
84
 
 
85
 
Especially layer3.c common.c and mpg123.h is based on the dist10 package.
86
 
The code is fullly rewritten but I'm using sometimes the
87
 
same variable names or similar function names as in the
88
 
original package.
89
 
 
90
 
In the current layer3.c I'm using a DCT36 first seen in Jeff Tsay's 
91
 
(ctsay@pasteur.eecs.berkeley.edu) maplay 1.2+ package. His code is
92
 
under GPL .. I also tried the enhancement from Mikko Tommila. His
93
 
code is also in layer3.c (but it's disabled at the moment, because
94
 
it was slightly slower than the unrolled 9 point DCT (at least on 
95
 
_my_ system)). Theoretically it should be faster. You may try it on
96
 
your system.
97
 
 
98
 
The output can converted to different audio formats and
99
 
rates. Currently, only (very simple) audiosupport for
100
 
the most common computer systems. It's possible
101
 
to build a 'generic' version which needs an external
102
 
audio player for playing.
103
 
 
104
 
I have tested the program with a lot of teststreams, but it's very 
105
 
likely, that there are still a few bugs.
106
 
 
107
 
Playing MP3s coming with MIMEType "audio/x-mpegurl" 
108
 
---------------------------------------------------
109
 
For netscape navigator: 
110
 
Go: Preferencs->Navigator->Applications
111
 
 Click 'NEW' Button and fill in the form:
112
 
  Description: MP3 Playlist
113
 
  MIMEType:    audio/x-mpegurl
114
 
  suffix:      m3u
115
 
 Click the 'Application' button below and add a
116
 
  mpg123 -@ %s
117
 
 or maybe better
118
 
  xterm -e mpg123 -@ %s
119
 
 in the application field. Press OK. That's all.
120
 
 
121
 
 
122
 
NAS notes: (from Martin Denn)
123
 
-----------------------------
124
 
you may wanna play with the following defines: (from audio.c)
125
 
  NAS_SOUND_PORT_DURATION 
126
 
  NAS_SOUND_LOW_WATER_MARK
127
 
Change them to optimize the player for your environment. For slow
128
 
networks a proven config is:
129
 
#define NAS_SOUND_PORT_DURATION 10 /* seconds */
130
 
#define NAS_SOUND_LOW_WATER_MARK 75 /* percent */
131
 
 
132
 
Pentium optimization notes:
133
 
---------------------------
134
 
The ASM optimaztions are especially for Intel Pentium FPUs.
135
 
On other processorts the egcs compiler optimiazation
136
 
may do a better job.
137
 
 
138
 
3DNow notes:
139
 
------------
140
 
You need a new 'as'. ie. the 'as' from binutils-2.9.1.0.19a.
141
 
If you donļæ½t have a suitable ļæ½asļæ½, you may wanna try to _copy_ the
142
 
files dct64_3dnow.o and decode_3dnow.o from the precompiled/ 
143
 
directory to the base mpg123 source path and try to compile
144
 
the source.
145
 
A funny side-effect of the 3dnow optimizations is, that now the
146
 
-2 and -4 downsampling is a little slower than full quality, because
147
 
the 3dnow optimization is only enabled for full quality decoding.
148
 
3dnow only works with -DREAL_IS_FLOAT. 
149
 
 
150
 
 
151
 
have fun,
152
 
           Mike
153
 
 
154
 
----------------------------------------------------------------------------
155
 
 
156
 
Just for info:
157
 
    I'm also working (but not at the moment) on a DSP port for this package. 
158
 
    A first testversion of the _LAYER-2_ part is finished and seems
159
 
    to work in realtime with my 20MHZ ADSP-2115 
160
 
 
161
 
----------------------------------------------------------------------------
162
 
 
163
 
Copyrights (c) 1995,1996,1997 of all changes/modifications and
164
 
of the new code by Michael Hipp. All rights reserved.
165
 
Copyrights (c) 1997 of several enhancements by Oliver Fromme.
166
 
See the packages 'maplay 1.2(+)' and 'mpegaudio' for their copy-policies.
167
 
Copyrights (c) 1997 of the OS2 specific parts by Niclas Lindstrom
168
 
 
169
 
known bugs:
170
 
-----------
171
 
  layer 3 i-stereo not heavily tested
172
 
   btw: I'm looking for i-stereo teststreams .. maybe you could send me a few
173
 
  Layer 1 not heavily tested
174
 
  no CRC checking ..
175
 
  no 'free format streams'
176
 
  no clean audio interface
177
 
  MPEG 2.0, Layer1 and Layer2 not tested (and probably will not work)
178
 
  MPEG 2.0, Layer3 not heavily tested .. may has bugs.
179
 
 
180
 
related information:
181
 
--------------------
182
 
  If you need an mp3 frame re(assembler) and stream debug tool you should
183
 
  have a look at the mp3asm program on Olli's mpg123 page.(http://mpg.123.org)
184
 
 
185
 
some interessting patent information:
186
 
-------------------------------------
187
 
  http://www.iis.fhg.de/amm/legal/
188
 
 
189
 
 
190
 
******************************************************************************
191
 
*
192
 
* This is software with ABSOLUTELY NO WARRANTY.
193
 
* Use it at your OWN RISK. It's possible to damage e.g. hardware or your hearing
194
 
* due to a bug or for other reasons. 
195
 
*
196
 
* I do not warrant that the program is free of infringement of any third-party
197
 
* patents.
198
 
*
199
 
******************************************************************************
200
 
 
 
1
* * * * * * * * * * * * * * * * * * * * * * * * * * * *
 
2
*   mpg123 - MPEG 1.0/2.0/2.5 audio player            *
 
3
*   README for version 0.60, dated at 22.08.2006      *
 
4
*                                                     *
 
5
* ...still the fastest MPEG audio player for UNIX ;)  *
 
6
* * * * * * * * * * * * * * * * * * * * * * * * * * * *
 
7
(This file has very long lines - die-hard terminal nostalgists can be satisfied by `fmt -s -w 75 < README | less`. I think it's better to let the reader's preference rule than to preformat the stuff to some arbitrary width.)
 
8
 
 
9
 
 
10
0. Stuff
 
11
 
 
12
For building/installation info see INSTALL.
 
13
 
 
14
The mpg123 project was started by Michel Hipp and is now being maintained by Thomas Orgis and Nicholas J. Humfrey, who intitated the Sourceforge project.
 
15
The source code contains contributions from quite a few people - see AUTHORS for more info.
 
16
It is Open Source software licensed mostly under the LGPL with some parts restricted to GPL. See COPYING for details.
 
17
As for every mp3 player, some of mpg123's functionality may be covered by patents in a country where these are valid. See PATENTS for details.
 
18
 
 
19
Project's official website URL is
 
20
 
 
21
        http://mpg123.org
 
22
(or http://mpg123.orgis.org as fallback address if there is a problem with the DNS forwarding)
 
23
 
 
24
for the traditional hope page and
 
25
 
 
26
        http://sourceforge.net/projects/mpg123
 
27
 
 
28
for sourceforge.net based services like download mirrors, mailing lists and bug/feature trackers.
 
29
Please use the sourceforge download mirrors when possible to minimize load on the mpg123.org server.
 
30
 
 
31
 
 
32
1. Introduction
 
33
 
 
34
This is a console based decoder/player for mono/stereo mpeg audio files, probably more familiar as MP3 or MP2 files.
 
35
It's focus is speed. We still need some low-end benchmarks for the current version, but playback should be possible even on i486 CPUs. There is hand-optimized assembly code for i586, MMX and 3DNow! instructions, while generic code runs on a variety of different platforms and CPUs.
 
36
It can play MPEG1.0/2.0 layer I, II, II (1, 2, 3;-) files (VBR files are fine, too) and produce output on a number of different ways: raw data to stdout and different sound systems depending on your platform (see INSTALL).
 
37
Most tested are Linux on x86 and Alpha/AXP and MacOSX on ppc as the environments the current developers work in.
 
38
We are always thankful for user reports on success (and failure) on any platform!
 
39
 
 
40
 
 
41
2. Contact
 
42
 
 
43
short:
 
44
 
 
45
        mpg123-devel@lists.sourceforge.net
 
46
        mpg123-users@lists.sourceforge.net
 
47
or 
 
48
        maintainer@mpg123.org
 
49
 
 
50
long: see doc/CONTACT
 
51
 
 
52
 
 
53
3. Interface/Usage
 
54
 
 
55
3.1 Simple Console Usage
 
56
 
 
57
Mpg123 is a console program - normally it just plays a list of files you specify on command line and that's it. See the included manpage or
 
58
 
 
59
        mpg123 --help
 
60
 
 
61
on command line syntax/options. I encourage you to check out the --gapless and --rva-album/--rva-mix options:-)
 
62
 
 
63
In the simple "mpg123 file1.mp3 file2.mp3" mode, the only thing you can do to interact is to press Ctrl+C to skip to next track or end the whole playback if pressing it twice.
 
64
 
 
65
Note that this Ctrl+C behaviour is special to this mode; when any of the following is activated, Ctrl+C will just kill the program like you would expect normally (this changed from earlier versions).
 
66
 
 
67
3.2 Advanced Console Usage
 
68
 
 
69
You can specify the option -C to enable a terminal control interface enabling to influence playback on current title/playlist by pressing some key:
 
70
 
 
71
'b' to seek back to beginning of track
 
72
'f' to skip to nest track
 
73
'p' for pause (actually, looping current chunk)
 
74
's' to stop/restart playback (the usual "pause" function...)
 
75
'q' to quit playback
 
76
',' for rewind seek
 
77
'.' for forward seek
 
78
';' for fast rewind
 
79
':' for fast forward
 
80
'<' for fine rewind
 
81
'>' for fine forward
 
82
'h' for printout of current key bindings
 
83
 
 
84
You can change these bindings to key to your liking by modifying term.h .
 
85
 
 
86
Note: This interface needs not to be available on _every_ platform/build.
 
87
 
 
88
3.3 Control Interface for Frontends
 
89
 
 
90
There used to be several interfaces for frontends left over from that past, but only one of them remains for the present and future:
 
91
 
 
92
        The Generic Control Interface
 
93
 
 
94
It contains of communication of textual messages via standard input to mpg123 and responses to standard output unless the -s switch for output of audio data on stdout is used - then the responses come via stderr.
 
95
 
 
96
See doc/README.control for usage.
 
97
 
 
98
 
 
99
4. Speed
 
100
 
 
101
mpg123 is fast. Any faster software player is probably based on some hacked mpg123;-)
 
102
This is the case with current MPlayer, wich includes mpg123-based code in its mp3lib.
 
103
There are some nice assembler optimizations (SSE, for example) that may make mplayer a faster mp3 decoder in cases where these are applicable - we are preparing to incorporate these into the mpg123 player to make it the fastest mp3 player under all circumstances.
 
104
 
 
105
 
 
106
5. Accuracy
 
107
 
 
108
        http://www.underbit.com/resources/mpeg/audio/compliance/
 
109
 
 
110
states mpg123-0.59r as being fully ISO/IEC 11172-3 compilant. Meaning: It decodes as it should. While I didn't verify the test I can confirm that the sound of mpg123 is fine enough for my ears;-)
 
111
 
 
112
I don't know which decoding routine they tested, I guess the pentium-optimized one. Depending on the chosen optimization, the output may vary slightly. At least the MMX assembler optimization is known to deviate in output by +/-1 (rarely +/-2).
 
113
This means +/- for the 16-bit integer sample value ranging over ca. +/-32000. This deviation may turn into hearable distortion for very low-amplitude sound, as shown in example files on
 
114
 
 
115
        http://dither123.dyndns.org
 
116
 
 
117
7. History
 
118
 
 
119
A looooong time ago (mid-90s), Michael Hipp wrote some initial mpg123 and made it _the_ Unix console mp3 player in the following years.
 
120
 
 
121
This is the historic description:
 
122
 
 
123
        This isn't a new player. It's a fully rewritten version originally based 
 
124
        on the mpegaudio (FHG-version) package. The DCT algorithm in the
 
125
        synthesis filter is a rewritten version of the DCT first seen in the maplay
 
126
        package, which was written by Tobias Bading (bading@cs.tu-berlin.de). The 
 
127
        rewrite was neccassary, because the GPL may not allow this copyright mix.
 
128
        The mpegaudio package was written by various people from the MPEG/audio
 
129
        software simulation group. The maplay is under GPL .. You can find the
 
130
        original source code and the mpegaudio package on: ftp.tnt.uni-hannover.de.
 
131
 
 
132
        Especially layer3.c common.c and mpg123.h is based on the dist10 package.
 
133
        The code is fullly rewritten but I'm using sometimes the
 
134
        same variable names or similar function names as in the
 
135
        original package.
 
136
 
 
137
        In the current layer3.c I'm using a DCT36 first seen in Jeff Tsay's 
 
138
        (ctsay@pasteur.eecs.berkeley.edu) maplay 1.2+ package. His code is
 
139
        under GPL .. I also tried the enhancement from Mikko Tommila. His
 
140
        code is also in layer3.c (but it's disabled at the moment, because
 
141
        it was slightly slower than the unrolled 9 point DCT (at least on 
 
142
        _my_ system)). Theoretically it should be faster. You may try it on
 
143
        your system.
 
144
 
 
145
Well, that's how it started...
 
146
Official development ceased due to the typical lack-of-time syndrome around 2002 and the free-floating patches began to seize the day.
 
147
 
 
148
But before that, Michael wrote or rewrote the essential code; others contributed their bits.
 
149
The main message is:
 
150
 
 
151
Code is copyrighted by Michael Hipp, who made it free software under the terms of the LGPL 2.1.
 
152
 
 
153
Please see doc/ROAD_TO_LGPL, COPYING and AUTHORS for details on that. Note that the only notable legacy non-LGPL file was the old alsa output that didn't work with alsa 0.9/1.0 anymore.
 
154
Also, there has been a libao output in the betas 0.60 for a short period. Libao being generally problematic for us because of its GPL license, this output is not distributed anymore in the release packages. There is now a new, LGPLed alsa output that made both the old alsa and libao obsolete for our purposes.
 
155
So, the distributed mpg123 releases actually only contains LGPL code, but you get the other files from our subversion repository if you checkout the trunk / version tags.
 
156
 
 
157
There has been quite some confusion about the licensing and "freeness" of mpg123 in the past.
 
158
The initial "free for private use, ask me when you want to do something commercial" license caused some people to avoid mpg123 and even to write a replacement mimicking the interface but using a different decoding engine - what was not actively developed for too long but entered the "free" software sections.
 
159
 
 
160
The Debian (non-free section) and Gentoo distributions cared about the last stable and the last development release of mpg123 over the years with mainly  applying security fixes. Thanks go to the distribution maintainers for not letting it alone to bitrot over the years.
 
161
 
 
162
Thomas Orgis started to hack on mpg123 in 2004 while working on his personal audio experience with mixplayd and later DerMixD, utilizing the generic control interface. In Feb 2005, he crammed control interface improvements together with Debian's r19 fixes and released the personal fork/patch named mpg123-thor.
 
163
Little later that year, Nicholas J. Humphrey independently created the sourceforge project and released an autotooled 0.59r under official GPL flag with Debian and MacOSX fixes.
 
164
In the beginning of 2006, Thomas finally decided that he could work "officially" on mpg123 and contacted Michael Hipp for taking over maintainership.
 
165
Michael was all-positive about letting mpg123 really live again (and perhaps see version 1.0 some time;-) and also pointed at the sourceforge project that didn't see much activity since the initial release. 
 
166
A lot of emails and some weeks later there was the two-developer team of Nicholas and Thomas working on merging their mpg123 variants as well as adding some features and fixes to let it shine again.
 
167
 
 
168
And there we are now...
 
169
 
 
170
8. End
 
171
 
 
172
Have fun!
 
173
____________
 
174
Thomas Orgis