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
Old versions of BladeEnc were very sensitive for compiler optimisations. Even well known compilers as Visual C++ and GNU C generated mutated versions of BladeEnc, producing lower quality output, when optimisations were enabled.
However, the cause of this problem has later been identified and solved (it was a compiler error, but it could easily and safely be avoided by marking a certain variable as 'volatile') and is no longer of any greater concern.
All compilers we know of generates correctly working BladeEnc binaries even when using the highest optimization level, but just to be sure we recommend you the following test:
First compile a non-optimized version of BladeEnc and encode an mp3
file (doesn't have to be so long, 20 seconds should be more than enough).
Then compile a fully optimized BladeEnc and use it to encode the same file,
then compare the outputs. They should be binary identical and not differ
by a single byte. If they differ, something has happened and I recommend
you to not trust the optimized binary.
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.
Contributing BladeEnc binaries
In order to port BladeEnc to a currently unsupported platform, please
follow these simple steps:
Compiling the DLL
To compile the Windows DLL, please follow these 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. In 0.92.0 or older you need to change here for switching between platforms. |
bladesys.c | Contains all 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, this has been removed in the latest version. |
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. :) |