Last modified: 2008/5/3
What is this?
X Lossless Decoder(XLD) is a tool for Mac OS X that is able to decode/convert/play various 'lossless' audio files. The supported audio files can be split into some tracks with cue sheet when decoding. It works on Mac OS X 10.3 and later.
XLD is Universal Binary, so it runs natively on both Intel Macs and PPC Macs.
Screenshot
Features
Support various formats
XLD supports the following formats:
Other formats supported by Libsndfile are also decodable. XLD uses not decoder frontend but library to decode, so no intermediate files are generated. All of the supported formats can be directly split with the cue sheet. XLD also supports so-called 'embedded' or 'internal' cue sheet.
Currently you can choose output format from WAVE,AIFF and Raw PCM. In addition, you can choose Ogg Vorbis (aoTuV), MPEG-4 AAC (QuickTime/CoreAudio), MP3 (LAME), Apple Lossless, FLAC and HE-AAC (aacPlus v1/v2) in the GUI version.
Plug-in oriented design
Frontend and backend of XLD are prefectry separated, so the frontend is able to access the various decoder with the same interface. If we provide plug-in interface in the future, you can easily develop the plug-in of the new format. If you are interested in this, please see XLDDecoder.h in the source files.
How to use
IMPORTANT NOTE : To split ape(flac,wav,etc) + cue files, open the .cue file from "Open..." in File menu. "Open Raw PCM (bin/cue)" can be only used to handle Raw PCM (header-less wav) files.
Prease refer Readme file included in the archive to get usage of GUI version. Usage of command line version is:
% xld [-c cuesheet] [-e] [-f format] [-o outpath] [-t track] file
Without any option, XLD simply outputs decoded WAVE file. The extension of the output file is changed from original one into ".wav"
You can specify the following options:
- -c cuesheet
-
Split file into tracks with cue sheet. If 'TITLE or 'ARTIST' is described in the cue sheet it affects the name of the output file.
- -e
-
Exclude pre-gap from output file. Pre-gap is appended to the last of tracks by default. This option is ignored when '-c' option is not specified.
- -f format
-
Specify the format of the output file. You can specify the following formats:
- wav
Microsoft WAVE format. This is default output format. Extension is ".wav".
- aif
Apple AIFF format. Extension is ".aiff".
- raw_big
Big-endian raw(linear) PCM format. Extension is ".pcm".
- raw_little
Little-endian raw(linear) PCM format. Extension is ".pcm".
- -o outpath
-
Specify the path or name of the output file. If outpath is a directory, output file is saved in that directory.
- -t track
-
If you specify "1" as a track, only the track 1 is decoded. Likewise, Track 2 and 4 are decoded when you specify "2,4" as a track.
- --raw
-
Read input file as Raw PCM. Following 4 options can be specified.
- --samplerate n
-
Set samplerate of input file to n Hz when --raw option is specified. Default is 44100 Hz.
- --bit n
-
Set bit depth of input file to n bit when --raw option is specified. Default is 16 bit.
- --channels n
-
Set number of channels of input file to n ch when --raw option is specified. Default is 2 ch.
- --endian little/big
-
Set endian of input file when --raw option is specified. Default is little.
Examples
% xld -o ~/Music hoge.flac -f aif
Decode hoge.flac in the AIFF format, and output in ~/Music.
% xld -c hoge.cue -t 1,3 hoge.flac
Split hoge.flac with hoge.cue, and decode the 1st and 3rd tracks.
Download
The source code of XLD is included in the archive. The library and header of Libsndfile, FLAC, Wavpack, Monkey's audio and Libcddb is required to compile.
Notes: Do not use Zipeg or The Unarchiver for extracting these archives. I've received some reports that these softwares break unix permission.
Make a donation
If you appreciate XLD and would like to support the project, you are welcome to donate via Paypal.
ToDo
- Enable to save changes in the cuesheet
- Enable to convert tags simultaneously
- Polish user interface
- Enable Apple lossless decoding in 10.3
I myself don't want this ;)
Version history
2008/5/3
- Fixed bug that prevented reading cue sheet with no PERFORMER info
- Added "Cancel All Tasks" context menu to the progress window
- Slightly improved performance of LAME mp3 encoder
- Updated LAME 3.98b8 plugin
More Altivec optimization has been applied. Now 10-15% faster than the previous version on G4/G5 machine (graph).
2008/4/23
- Updated LAME 3.98b8 plugin
A part of psychoacoustic analysis routine for vbr-new has been optimized for AltiVec. This resulted in about 15% speedup on G4/G5 machine.
2008/4/21
- Updated LAME 3.98b8 plugin
Enabled asm routine for Intel CPU; now 20% faster than before.
2008/4/19
- Provided LAME 3.98b8 Plugin
There are various changes since 3.97. The interface is slightly changed because now floating-point quality value can be specified in VBR mode for more flexible quality control. This version is uniquely optimized for AltiVec (as 3.97 in the current XLD), so it is faster for G4/G5 users than the original version.
2008/4/6
- Provided aoTuV b5.5 Plugin
2008/3/30
- Supported reading cover art in ape/wavpack files
- Supported album artist metadata in some formats
- Reduced memory usage when importing cover art
- Added German localization
- Added French localization
Notes: Cover art obtained from iTunes Store isn't embedded in music file itself. So XLD cannot read cover art form such kind of ALAC files.
2008/3/13
- (20080313a)Fixed MP3 encoder to work correctly on G4/G5 Mac
- Added support for embbeded cover art
XLD now can read embedded cover art in FLAC and ALAC, and can embed cover art in (HE-)AAC, MP3, FLAC and ALAC. If you want to embed the existing image file, drag and drop the file to the box as shown in the figure below. Large images can be scaled when embedding. Scaling option is in the pref pane.
- Metadata supported by mp3 encoder was increased
For the detail, please see this page.
2008/3/10
- Supported MusicBrainz database
No specific configuration is required. XLD automatically querys MBDB when querying FreeDB.
- Fixed bug that prevented decoding TTA files with ID3 tag
- Changed timescale of m4a file created by HE-AAC encoder to 600
2007/3/8
- Fixed bug that caused corrupt .m4a output when encoding 48kHz file
- Gave up support for 32kHz input in HE-AAC encoder due to very limited bitrate range
cf. mono file must be encoded at bitrate <= 44kHz.
- Updated Simplified Chinese localization resources
2007/3/5
- Added support for HE-AAC output by aacplusenc
Supported bitrate range is 16-64kbps. Parametric stereo is used if bitrate <= 44kbps. Supported input frequency is 32, 44.1 and 48kHz.
For high-quality playback, use MPlayer or VLC. AAC decoders based on QuickTime cannot handle SBR and PS part.
- Integrated MP3 decoder
Still no support for ID3 reading.
- Fixed bug that caused crash when Raw PCM import
2007/11/21
- Disabled option of writing accurate bitrate in AAC encoder on Leopard (GUI)
I noticed that this option is meaningless on Leopard, because AAC encoder on Leopard writes accurate bitrate by default.
- Spin-off (currently in Japanese only)
2007/11/19
- Updated converter routine to enable multi-threaded conversion (GUI)
You can set maximum number of threads from Preference.
- Supported writing accurate bitrate in AAC encoder (GUI)
Now similar to iTunes.
2007/11/14
- (Nov. 13, 2007 19:00 GMT)Updated again because VBR quality is not saved
- Supported ABR and unconstrained(true) VBR mode in AAC encoder (GUI)
The new AAC encoder is available on Leopard, or Tiger with QuickTime 7.3 installed. Here is a brief explanation of available modes:
- CBR
Keep a bitrate constant, but it is not perfectly constant due to a bit reservoir.
- ABR
Try to encode at a target bitrate on an average. It fluctuates bitrate locally more than CBR because bitrate restriction is applied in a longer time span compared to CBR.
- VBR (Constrained)
Fluctuates bitrate according to the difficulty of encoding. It constrains variation range due to the target bitrate. So It doesn't fully take advantage of VBR feature, but more efficient than ABR. Older version of XLD and iTunes use this as VBR mode.
- True VBR
Fluctuates bitrate according to the difficulty of encoding to maintain a target quality. Bitrate variation is unconstrained. Theoretically it provides the best tradeoff between quality and bitrate, but bitrate is hard to predict. Apple's implementation requires target quality in 0 to 127 range. As a guide, quality 0 is about 32kbps, 90 is about 128kbps, and 127 is about 192kbps, respectively.
True VBR mode requires target quality, and the others require target bitrate. Unlike the previous version, the target bitrate can be specified at any value in 16-320kbps.
- Added Simplified Chinese localization (GUI)
Thanks to Shonete Smith.
2007/11/11
- Updated AAC/Apple Lossless encoder to fix the compatibility problem with Leopard (GUI)
- Added in ver. 20071111a: fixed a remaining bug in AAC encoder (GUI)
The bug occurs when encode a file longer than a few minutes with tag on Leopard... sorry.
2007/9/17
- Updated FLAC to version 1.2.1
- Changed default extension for Ogg FLAC from .ogg to .oga according to the new specification (GUI)
- Improved performance of tag writing for AAC/ALAC output plugin (GUI)
2007/8/11
- Fixed a bug that album name is incorrectly set to the last track title when reading embedded cuesheet (GUI)
2007/7/28
- Updated FLAC to version 1.2.0
It will be slightly faster on Intel Macs due to enabling MMX/SSE codes.
- Partially rewritten Monkey's Audio/TTA decoder with SSE optimization
Notes: TTA version 3.4.1 has been released, but it has no improvement on decoder and lost 32bit float decoding capability. So XLD still uses version 3.3.
- Fixed overwriting problem when both input and output file have the same name (GUI)
2007/6/28
- Fixed a bug that prevented decoding ALAC files on Intel Mac
- Updated WavPack to version 4.41
2007/5/4
- Partially fixed a bug that caused crashes on iPod when playing Apple Lossless file encoded by XLD
"Partially" means that I don't understand a fundamental cause of this bug. Probably this is a problem of iPod or CoreAudio. Note that you don't have to re-encode ALAC files unless you play those files with iPod.
- Fixed a bug that prevented converting 24/32-bit files to Apple Lossless
- Fixed some minor issues
2007/2/14
- Updated FLAC to version 1.1.4
- Supported reading cuesheet which has index over 99:99:99
- Improved handling of character encodings in cuesheet
2006/12/16
- Added option to get only the specific info from CDDB (GUI)
Please refer to "Query Items" submenu in "CDDB" menu.
- Improved handling of 32bit floating-point audio files
- Added option to select stereo mode in LAME output plugin (GUI)
Please use with default (Auto) setting if you have no special reason.
- Updated WavPack to version 4.40
2006/12/9
- Fixed a problem that caused some noises at the beginning of the file when XLD read AIFF directly from the Audio CD mounted on desktop
This may be a bug of Libsndfile, but I temporarily dealt with it on my side.
2006/12/3
- Added interface to select character encodings of cuesheet (GUI)
- Added an application icon
2006/11/29
- Updated FLAC to version 1.1.3
- Supported Ogg FLAC output (GUI)
- Some minor bug fixes
2006/11/25
- Added option to fix the offset by 30 samples
Related to this problem... This option partially correct the problem that the offset data measured by EAC is wrong in 30 samples. If this option is enabled, 30 zero samples are inserted into the beginning of the file and 30 samples are truncated at the end of the file.
The option in the command-line version is "--correct-30samples".
Note that this option must NOT be used with the file which is nothing to do with the problem.
2006/11/19
- Updated FLAC to version 1.1.3b2
- Supported OggFLAC input
- Changed FLAC handler from libsndfile to native libFLAC
Huge commit around FLAC. Seeking is now stable. Support of OggFLAC output is implemented, but disabled in the interface because it generates corrupt file...
2006/11/18 (Revision 2)
- Fixed problem that XLD did not work on OSX 10.3 since version 20061011 (GUI)
Sorry...
2006/11/18
- Fixed problem that XLD failed to decode the file with tag whose character encoding is invalid
2006/11/11
- Spun off player interface (GUI)
- Enabled player to open the file without cuesheet (GUI)
- Enabled player to seek anywhere in the file (GUI)
- Fixed the bug that prevented ALAC playback (GUI)
To play file without cuesheet, please select "Show Player" from Window menu and drag file there. There is no change for playing the file with cuesheet, i.e., open the cuesheet and double-click the track you want to play.
I already recognized the crash bug when seeking FLAC file. This is probably due to Libsndfile, which XLD depends on when decoding FLAC. I'll try to write the new FLAC decoder to fix this bug.
2006/11/8
- Improved playback function (GUI)
Improved buffering scheme, made seeking faster, and several bug fixes.
2006/10/31
- Updated libcddb to version 1.3.0
- Added some supported tags to convert
Supported tag list is here.
2006/10/29
- Supported Raw PCM input in the command-line version
Please use --raw option to read.
2006/10/28
- Supported conversion of metadata(tags) from ALAC (GUI)
2006/10/27
- Fixed problem that prevent G5 machine from reading LAME output plugin (GUI)
I missed this problem for a long time... Sorry.
2006/10/26
- Fixed remember to convert DATE string to YEAR when read from cuesheet (GUI)
- "REM GENRE" and "REM DATE" lines are now read from embedded cuesheet (GUI)
- Some minor fixes
2006/10/25
- Provided aoTuV b5 Plugin
To use, please remove old "XLDVorbisOutput.bundle" and add the new one from the plugin section of Finder's show info panel . You may also directly replace the file in XLD.app/Contents/PlugIns with the new one. Note that the default version included in XLD will be b4.51 for some while because the quality is quite steady.
2006/10/22
- Supported conversion of metadata(tags) partially (GUI)
In case the input format is FLAC or Monkey's Audio or WavPack, some metadata in the tag are preserved(if output format supports). Preserved metadata are: TITLE, ARTIST, ALBUM, TRACKNUMBER, GENRE, YEAR, COMMENT, etc. Note that metadata is ignored when cuesheet exists.
- Supported reading "Genre" and "Year" information from cuesheet and CDDB (GUI)
"REM GENRE" and "REM DATE" line is read, respectively.
2006/10/14
- Supported internal/embedded cuesheet for Monkey's Audio (GUI)
- Changed interface when "Open as Raw PCM(+cue)" is selected (GUI)
2006/10/12
- Supported internal/embedded cuesheet for FLAC and WavPack (GUI)
Supported foobar2000's original format.
2006/10/11
- Supported Raw PCM input (GUI)
Select "Open as Raw PCM(+cue)" in the dialog which appears after open the file, or choose "Open as raw PCM (bin/cue)..." from the File menu. Then you will get a dialog to select the format of the raw PCM file. You can choose format and open it. Probably you will be able to read bin/cue type audio image in this mode. Note that cue sheet in this mode must have extension ".cue".
- Supported internal/embedded cuesheet partially (GUI)
Currently XLD only supports cuesheet embedded as FLAC__StreamMetadata which is natively supported by FLAC. When you open the file that has embedded/internal cue sheet, you can choose from the dialog if you want to read it. foobar2000's original(?) format, that is, cue sheet which is embedded as Ape tag/VorbisComment will be supported in the future.
Command-line version will be updated later...
2006/9/25
- Updated lame mp3 encoder's version to 3.97 (GUI)
- Some minor fixes (GUI)
lame 3.97 doesn't have any quality-related change since 3.97b3. You don't have to re-encode your files.
2006/9/16 (Revision 2)
- Updated Libsndfile library
2006/9/16
- Supported FLAC output (GUI)
Someone's request.
The reason why XLD did not support lossless encoder(except ALAC...because it is playable on iTunes) is simply the name of application, i.e. "lossless decoder" ;)
2006/9/15
- Updated AAC output plugin (GUI)
Gapless information now includes the number of padding samples. This will make the info fully compatible with iTunes 7...
2006/9/14
- Added option to add gapless playback information for AAC output plugin (GUI)
AAC output plugin adds gapless playback information that is newly added to files encoded by iTunes 7. If you decode the file with this information using iTunes 7, the number of samples of output is exactly the same as the original. This info is probably available only for iTunes 7 (not for other player). Note that the previous AAC files encoded by XLD seem to be gapless (for me) if use iTunes 7... And this option is currently experimental, so please report me if something is wrong.
ALAC and mp3(lame) are already ready for gapless playback. For mp3 iTunes 7 seems to read lame tags.
2006/9/13
- Fixed problem that disabled Apple lossless encoder (GUI)
By the way, gapless playback became possible thanks to the release of iTunes 7. Now you can enjoy gapless playback of files split/encoded by XLD using iTunes 7.
2006/9/11
- Updated lame mp3 encoder's version to 3.97b3 (GUI)
- Modified default quality of lame to '-q 3' (GUI)
Now output is euqivalent to the preset of command-line encoder...
2006/9/9
- XLD is now able to play and convert simultaneously (GUI)
2006/9/8
- Updated TTA decoder
- Fixed some bugs in lame mp3 output plugin (GUI)
- Rewrote all output plugins for future major update release (GUI)
2006/9/2
- Added preliminary support for batch conversion (GUI)
If you open multiple files with XLD simultaneously, they will be converted one after another.
The files which are not supported by XLD will be ignored (XLD shows no error message in batch conversion mode).
2006/8/28
- Fixed several bugs in CDDB querying routine (GUI)
- Added checkbox to enable/disable local CDDB cache (GUI)
To remove cache, please delete ~/.cddbslave directory. (use Terminal, etc)
- Updated Monkey's Audio decoder
Now read files in the rocked volume...
2006/8/27
- XLD now shows dialog if CDDB server returns multiple candidates of the disc (GUI)
- Added CDDB server list manager (GUI)
- Title and Artist columns are now resizable (GUI)
2006/8/26
- Added function to get track information from CDDBs (GUI)
- Some bug fixes and improvements in the playback routine (GUI)
2006/8/8
- Added simple music player capable of playing tracks based on the index of the cue sheet (GUI)
Double-click the track you want to play in the cue sheet window. Interface will be improved later.
2006/8/5
- Added function to specify the format of output filename (GUI)
- Fixed a problem of decode failure when the output format is AAC or ALAC, and colon(:) is included in the character of metadata (GUI)
- Fixed a problem of crashing when the output format is AAC or ALAC, and the metadata has only title string (GUI)
2006/7/16
- Added support for output in Apple Lossless format(GUI, 10.4 and above)
- Fixed a problem of ignoring preferences when XLD is launched by drag-and-drop(GUI)
- Supported reading cue sheet with Carriage Return only
- Some minor fixes
2006/6/22 (revision 2)
- Fixed corrupt output at end-of-file when tagging with AAC
2006/6/22
- Updated Wavpack decoder
Now reads .wvc file if exists.
- Supported automatic tagging from metadata in the cue sheet (GUI)
Available for MP3, Vorbis and AAC output. Currently supports only a portion of metadata.
Format of MP3 tags are ID3v2.3. Characters are written in Unicode(UCS-2).
2006/6/20
- Updated Monkey's audio decoder
- Implemented automatic encoding detenction method for Japanese character in the cue sheet
2006/6/17 (revision 2)
- Added OS version checking routine in plugins
2006/6/17
- Added support for output in MP3(lame) format
2006/6/15
- Updated Monkey's audio decoder
- Improved handling of cue sheet
2006/6/14
- Added support for output in MPEG-4 AAC format (10.4 only)
- Supported saving prefs of output plugins
2006/6/13
- Added support for output in Ogg Vorbis format
- Some minor fixes
2006/6/12
- Initial release of GUI version
2006/6/6
- Fixed a decoding problem of 8bit ape files on the x86 machines
- Tweaked some interfaces
2006/5/30
- Made XLD Universal Binary
2006/5/28
- Used GNU getopt instead of libsystem's getopt
- Added support of output in AIFF and Raw PCM
- Changed behavior of -o option
2006/5/27
Please feel free to link to this page.
E-mail