# PLSconvert.me — licences and patent notes This file covers the web version. Read it before you put the site on a public server, because one of the components carries conditions you have to satisfy as the person distributing it, and a patent question that no licence resolves for you. --- ## What ships, and under what terms | Component | What it does | Terms | | --- | --- | --- | | PLSconvert.me itself (`index.html`, `app.js`, `tags.js`, `style.css`, `base.css`) | The application | Yours | | `@ffmpeg/ffmpeg` + `@ffmpeg/core` | Decoding, DSP, muxing, most encoders | LGPL/GPL, loaded from jsDelivr ([FFmpeg legal](https://www.ffmpeg.org/legal.html)) | | `vendor/fdkaac.js` | Fraunhofer FDK AAC encoder — AAC-LC, HE-AAC v1, HE-AAC v2 | Fraunhofer FDK AAC licence — **see below** | | `vendor/fdk-wrapper.c` | The ~200-line C wrapper around it | MIT, part of this project | | JSZip | "Download all (.zip)" | MIT, loaded from a CDN | --- ## The Fraunhofer FDK AAC encoder ### Why this is a separate module and not part of FFmpeg FFmpeg cannot ship `libfdk_aac`. A build that links it must be configured `--enable-nonfree`, and the result is not redistributable — FFmpeg says so plainly, and the reason is worth understanding: the FDK licence is **incompatible with the GPL**, and FFmpeg's own builds are GPL. You cannot satisfy both licences at once, so the combined work cannot be distributed ([why FFmpeg does not distribute a libfdk-aac binary](https://opensource.stackexchange.com/questions/2395/why-doesnt-ffmpeg-distribute-a-binary-with-libfdk-aac-enabled)). That is a GPL-compatibility problem. It is **not** a rule that FDK AAC cannot be redistributed. The FDK licence itself says the opposite: > Redistribution and use in source and binary forms, with or without modification, are > permitted without payment of copyright license fees provided that you satisfy the > following conditions So PLSconvert.me compiles the encoder into its own standalone WebAssembly module that links nothing GPL. The incompatibility never arises, and the module can be served to visitors like any other asset. This distinction matters for a website in a way it does not for a desktop app. A WebAssembly module is downloaded and executed by every visitor, so serving one is distribution in the most literal sense there is. A nonfree FFmpeg build could never be put here. This module can. ### What you must do when you host this These are the FDK licence conditions, and hosting the site is distribution: 1. **Keep `vendor/FDK-AAC-NOTICE.txt` on the server and reachable.** The licence requires the complete licence text to accompany the binary. The page footer links to it. Do not delete it, and do not block `vendor/` in `.htaccess` or via your CDN. 2. **Keep `vendor/fdk-aac-2.0.3.tar.gz` downloadable.** The licence requires you to make the complete source code of the codec available free of charge to anyone who receives the binary. That tarball is the unmodified upstream release: ``` fdk-aac 2.0.3 https://github.com/mstorsjo/fdk-aac/archive/refs/tags/v2.0.3.tar.gz sha256 e25671cd96b10bad896aa42ab91a695a9e573395262baed4e4a2ff178d6a3a78 ``` 3. **Keep `vendor/fdk-wrapper.c` downloadable** — it is the only modification alongside the codec, and shipping it keeps condition 2 unambiguous. 4. **Do not charge a copyright licence fee** for the codec. 5. **Do not use Fraunhofer's name to promote the site.** Naming the encoder factually, as this file and the footer do, is not promotion; "powered by Fraunhofer" would be. 6. **If you modify the codec source**, the licence requires prominent notices stating what you changed and when, and the name must become "Third-Party Modified Version of the Fraunhofer FDK AAC Codec Library for Android". The shipped codec is unmodified — only the wrapper is ours — so this does not currently apply. The full text is in `vendor/FDK-AAC-NOTICE.txt` and at [SPDX](https://spdx.org/licenses/FDK-AAC.html). Read it rather than relying on this summary. ### Patents — read this part Copyright and patents are separate, and nothing above touches patents. The FDK licence is explicit: > NO EXPRESS OR IMPLIED LICENSES TO ANY PATENT CLAIMS, including without limitation the > patents of Fraunhofer, ARE GRANTED BY THIS SOFTWARE LICENSE. > > You may use this FDK AAC Codec software or modifications thereto only for purposes that > are authorized by appropriate patent licenses. AAC is patent-encumbered. Practical points: - **This is not new exposure introduced by the FDK module.** The site already encoded AAC with FFmpeg's native encoder, which implements the same patented standard. Adding FDK changes the code, not the patent position. - **AAC patent licensing is per-product, not per-file.** Via LA charges a one-time fee — US$15,000, or US$1,000 for a small entity of 15 or fewer employees and under US$1M revenue — and charges **nothing on the bitstreams** an encoder produces ([Via LA AAC FAQs](https://www.via-la.com/licensing-2/aac/aac-faqs/)). - HE-AAC's SBR and parametric stereo tools are newer than the AAC-LC core, so their patent timelines run later. If patent exposure is a concern for you, that is an argument for offering Opus at low bitrates rather than HE-AAC — see below. - **This is not legal advice.** If you run this commercially, ask a lawyer about Via LA. If none of that appeals, delete `vendor/` and remove the FDK presets from `FDK_PRESETS` in `app.js`. Everything else keeps working; you lose HE-AAC. --- ## A note on when HE-AAC is worth it HE-AAC exists to make small files sound acceptable, and at that it works — measured on this build, HE-AAC v2 at 24 kbps stereo reproduces content up to about 16 kHz, where plain AAC-LC at the same bitrate is dead above 8 kHz. But Opus generally beats HE-AAC at 64 kbps and below, and Opus is royalty-free with no patent question at all. HE-AAC earns its place when something on the far end **requires** AAC: hardware players, broadcast encoders, older phones, streaming chains that only accept an AAC bitstream. If your target accepts Opus, the Opus presets are the better choice. --- ## One quirk you will notice Run `ffprobe` on a raw `.aac` file from an HE-AAC preset and it reports `profile=LC`. The same audio muxed into `.m4a` reports `profile=HE-AAC`. Nothing is wrong. ADTS headers carry implicit, backward-compatible signalling: the header declares LC so that a decoder which knows nothing about SBR still plays the core stream, and SBR is signalled inside the payload. The MP4 container has a proper configuration record, so it states the real profile. This is the default behaviour of the FDK encoder and of the `fdkaac` command-line tool, and it is the more compatible choice for hardware. The SBR data is present either way — decode both and measure the spectrum if you want to confirm it.