Tue. Mar 5th, 2024

Quick Links

Key Takeaways

  • OPUS is an open-source audio codec suitable for real-time streaming and static audio files.
  • Major platforms and services like YouTube, Spotify, Netflix, and SoundCloud widely use OPUS.
  • You can use media players such as VLC to open OPUS audio files and streams.

There are many different file types used for audio. Most people know MP3, M4A, WAV, or FLAC, but one of the most popular modern audio codecs is OPUS. It’s used a lot in streaming, and some of your favorite apps rely on this oddly named format.

What is OPUS?

The Opus logo.

OPUS is a modern, high-fidelity, real-time, royalty-free, and open-source audio codec. It’s similar in purpose to other lossy audio codecs such as MP3, AAC, and Vorbis, though many unique qualities distinguish it from its peers. You can use OPUS for real-time streaming over low-bandwidth links, as well as encoding static audio files like songs or voice recordings. Because of its hybrid design, it’s well-suited for both speech and music applications.

Who Makes It?

The Xiph.org logo.

Producing the official OPUS standard was a joint effort between two unlikely collaborators. Developers working on similar goals of a low-latency, high-fidelity audio codec from both the non-profit organization Xiph.org and Skype, Limited (Now Microsoft) combined their respective CELT and SILK codecs to create OPUS.

CELT (Constrained Energy Lapped Transform) was first developed by Jean-Marc Valin of Xiph.org in 2007. While working on a high-quality videoconferencing project as part of his post-doc, Jean-Marc realized that there were no suitable high fidelity, yet low latency, audio codecs. There were high delay, high latency codecs such as MP3, Vorbis, and AAC. There were low delay, low latency speech-oriented codecs such as AMR, G.729, and Speex (which Jean-Marc also produced in 2002 with help from David Rowe). But like in the fairy tale Little Red Riding Hood, neither codec was “just right” for high fidelity, low latency audio use cases like what he was working on.

SILK was developed at Skype by Koen Vos, Søren Skak Jensen, and Karsten Vandborg Sørensen, starting in 2006. It was intended as a replacement for their currently used SVOPC audio codec, which was also developed in-house. The SVOPC codec was itself a replacement for Skype’s previously employed iSAC and iLBC codecs, both of which were licensed by a third party. SILK was first used in Skype in January 2009, and then in March, it was announced that it would be available under a royalty-free license to third-party software and hardware developers. It was submitted to the IETF in July 2009, which is when Jean-Marc noticed the project.

Though CELT was proposed to the emerging IETF working group alongside SILK, there were also other parties present in the process who strongly resisted standardizing on a single codec at all. With the two codecs being proposed simultaneously, the developers at Xiph.org and Skype decided to take a closer look at their respective projects together. To both of their surprise, CELT and SILK actually complimented each other quite nicely. SILK excelled at encoding speech up to 8KHz, and CELT was more efficient at coding music with sub-10ms delay. Even better, with neither codec able to efficiently code speech up to 20KHz, they were able to combine them to achieve this with high quality and low latency. The collaboration continued, and OPUS, a hybrid of SILK and CELT, became an IETF standard in 2012.

Who Uses It?

OPUS may just be the most popular audio codec you’ve never heard of. For example, the following major platforms and services use OPUS to deliver audio:

  • YouTube
  • Spotify
  • Vimeo
  • Netflix
  • SoundCloud
  • Signal
  • WhatsApp
  • Discord
  • Mumble

The list doesn’t stop here. Countless other platforms, commercial and independent streaming radio stations, and other projects use OPUS. The Icecast open-source media streaming server, also developed by Xiph.org, supports OPUS as its preferred audio codec.

The Ogg Container Format

OPUS data contains digitally encoded audio and not much else. It, as well as many other media codecs, are designed to be placed inside a container, which helps describe and organize the data inside.

You can think of a container like a box. It allows you to put multiple separate things inside of it. On the outside of the box is a label that describes everything inside. Some container formats you’ve probably heard of before are TAR and ZIP, which are general-purpose archive files.

Unlike TAR and ZIP, however, the Ogg container format was created specifically to hold multimedia streams. Following the standard of Xiph.org development, it’s a free and open format with no restrictions by software patents. Xiph.org started the development of Ogg in 1993 as part of a simple audio compression package originally called Squish.

An Ogg container file may contain any number of independent streams. These streams can be for video, audio, text and/or metadata. However, the OGG file extension is most commonly used to describe an Ogg container with the Vorbis audio codec inside (referred to as “Ogg Vorbis” files.)

It’s a common misconception that Ogg containers are fully synonymous with Vorbis audio. In fact, Xiph.org created additional file types and extensions to better describe content inside Ogg containers: OGA files for audio, OGV for video, and OGX for multiplexed Ogg.

OPUS audio was designed to be encapsulated in Ogg containers (specified as: audio/ogg; codecs=opus). However, when OPUS is used inside Ogg, instead of using the file extension OGG, the OPUS file extension is used.

How To Open an OPUS File or Stream

If you’ve got an OPUS file and need to open it, VLC is always a good choice. It has native support for these types of files and network streams, including those produced by Icecast. VLC is an open-source, cross-platform media player with installations available for Windows, MacOS, Linux, Android, and iOS. It’s also free to download. You can get the VLC player directly from the VideoLAN website or your operating system’s package manager.

We’ll use VLC to open a song I made a few years ago called “Concur,” which I encoded with OPUS.

After installing VLC, go to Media > Open File:

The VLC media player, with the Open File menu option selected.

Find the OPUS file you want to play in your file system and double-click it:

A VLC file selection window, with concur.opus file selected.

And it should start playing automatically since VLC has built-in support for OPUS audio:

VLC playing the concur.opus file.

OPUS is a great choice for high-fidelity, low-latency digital audio. The nature of its open design and offering makes it undeniably attractive for developers who want to incorporate it into their applications.

Source link

By John P.

Leave a Reply

Your email address will not be published. Required fields are marked *