User Tools

Site Tools


Configuring DeadBeef

1.0 Introduction

Let's start by being honest: “DeadBeef” is a stupid name for a music player/manager! It is equivalent for schoolboys of a certain age to have called something '55378008' because …for reasons! For the record, then: 'DeadBeef' is so called because it's an example of 'Hexspeak' and is specifically a 'Magic Debug Number'. However, the relevance of that to a music player still escapes me, so let's just agree to agree that it's a stupid name!

Even worse is that, if you stuck by the spelling rules the developers have decided upon, this article should be all about an audio player called “DeaDBeeF”. But I point-blank refuse to capitalise like that, so throughout this article, you'll be reading about something that only contains two capital letters! Ugh!!

What DeadBeef isn't, however, is a rubbish music player/manager. Quite the contrary: it's one of the best I've ever found for Linux (I think its nearest competitor would be Clementine, which is a big, heavyweight Qt program that, last I heard, was struggling to survive as a live development project, leading to it being forked into the **Strawberry** music player project… yet another dumb name, I fear… only this time, one with questionable website design taste, too!)

DeadBeef is fast, relatively low resource consumption, does gapless playback by default and, most importantly for me, is very, very flexible and configurable. It is Linux's equivalent to Foobar2000, which at one time started life as a very bare-bones player that had to be configured up the wazoo before it turned into something highly usable. DeadBeef is the same sort of beast: out-of-the-box, it's not got a lot to recommend it, but with a few bits of post-install configuration, it can become very usable indeed.

What follows, therefore, is my recipe for turning DeadBeef into a highly competent classical music player. I'm sure it won't appeal to everyone, but along the way, hopefully you'll pick up the skills needed to make it work more like you want it to -so the article won't have been wasted anyway!

2.0 In the Beginning...

Installing DeadBeef is non-trivial for a lot of Linux distros, since it appears not to be a standard part of most distros' standard repositories …so I am afraid you will probably have to compile from source.

First, check what the latest version of the software is: visit their sourceforge software respository and look for the latest version in the list of 'static files' they present there. At the time of writing, it's 0.7.2-2 -but take a fresh look and replace that version number in what follows with whatever is the latest version when you go look.

With that version number to hand, installation goes as follows:

wget$(echo $FULLVERSION)_x86_64.tar.bz2
tar xjvf DeadBeef-static_$(echo $FULLVERSION)_x86_64.tar.bz2
sudo mv DeadBeef-$(echo $SHRTVERSION) /usr/bin/DeadBeef-$(echo $SHRTVERSION)
sudo ln -sf /usr/bin/DeadBeef-$(echo $SHRTVERSION)/DeadBeef /usr/bin/DeadBeef

Once all that's done, you just type /usr/bin/DeadBeef at the command line to run the program. That's also the command tocreate shortcuts in whatever launchers, panels or start menus you use. For example, in Gnome 3 (as tested on both Fedora 30 and Ubuntu 19.04):

gedit ~/.local/share/applications/DeadBeef.desktop

Then add:

[Desktop Entry]

…and save the modified file. Now you can click Gnome's Activities → Show Applications menu options and DeadBeef will be listed as an application on the system. If you then right-click the application icon, you can select 'Add to Favourites' to pin it as an application icon in the 'side dock' that Gnome uses as a quick-launch panel:

What you get when you first launch the program will be something similar to this:

It's bare, it's barely there and it's barely usable… but it's easily fixed! So let's see how to do that now.

3.0 Adding Some Music

To begin with, you should start by adding your music collection to DeadBeef's default playlist. If we assume that you know where your music files live, all you need to do to achieve this is click the File → Add folder(s) menu options and then point DeadBeef to the folder which represents the root of your music collection.

For example, let's say I store my music in /home/hjr/Music, a folder which then contains a bunch of other folders, each of which contains music by different composers, like so:

In that case, here's me pointing DeadBeef to the 'root' of that folder tree:

Very quickly, DeadBeef populates its default playlist with data about the music files it has discovered in that folder structure:

One of the really nice things about DeadBeef, in fact, is just how fast it adds over 1TB of FLAC files from my 'real' music collection (the one in the screenshots is a tiny subset of it, used for illustration purposes only). I believe it's got something to do with DeadBeef being written in C, which makes it really fast and efficient at everything it does. Whatever the reason, it beats waiting the many minutes -or even hours- that other Linux music managers usually take to do this job!

