This is now our fourth blog post about audio on the web (one, two, three). We may be risking beating a dead horse, but we do need to clarify an important point from our last entry: it is true games with 5000 distributions require a $2500 MP3 license. However, we've been in touch with MP3 licensing and they have said the license is only applicable if the MP3 files are available separately. If you let Flash combine everything in to a single .swf it therefore avoids separate MP3 files, making the license unnecessary for Flash games. Sorry if we gave any Flash developers a fright! (If you use external MP3s though, you still fall under the license!)

We also heard rumour of some special deal Adobe have with the MP3 license. We called Adobe and they told us no such deal exists. SWF is exempt under the MP3 license rules, so perhaps this was mistaken for a "special arrangement".

HTML5 games, on the other hand, are not exempt from this since they do use separate MP3 files. So you do have to be really careful about using MP3 in HTML5 games. MP3 licensing also clarified some of the points about using MP3 in games for us:

The '5000 distributions' is counted by users. So you probably want to measure unique IPs or similar, even though that is not a perfect metric. A partial download does not count. So if someone quits your game at 90% loaded, it doesn't count. Even if the user is using a browser that doesn't use the MP3 files (e.g. Chrome or Firefox, which download the Ogg files instead), it still counts as a distribution!

Unless you're willing to pay the $2500 fee, we strongly recommend using MPEG-4 AAC instead. Via Licensing, who handle the AAC license, have the following FAQ on their site to clarify this:

“Are there use fees for AAC?

No. License fees are due on the sale of encoders and/or decoders only. There are no patent license fees due on the distribution of bit-stream encoded in AAC, whether such bit-streams are broadcast, streamed over a network, or provided on physical media.”

In other words, game developers don't need to worry about AAC licenses at all. It's only those dealing with AAC encoders and decoders that need to worry about it, and that's the problem of whoever distributes the encoders/decoders. So, clearly AAC is far better for games than MP3! And this is why we don't support MP3 at all in Construct 2.

Isn't this complicated?

However, like MP3, AAC is still a patent-encumbered format. This means Via Licensing could change their mind about the state of affairs in future. Let's hope they don't. Also, it makes things complicated for us, because Construct 2 can encode AAC files and therefore we're applicable to the license. We've worked around this by using Windows 7's built-in AAC encoder, but it's a pretty basic encoder, and obviously this leaves XP and Vista users having to find their own encoders. Also, Windows 7's encoder doesn't take full advantage of the AAC format, so the files it makes sound worse and have larger filesizes than the Ogg Vorbis files (which, of course, is a free format). So Internet Explorer and Safari users will suffer poorer sound quality and slower download rates than users on other browsers. We could get a better AAC encoder, but then we need to sort out the licensing which could end up being expensive for a cash-strapped startup, and we don't feel like it's worth the cost when Ogg Vorbis performs excellently and is free.

I think it's interesting we've written so much on these patent-encumbered formats because they're so complicated. On the other hand, the rules for Ogg Vorbis can be fully summed up as thus: it is free for everyone. Isn't that nice and simple? Ogg Vorbis is the ideal format for the web, but Internet Explorer and Safari insist on complicating matters for web developers all over the world with their patented formats. This stems from a big war over video formats, which is much bigger fish. However I think it's an interesting indicator of who really has the best interests of the web at heart. To recap, Chrome, Firefox and Opera all support Ogg Vorbis. Apple and Microsoft's browsers don't, even though it is a completely free format and they could implement it without asking anyone right now if they wanted to, but they insist against doing that.

Summary

Ogg Vorbis is high quality, compresses well, and is free for everyone to use - even for us to encode. MP3 is too expensive for most independent developers to even consider for HTML5 games or externally with Flash, but Flash SWF files are exempt. AAC is free for HTML5 games, but still patent-encumbered, and would be unnecessary if all browsers just supported the free Ogg Vorbis format. However, AAC is free so we can all continue to use it for the time being anyway. Construct 2 takes care of the dual encoding problem for you (so long as you're on Windows 7) and prevents you from using MP3, so you're never at risk of surprise fees when making games with Construct 2. We hope that finally clears everything up!

Disclaimer: if you're in any doubt, please do seek your own advice about this - we don't make any claim that the information in this blog post is entirely accurate or applicable to your circumstances.