GStreamer
GStreamer is a pipeline-based multimedia framework written in the C programming language with the type system based on GObject.
GStreamer allows a programmer to create a variety of media-handling components, including simple audio playback, audio and video playback, recording, streaming and editing. The pipeline design serves as a base to create many types of multimedia applications such as video editors, streaming media broadcasters, and media players.
Designed to be cross-platform, it is known to work on Linux (x86, PowerPC and ARM), Solaris (Intel and SPARC), macOS, Microsoft Windows and OS/400. GStreamer has bindings for programming-languages like Python, C++, Perl, GNU Guile (guile), and Ruby. GStreamer is free software, licensed under the GNU Lesser General Public License.
Installation
Install the gstreamer package.
To make GStreamer useful, install the plugins packages you require. See official documentation for list of features in each plugin.
- gst-libav - Libav-based plugin containing many decoders and encoders.
- gst-plugins-bad - Plugins that need more quality, testing or documentation.
- gst-plugins-base - Essential exemplary set of elements.
- gst-plugins-good - Good-quality plugins under LGPL license.
- gst-plugins-ugly - Good-quality plugins that might pose distribution problems.
- gst-plugin-libde265AUR - libde265 plugin (an open h.265 video codec implementation) for gstreamer.
Integration
PulseAudio
PulseAudio support is provided by the gst-plugins-good package.
KDE / Phonon integration
See Phonon.
Hardware video acceleration
See Hardware video acceleration.
GStreamer will automatically detect and use the correct API [1]. Depending on the system install:
- gstreamer-vaapi for VA-API support.
- gst-plugins-bad and nvidia-utils for NVDECODE/NVENCODE support.
Ignore driver whitelist
GStreamer uses a whitelist of VA-API drivers. To ignore the whitelist and allow support for other drivers like intel-media-driver, set GST_VAAPI_ALL_DRIVERS=1
as environment variable.
Verify VA-API support
To verify VA-API support:
$ gst-inspect-1.0 vaapi
Plugin Details: Name vaapi Description VA-API based elements Filename /usr/lib/gstreamer-1.0/libgstvaapi.so Version 1.16.2 License LGPL Source module gstreamer-vaapi Binary package gstreamer-vaapi Origin URL https://bugzilla.gnome.org/enter_bug.cgi?product=GStreamer vaapijpegdec: VA-API JPEG decoder vaapimpeg2dec: VA-API MPEG2 decoder vaapih264dec: VA-API H264 decoder vaapivc1dec: VA-API VC1 decoder vaapih265dec: VA-API H265 decoder vaapipostproc: VA-API video postprocessing vaapidecodebin: VA-API Decode Bin vaapisink: VA-API sink vaapih265enc: VA-API H265 encoder vaapih264enc: VA-API H264 encoder 10 features: +-- 10 elements
Verify NVDECODE/NVENCODE support
To verify NVDECODE/NVENCODE support:
$ gst-inspect-1.0 nvcodec
Plugin Details: Name nvcodec Description GStreamer NVCODEC plugin Filename /usr/lib/gstreamer-1.0/libgstnvcodec.so Version 1.18.2 License LGPL Source module gst-plugins-bad Source release date 2020-12-06 Binary package GStreamer Bad Plugins (Arch Linux) Origin URL https://archlinux.org/ nvh265enc: NVENC HEVC Video Encoder nvh264enc: NVENC H.264 Video Encoder nvvp9dec: NVDEC vp9 Video Decoder nvvp8dec: NVDEC vp8 Video Decoder nvh265dec: NVDEC h265 Video Decoder nvh265sldec: NVDEC H.265 Stateless Decoder nvjpegdec: NVDEC jpeg Video Decoder nvh264dec: NVDEC h264 Video Decoder nvh264sldec: NVDEC H.264 Stateless Decoder nvmpeg4videodec: NVDEC mpeg4video Video Decoder nvmpeg2videodec: NVDEC mpeg2video Video Decoder nvmpegvideodec: NVDEC mpegvideo Video Decoder 12 features: +-- 12 elements