BladeEnc is distributed under the terms of the GNU Lesser General Public License (LGPL), so you are welcome to download and use the sourcecode for anything you want as long as you follow the license agreement.
Please click on "License" in the left frame to view the license agreement
before downloading the sourcecode.
Stable and Development versions
The sourcecode for BladeEnc is available in two versions: Stable and Development.
The stable version is the latest released version, which is the recommended sourcecode to download if you want to compile BladeEnc for a platform not supported. As long as you set the right defines in system.h and manage to compile together a binary it should work nicely.
The development version is always the latest thing, provided for people who wants to help developing BladeEnc. It might not work correctly if we are in the middle of some major changes. It also might contain serious bugs or decreased sound quality if we are experimenting with some new algorithms. I don't recommend you to download this for anything except helping out with the development. As soon as we have a development version which we considers to be trustworthy for everyday use, we'll release it as the next stable version.
From time to time there might just be a stable version if I've recently released a new stable version and haven't made any changes since then.
Click here to go to the source archive
Committing back changes
People who have downloaded the sourcecode and made improvements are
encouraged to send back their modified sourcecode. This is done by attaching
the sourcecode to an e-mail and sending it to tord.jansson@swipnet.se.
Please also write something about what you have changed and why since that
will make it easier for me.
WARNING 1 - Audio Quality
People who prefer to compile BladeEnc themselves should be aware that the BladeEnc sourcecode is a very delicate piece of code that needs your compiler to treat it absolutely correctly. Small changes in precision that won't affect other programs can affect BladeEnc's encoding process to such a degree that you get an audible degradation of sound quality!
We have found that some versions of well known compilers such as Visual C++ and GNU C do decrease the output if optimizations are enabled. Visual C++ 5.0 (without service packs) for example generates a mutated BladeEnc that adds a very irritating low-frequency "engine sound" to most music.
If you are serious about sound quality we recommend you to either download
binaries from our homepage or check the output of your compiled version
with that generated by any of our binaries. Given the same input file they
should generate exactly the same output (use md5sum or something similar
to compare). If they don't, the quality generated by yours might be lower.
WARNING 2 - MPEG Layer 3 Patents
Although the sourcecode for BladeEnc is distributed under the LGPL, it includes algorithms and solutions that some of the creators of the MPEG Layer 3 standard claims to have patents on.
This makes portions of the BladeEnc sourcecode quite unsuitable for
inclusion into other software projects. It might even be a breach of the
GPL / LGPL license of another product if you add patent covered parts of
BladeEnc to its sourcecode.
Porting BladeEnc
In order to port BladeEnc to a currently unsupported platform, please
follow these simple steps:
Getting Started with the BladeEnc Sourcecode
Here follows some information that might help you to get started with
the BladeEnc sourcecode:
| system.h | Contains platform specific defines. Change here for switching between platforms. |
| bladesys.c | Contains platform specific code |
| samplein.c | Mini-library for reading sample files and providing some basic sample conversion (8/16-bit, mono/stereo, big/little-endian etc). |
| main.c | The main code for reading commandlines, handling the batch, producing screen output and handling errors. Doesn't contain any of the MP3 encoding routines. |
| codec.c | The main interface for the MP3-encoding routines. If you just want to look at the MP3 engine you should start here. |
| bladetab.c | Just a damn big table, the inclusion of which was the best optimization so far... :) |
| tables.c | Some tables that were loaded as separate files in the ISO distribution. |
| formatbitstream2.c | Replacement for formatbitstream.c in the ISO distribution which seemed to be copyrighted. Provides the same functionality with about 1/3 of the code. :) |