编解码器与容器
自维基百科Wikipedia, "编解码器(英语:codec)指的是一个能够对一个信号或者一个数据流进行编解码操作的设备或者程序。."
一般来说,编解码器被多媒体应用程序用来对音频或视频流进行编码或解码。为了播放编码后的数据流,用户必须确保安装了适当的编解码器。
这篇文章只关于编解码器及程式后端;见List of applications/Multimedia 以列举音视频播放器的选择如(MPlayer, mpv 和 VLC)
需求[编辑 | 编辑源代码]
播放常见的媒体需要
- 一个播放器
- 一个编解码器
如果有了媒体播放器,不一定非要安装编解码器。例如,MPlayer 就内置了大量编解码器。
编解码器列表[编辑 | 编辑源代码]
音频[编辑 | 编辑源代码]
见Wikipedia:Comparison of audio coding formats.
无损音频编解码器[编辑 | 编辑源代码]
- Apple Lossless (ALAC) — 由苹果公司开发的无损音频压缩编解码器,部署在其所有的平台和设备上。
- FLAC — 自由的音频编解码器
- WavPack — 无损的音频压缩格式,同时也有有损的hybrid mode.
有损音频编解码器[编辑 | 编辑源代码]
格式 | 编码器 | 解码器 | |
---|---|---|---|
AAC | #AAC | ||
ATSC A/52 | aftenAUR | a52dec包 | |
CELT | celtAUR | ||
MPEG-1 | libmad包 | ||
MP3 | lame包 | ||
Musepack (MPC) | – 1 | libmpcdec包 | |
Opus | opus包 | ||
Vorbis | libvorbis包 | ||
语音编解码器 | |||
AMR | opencore-amr包 | ||
Speex | speex包 |
- mppenc 没有打包。
- CELT — 开源、无专利的有损编解码器, 特点是低延迟。
- LAME — MP3 编码器、可视化框架分析。
- liba52 — 解码 ATSC A/52 (Dolby Digital) 流(有损)的自由库。
- libdca — 编码 DTS 相干声学流(DTS Coherent Acoustics streams)的自由库。
- MAD — 高品质 MPEG 音频解码器。
- Musepack (MPC) — 开源有损音频编解码器,为 transparency 而设计。
- opencore-amr — 自适应多速率(Adaptive Multi Rate,AMR)语音解码器的开源实现。
- Opus — 开源无专利音频编解码器,为语音和通用音频而设计,低延迟。
- Speex — 为语音设计的无专利有损音频压缩格式。
- Vorbis — 开源无专利有损音频编解码器。
AAC[编辑 | 编辑源代码]
自 Wikipedia:
- 高级音频编码(Advanced Audio Coding,AAC)是为数字音频压缩而设计的专有音频编码格式。作为 MP3 格式的继任者,AAC在相同采样率下音质一般优于 MP3。
- FAAC — 专有 AAC 音频解码器。
- FAAD2 — ISO AAC 音频解码器。
- Fraunhofer FDK AAC — AAC 编码器的 OpenCORE 框架实现。该库经 Fraunhofer AAC 编解码器修改而来。
- https://sourceforge.net/projects/opencore-amr/ || libfdk-aac包 (codec library) fdkaac包 (CLI frontend for libfdk-aac)
- Nero AAC — Nero AAC reference quality MPEG-4 and 3GPP audio codec. (deprecated)
图像编解码器[编辑 | 编辑源代码]
- JasPer — 新兴的 JPEG-2000 Part-1 标准编解码器的软件实现。
- OpenJPEG — 开源 JPEG 2000 编解码器。
- WebP — 适用于有损与无损压缩的图像格式服务。目前由 Google 开发。
- AV1 Image File Format (AVIF) — 基于 AV1 视频编解码器的图像实现。
- High Efficiency Image File Format (HEIF) — 基于 HEVC 编解码器的图像格式。通常使用 HEIC 容器。
视频编解码器[编辑 | 编辑源代码]
另见 Wikipedia:Comparison of video codecs。
格式 | 编解码器库 |
---|---|
AV1 | aom包, dav1d包 (decode), rav1e包 (encode), svt-av1包 |
AVS2 | davs2AUR (decode) |
Daala | daala-gitAUR |
Dirac | schroedinger包 |
DV | libdv包 |
H.265 | x265包, x265-hgAUR |
libde265包, libde265-gitAUR | |
H.264 | x264包, x264-gitAUR |
MPEG-1 | libmpeg2包 (decode) |
MPEG-2 | |
MPEG-4 | Xvid (xvidcore包) |
Theora | libtheora包 |
VP8, VP9 | libvpx包, libvpx-gitAUR |
- AV1 — AOMedia Video 1 (AV1) 是 Google's VP9、Mozilla's Daala、Cisco's Thor 编解码器的继任者。“aom”是编解码器的参考实现, “dav1d”是注重性能的编解码器, “rav1e” 是注重性能的解码器。Most benchmark show better performances with svt-av1 than rav1e.
- Daala — Research video codec under development by the Xiph.Org Foundation and sponsored by the Mozilla Foundation. The goal of the project is to provide a free to implement, use and distribute digital media format and reference implementation with technical performance superior to h.265.
- libde265 — Open source implementation of the h.265 video codec.
- libdv — The Quasar DV codec (libdv) is a software codec for DV video.
- libmpeg2 — Library for decoding MPEG-1 and MPEG-2 video streams.
- Schrödinger — Advanced royalty-free video compression format designed for a wide range of uses, from delivering low-resolution web content to broadcasting HD and beyond, to near-lossless studio editing.
- Theora — Open video codec developed by the Xiph.org.
- VP9 — High-quality, open video format for the web that's freely available to everyone. Improved version of earlier VP8 codec.
- x264 — Free library for encoding H264/AVC video streams.
- x265 — Open-source project and free application library for encoding video streams into the H.265/High Efficiency Video Coding (HEVC) format.
- Xvid — Open source MPEG-4 video codec.
容器格式工具[编辑 | 编辑源代码]
另见 Wikipedia:Comparison of video container formats。
- MKVToolNix — Set of tools to create, edit and inspect Matroska files.
- MP4Joiner — A collection of GUI tools to manipulate MP4 files (MP4Joiner, MP4Splitter).
- OGMtools — Information, extraction or creation for OGG media streams.
后端[编辑 | 编辑源代码]
GStreamer[编辑 | 编辑源代码]
From https://gstreamer.freedesktop.org/:
- GStreamer is a library for constructing graphs of media-handling components. The applications it supports range from simple Ogg/Vorbis playback, audio/video streaming to complex audio (mixing) and video (non-linear editing) processing.
Simply, GStreamer is a backend or framework utilized by many media applications. See GStreamer article.
xine[编辑 | 编辑源代码]
From https://sourceforge.net/projects/xine/:
- xine is a free multimedia player. It plays back CDs, DVDs, BluRays and VCDs. It also decodes multimedia files like AVI, MOV, WMV, and MP3 from local disk drives, and displays multimedia streamed over the Internet.
As an alternative to GStreamer, many media players can be configured to utilize the xine backend provided by xine-lib包.
Note that the xine project itself provides a capable video player, xine-ui包.
libavcodec[编辑 | 编辑源代码]
libavcodec is part of the FFmpeg project. It includes a large number of video and audio codecs. The libavcodec codecs are included with media players such as MPlayer and VLC, so you may not need to install the ffmpeg包 package itself.
疑难解答[编辑 | 编辑源代码]
No H264, mpg4 or Musepack (.mpc) in Totem Player[编辑 | 编辑源代码]
If you see the "The H264 plugin is missing" warning with Totem media player, 安装 gst-libav包.
No H264 in Parole Player[编辑 | 编辑源代码]
If you see the "Parole needs H.264 decoder to play this file" warning with Parole media player, 安装 gst-libav包.