A blank optical disc catching light on a dark desk

Codecs

The open-source answer had to be written twice

Seven hundred megabytes, whatever the film was. The blank disc is the unit the whole era measured itself against.

The codec is the argument · Medium

When the first open MPEG-4 codec imploded over its own licence, a small team rebuilt it from scratch — and kept it compatible enough that nobody noticed.

From OpenDivX to a fresh start

The sequence began with DivXNetworks, the company that had formed around Jérôme Rota's early hack, deciding in 2001 to sponsor an open-source MPEG-4 implementation. The project was called OpenDivX, and for a brief window it looked like the community would get both a clean codebase and corporate backing. What it got instead was a lesson in what happens when a company reserves the right to change the terms.

When DivXNetworks pulled OpenDivX back under a proprietary licence — retaining control of the code the community had helped to build — several of the project's contributors forked what they had and started over. The fork was announced in late 2001 and named XviD, an anagram of DivX. The name was a statement of intent: this was the same territory, contested.

A workbench with a monitor, cables and a tower case open
The bench where an encode was judged — one screen, one pass, and several hours to find out.

Because MPEG-4 Part 2 was a published standard from the Moving Picture Experts Group, writing a fresh encoder to it was legally viable. The specification defined what a compliant bitstream looked like; it said nothing about who could implement one. XviD's developers wrote their own entropy coding, motion estimation and rate control from scratch, producing an encoder that generated bitstreams any MPEG-4 Part 2 decoder — including every existing DivX decoder already installed on millions of machines — could read without modification. Compatibility was not a compromise; it was the strategy.

What XviD actually decided, codec by codec

The encoder that emerged made different choices than its competitors at almost every stage. XviD's motion estimation leaned heavily on half-pixel and quarter-pixel precision, extracting detail that simpler implementations left on the table. Its rate control introduced genuinely useful two-pass encoding: a first pass analysed the entire source to build a complexity map, and the second pass allocated bits accordingly — more for a fast action sequence, fewer for a static talking head. The result was that a given file size produced better average quality than single-pass alternatives, though at the cost of encoding time.

Its handling of the Group of Pictures structure was similarly deliberate. Keyframe interval and GOP size were exposed to whoever was configuring an encode, because the developers understood that a longer GOP saved bits while a shorter one made seeking tolerable — and that the right answer depended on the content. Chroma subsampling was handled at 4:2:0, standard for the era and consistent with what downstream players expected.

How it works

Key decisions and their consequences

  • OpenDivX licence reversal, 2001community contributors forked the code rather than surrender it
  • Name chosen as DivX anagramdeliberate positioning as the open alternative to the same format
  • Two-pass rate controlfirst pass builds complexity map; second pass allocates bits per scene
  • GOP size exposed to configurerslonger GOP saves bits; shorter GOP preserves seek accuracy
  • Output container: AVIcodec outpaced the container's capabilities
  • GNU General Public Licenceallowed hardware manufacturers to ship without MPEG LA royalties
  • Patent exposure remainedGPL covers copyright, not patents; no litigation materialised

What XviD could not solve was the container problem. Its output typically landed in AVI, a format from 1992 that had no native support for variable bitrate audio sync, chapter markers or multiple subtitle tracks. The codec was cleaner than the box it shipped in, and users spent years working around AVI's limitations even as the video quality steadily improved.

The licence that made it matter

XviD was released under the GNU General Public Licence. That single decision separated it permanently from every commercial MPEG-4 encoder. Anybody could study the source, anybody could modify it, and any modification had to be shared under the same terms. Hardware manufacturers shipping devices with MPEG-4 playback could build on XviD's freely licensed source, though the patent question remained open — which they did, quietly, in set-top boxes and portable players throughout the mid-2000s.

The irony is that XviD's success made it a target of the same patent system it was built to navigate around. MPEG LA maintained that MPEG-4 Visual patents applied to any conforming implementation regardless of how its source was licensed. The GPL covered copyright; it said nothing about patents. XviD's developers argued the implementer's position and kept shipping. The practical outcome was that litigation never materialised, the codec remained in wide use, and when H.264 eventually made MPEG-4 Part 2 look inefficient, XviD faded not because it lost a legal fight but because a better compression standard arrived.

DivX Video logo with white lettering and blue X on black oval badge
The mark as it looked once DivXNetworks had a product to put it on. The winking emoticon of the 1999 alpha is gone from it.Photo: DivX-Logo · Wikimedia Commons

Chronology

Chronology

  1. 2001, earlyDivXNetworks launches OpenDivX as open-source project
  2. 2001, lateDivXNetworks relicences; contributors fork and begin XviD from scratch
  3. Mid-2000sXviD ships in set-top boxes and portable players
  4. Late 2000s onwardH.264 adoption reduces MPEG-4 Part 2 relevance