Last Updated on August 11, 2021
Over the past few months, I’ve written lots of reviews of open source audio software, focusing mainly on music players. Linux has a mouthwatering array of open source multimedia tools, so I’m going to turn my attention wider afield from music players. Let’s start with some multimedia candy.
GLava is an OpenGL audio spectrum visualizer for Linux. An audio visualizer works by extracting waveform and/or frequency information from the audio and feeds this information through some display rules, which produces what you see on the screen. The imagery is usually generated and rendered in real time and in a way synchronized with the music as it is played.
GLava makes a real-time audio visualizer appear as if it’s embedded in your desktop background, or in a window. When displayed as the background, it’ll display on top of your wallpaper, giving the appearance of a live, animated wallpaper.
GLava is a simple C program that sets up the necessary OpenGL and Xlib code for sets of 2D fragment shaders. The software uses PulseAudio to sync the desktop visualizer with any music source.
You might find a package for your favorite distribution. GLava is available in the Arch User Repository if you use Arch Linux or one of its clones. But compiling the source code is very straightforward. Simply type the following commands at a shell.
$ git clone https://github.com/wacossusca34/glava
$ cd glava
$ CFLAGS="-march=native" meson build
$ ninja -C build
$ cd build
$ sudo meson install
On my Arch system, I didn’t need to install any packages first. But under Ubuntu 18.04 the software didn’t compile complaining about “missing meson.build:74:1: ERROR: C library ‘Xrender’ not found”. You can fix any compiling problems by ensuring you have the necessary packages with:
$ sudo apt-get install libpulse0 libpulse-dev libxext6 libxext-dev libxrender-dev libxcomposite-dev meson gcc
To configure the software, you’ll need to manually edit files with a text editor, as nothing can be modified from the application itself. First, copy the default configuration files to ~/.config/glava. This is actioned by running
The ~/.config/glava directory is now populated with .glsl files, including the configuration file rc.glsl. Open that file with your preferred text editor. The file is fairly well documented. Here you can enable or disable window hints, use native, xroot or no window opacity, specify the window background color, and a lot more besides.