# SBC (codec)

SBC, or low-complexity subband codec, is an audio subband codec specified by the Bluetooth Special Interest Group (SIG) for the Advanced Audio Distribution Profile (A2DP). SBC is a digital audio encoder and decoder used to transfer data to Bluetooth audio output devices like headphones or loudspeakers. It can also be used on the Internet. It was designed with Bluetooth bandwidth limitations and processing power in mind to obtain a reasonably good audio quality at medium bit rates with low computational complexity. As of A2DP version 1.3, the Low Complexity Subband Coding remains the default codec and its implementation is mandatory for devices supporting that profile, but vendors are free to add their own codecs to match their needs.
At CES 2020 the Bluetooth SIG announced LC3 as the successor of SBC. LC3 is used in the LE Audio protocol based on the Bluetooth 5.2 Core Specification.

## Design

SBC supports mono and stereo streams, and certain sampling frequencies up to 48 kHz. Maximum bitrate required to be supported by decoders is 320 kbit/s for mono and 512 kbit/s for stereo streams. It uses 4 or 8 subbands, an adaptive bit allocation algorithm in combination with an adaptive block PCM quantizer. Frans de Bont has based the SBC audio codec on his earlier work, and – in parts – on the MPEG-1 Audio Layer II standard. In addition, the SBC is based on the algorithms described in the EP-0400755B1. The patent owners wrote that they allow the free usage of SBC in Bluetooth applications with a goal of boosting the use of this technology.

## Variants
### Overview

| | | SBC | SBC profiles | SBC profiles | FastStream | FastStream | Audio CD |
| | | SBC | Middle Quality | High Quality | FastStream | FastStream | Audio CD |
| | | SBC | | | main stream | back stream | (for reference) |
| misc. | Launch | – | May 2003 | May 2003 | March 2008 | March 2008 | 1982 |
| misc. | Related patents | EP 0400755B1 (expired) | – | – | US 9398620B1 (expired) | US 9398620B1 (expired) | – |
| misc. | Free implementations | FFmpeg, libsbc | libsbc | libsbc | libsbc | libsbc | – |
| misc. | Proprietary implementations | – | multiple hardware implementations | multiple hardware implementations | hardware implementation in Qualcomm chips | hardware implementation in Qualcomm chips | – |
| Audio Encoding | Channels | Mono (1) Joint Stereo (2) | Joint Stereo (2) | Joint Stereo (2) | Joint Stereo (2) | Mono (1) | Stereo (2) |
| Audio Encoding | Sampling rate | 16 kHz 32 kHz 44.1 kHz 48 kHz | 44.1 kHz 48 kHz | 44.1 kHz 48 kHz | 44.1 kHz 48 kHz | 16 kHz | 44.1 kHz |
| Audio Encoding | Bit rate | up to 510 kbit/s (@ 44.1 kHz) up to 507 kbit/s (@ 48 kHz) | 229 kbit/s (@ 44.1 kHz) 237 kbit/s (@ 48 kHz) | 328 kbit/s (@ 44.1 kHz) 345 kbit/s (@ 48 kHz) | 212 kbit/s (@ 48 kHz) | 72 kbit/s (@ 16 kHz) | 1411 kbit/s (@ 44.1 kHz) |
| Audio Encoding | Subbands | 4 or 8 | 8 | 8 | 8 | 8 | none |
| Audio Encoding | Bitpool | 2...86 (@ 44.1 kHz) 2...78 (@ 48 kHz) | 35 (@ 44.1 kHz) 33 (@ 48 kHz) | 53 (@ 44.1 kHz) 51 (@ 48 kHz) | 29 | 32 | none |

### Middle and High Quality

A2DP recommends encoders to support Middle Quality and High Quality presets as specified in the above table. As a result, most operating systems are using the High Quality profile as the default or even the only one supported encoding profile.

### Higher quality variants

However, A2DP requires decoders to support higher quality streams, up to 512 kbit/s, and there are some experimental encoders that use this feature: for example, SBC XQ, used by Lineage OS. With higher bit rate, audio quality is comparable to aptX HD (529 kbit/s).

### FastStream

While A2DP officially supports only one-way audio streams, CSR has found a way to send a voice-back stream opposite to the main stereo stream, making it possible to use A2DP in headsets with microphones. It was implemented in the FastStream codec, which is the SBC codec with set parameters and the voice-back stream added.

## Implementations

The A2DP test specification (V1.0) contains a reference implementation of the encoder and decoder for the SBC codec. A Linux implementation is available at BlueZ - The Linux Bluetooth stack.