3.0 Tweaking Metadata Display

So now DeadBeef is displaying your music… but the display is a bit rubbish! The columns are all squished up, hiding most of the important information. So, start by click-and-dragging the little vertical dividers between the column names to make them wider:

You can now see that, by default, DeadBeef displays a single aggregated column called “Artist/Album”, which actually displays the Album and Artist metadata (as harvested from the music files' tags), squished into a single column. Now, it's not a bad thing to use Artist and Album as the 'sorting hierarchy' of your music data, but displaying both bits of information in a single column is not such a great idea: it means you can never sort your tracks just by Album name, for example, so that all Requiems are listed together (say).

So, I like to right-click the line where all the column names are listed. A pop-up menu appears, as shown in the previous screenshot, and this lets you add or remove columns from the main display at will. To begin with, click [Add column]:

In the new pop-up that appears, type 'Artist' (or, even better, 'Composer') as the column Title, and then select 'Artist' as the Type from the drop-down list of options presented. The rest of the fields can be left as-is, so just click [OK] to finish.

Repeat the same [Add column] process to add a new column called 'Album' (or, even better, 'Composition') and selecting the 'Album' data type for its contents.

You should now see something similar to this:

…which shows the concatenated Artist/Album column we started with at the left of the screen and the two separate columns I've just added to the mix. There's no point including the concatenated data when we've now got the individual columns to work with, so that last screenshot also shows me right-clicking the Artist/Album column header and selecting [Remove column] from the context menu that appears. The aggregated column is then removed from the display:

But remember, sorting your data by Artist and Album makes perfect sense -it was only displaying the two bits of data as one thing that was less than sensible. So in that previous screenshot, I've also right-clicked the column headings once more and selected Group by → Custom in the context menu:

Here, I'm specifying a “Group By” function that certainly alter the grouping or sorting of the music tracks, but without actually being displayed in its own right. In my case, I've typed in the custom grouping string %artist%-%album%… which is, effectively, the aggregated column's contents I just stopped from being displayed as a column on the main display. In essence, I've created a 'virtual column' which is invisible, but whose contents will still govern or control the way the 'real columns' are displayed.

Where did I get the “%artist%-'%album%” string from? By consulting the Foobar2000 Formatting Reference web page. This lists every metadata tag you can have, and the way it can be referenced in things like column headings or custom sorting/grouping 'virtual columns'. The fact that DeadBeef uses the same formatting for metadata as Foobar2000 is one of DeadBeef's crowning glories, in fact! Currently, only a relatively small subset of the functions listed on that page work -so you can't create a column whose content is based on “$len(%title%)”, for example, because the $len function is currently non-functional… but, allegedly, more and more of the Foobar2000 functionality will be coming across to DeadBeef in the future, which is defintiely a “good thing” :-)

Anyway, once you click [OK] to submit your custom grouping function, DeadBeef's display changes quite fundamentally:

Once you see your data in this format, it makes sense to once more click the column headings, select to Add a new column and this time, point to the Album Art entry:

The result is something like this:

…which starts to resemble something usable and attractive. (If I'm being picky, and having at least third thoughts on the subject, I think I'd drop the Artist column altogether at this point, as it's obvious from the grouping titles what composer is associated with each 'album' of music).

But it's a lot better than we started with, anyway!

4.0 Design Mode Changes

The next step to tweaking DeadBeef can look a tad drastic, but if you keep your cool, it eventually makes sense. First, we switch on DeadBeef's Design Mode: click View → Design Mode.

Now, when you right-click on any part of the main DeadBeef display, it will turn bright blue and a context menu will appear. The thing you right-clicked on will accordingly appear no longer to exist. Don't panic when this happens!

So, first, in Design Mode, right-click the playlist area (there's no need to be very specific about it; just right-click whilst hovering your mouse cursor over some track or other of an album):

The main display area in this screenshot has turned blue and a menu has appeared. I've select Replace with… and then the Splitter (left and right) menu options:

Now things turn grey and there's a faint vertical line which represents the point where left and right-hand parts of the screen are separated. Now right-click in the left-pane of this display:

Again, that component of the display will turn blue and from the context menu you can now select Insert → Playlist. At this point, the re-formatted playlist you'd achieved earlier re-appears, but this time constrained only to the left-hand side of the right-left splitter:

Moving to the right-hand pane, I once more right-click and this time, I ask to insert a top-bottom splitter. In the top part of the right-hand pane, I then do yet another right-click followed by Insert → Tabs:

A 'tab' is a panel which will fill that top-part of the right-hand side of the display. It will, by default, contain three empty tabs, each labelled 'placeholder'. You can click on each placeholder label in turn and again right-click and select to insert some new component. For example, in the above screenshot, I've clicked on the first 'placeholder' tab to select it, then right-clicked the blue area to request to insert an 'Album art display' component. Once that's confirmed, and I select a track from the left to play, this happens:

That is, the tabbed panel correctly displays a large version of the album art associated with the playing track. Note that the name of the tab is displayed as 'coverart', which is the default name when you select to insert Album art. If you, like me, are allergic to all-lower-case and one-word versions of things which ought to be two words, feel free to right-click the tab title and select Rename tab from the context menu:

Type in whatever properly-capitalised and -spaced words you prefer to see as your tab name and press [OK}. The display will update to show your user-supplied name.

Now right-click the other two tabs in turn. What you choose to insert into each is up to you. In the second, I'm selecting to insert a 'Spectrum':

In the third, I add a 'Scope' (and I then rename the tab to be called 'Oscilloscope'):

That last screenshot also shows that I've right-clicked the bottom quadrant of the screen and added a 'Selection Properties' component, so that the lower-right of the screen will always display detailed tag information about whatever track happens to be playing at the moment.

Your choice of tabs and content is entirely up to you: the one's I've mentioned are the one's I started with and quite liked, but if you are not into oscilloscopes or track properties, you can obviously elect to not switch those components on in the first place.

When you're happy with the various components you've loaded into DeadBeef's display, don't forget to switch out of Design Mode by clicking View → Design mode once more, until the check-box next to that menu item is empty.

5.0 Plug-ins

The built-in Spectrum Analyser and Oscilloscope that DeadBeef ships with leave quite a lot to be desired, I think! They provide a minimum level of functionality, but no great finesse!

Fortunately, DeadBeef is extensible by means of adding new Plugins to it. Visit the project's website to find the list of available plugins. I personally would recommend the Musical Spectrum one, but I don't have a lot of use for many of the others. It means my real music player's spectrum analyser looks like this:

…which is (I think!) a lot nicer to look at than the original.

Installing these plug-ins appears to be quite tricky, since the various' author's websites linked to from the DeadBeef plugins page often mentions needing to compile things and then run shell scripts. In fact, it's a lot simpler than that!

For example, click on the 'x86_64' link for the Musical Spectrum item and your browser will prompt to download a file called Save that somewhere and then extract the contents. You'll end up with a couple of files in a “plugins” directory, like so:

At the command prompt, you just need to copy those files over to DeadBeef's plugins directory, which in the case of version 0.7 and on Arch, is found in /usr/lib/deadbeef (note that 'deadbeef' is all in lowercase there!). Other distros and other versions may store things differently. In my case, therefore, I needed to do:

sudo mv /home/hjr/Downloads/plugins/*.so /usr/lib/deadbeef

Back in DeadBeef, you then just click Edit → Preferences → Plugins and the new plugin should be listed. Be prepared to hunt around a bit, though, as they don't appear to be listed in any particular order! My new 'Musical Spectrum' plugin got listed after 'Shorten player' and before 'VU Meter', for example …so it's clearly not an alphabetical listing!

6.0 Scrobbling

One plugin I think deserves special mention, though it's not to everyone's taste. I've been 'scrobbling' my music listening habits to since 2008 and I find it very helpful to know which composers I've been neglecting, which I've been over-listening to, and which compositions of a composer's I've been enjoying or ignoring. Therefore, I require every music player I use to transmit my music listening habits to

DeadBeef does have this functionality, courtesy of a plug-in:

You just need to find the plugin in the usual list, click [Configure], enable the scrobbler by clicking on the appropriate check-box and then supply your standard username and password combo. Three other options can then be used to fine-tune your scrobbling experience. In my music files, Album Artist should always be the same as Artist, so that option is of no consequence for me. I don't know what a MusicBrainzID is, but I don't want to use one anyway, so I switch that option off. The option to submit when tracks shorter than 30 seconds are played is one I didn't think would be needed -but it turns out that one of my recordings of Rachmaninov's Rhapsody on a theme of Paganini does have a number of tracks which are shorter than that, so I switched it on. But I don't think one would normally want to do that, to be honest.

Anyway: click 'Apply' and you should be good to go.

7.0 Minor Tweaks

There are a couple of other little refinements I add to my DeadBeef:

For starters, I like the player to minimise to the system tray when I click to close it, rather than for it to actually close.

Additionally, I like to tweak the content of the 'Titlebar'. By default, it doesn't (for example) tell you what Album is playing. So I revert back to my Foobar2000 tag formatting variables to tweak the titlebar display as you see here. Note that the “$num” function works fine to turn a single-digit track number as fetched from a track's metadata (say, track '4') into a two-digit, zero-padded equivalent (i.e., '04').

By default, If you've got a list of music that runs something like:

Britten - Album 1 - Track 1
                    Track 2
	            Track 3
        - Album 2 - Track 1
                    Track 2

… then if you start by playing Britten Album 1 Track 1, DeadBeef will continue playing everything right up (in this simple case!) to Album 2 track 2. It will, in other words, play through every piece of music in your library (or, rather, listed in your playlist -which currently is the same thing, of course) until you stop it. Personally, I prefer to play an 'album' (which in the world of classical music really means 'composition' or 'work', remember) and then stop. I don't want Strauss's 'Four Last Songs' to be followed by anything, just because its listed after them, basically!

Fortunately, the default behaviour is easy to alter: click the Playback menu and work your way through the various options there. I want linear ordering, for example, since it makes no sense to play movements of a symphony in a random order! For similar reasons, I don't loop at all, since I find there's no point in replaying the entire Wagner Ring the second it's finished!

To then stop the 'play everything until the end of the list' behaviour, you just switch on the option to Stop after current album. With that switched on when I play Album 1 - Track 1, in the earlier example, you'll find that no music at all plays after Album 1's Track 3 has concluded.

Finally, if you've installed the Musical Spectrum plugin I mentioned back in Section 6, be aware that you can right-click it at any time and choose to re-configure it. I find the following settings give the best-looking results, for example:

In particular, I find it necessary to bump the 'dB range' up to 120 and the FFT size to 32768 in order to prevent a large area of blank space happening at the right-hand side of the spectrum analyser's display. As ever, your mileage may vary.

8.0 Audio Conversion

I will ordinarily always listen to my music in FLAC format, since it's lossless and thus 'bit perfect', with no loss of audio/musical signal as compared to the original CD. But if I'm going on holiday, I might want a few tracks of something to be copied onto my phone or tablet, so I've got something to listen to on the flight. Given it's a noisy airplane ride and I've probably had a few vodkas en route, audio fidelity is not so important -but the phone's lack of storage space is! Therefore, I sometimes want to convert my FLACs into equivalent MP3s.

DeadBeef has that functionality built-in, which is very handy. Just select multiple tracks, right-click and select Convert from the context menu:

Various options are then presented to you, the most important of which is probably the choice of 'Encoder' (allowing you to output as WAV, MP3, OGG and what have you). Once you click [OK] on that screen, the file conversion begins:

…and at the end of it, you'll have a set of MP3s sitting in a duplicate folder structure as the source FLACs possess. It's a handy feature!

9.0 Conclusion

Well, that's an end for now to this brief tour of the delights of DeadBeef. Stupid name, great music player/manager! I look forward to more Foobar2000 functionality being imported to DeadBeef in future releases; in the meantime, it's already highly customisable, it's fast and its ability to use any Foobar2000 formatting at all, even just a small subset of it at the moment, makes it a highly desirable bit of software real estate in my opinion! I find it very suited to being my main Classical music listening tool these days: something very few media players can have said about them, in my experience!

I commend it to you, and hope you have fun knocking it into usable shape for yourself.

wiki/linux/deadbeef.txt · Last modified: 2019/06/03 15:54 by dizwell