Tuesday 28 February 2023

Returning to Music Player Daemon - Cantata vs Mpdevil

A while ago I tried Music Player Daemon (MPD) with my music, but found it wouldn't see half my collection and I gave up on it. That was a long time ago so I recently decided to try it again to see if it had improved and also I have recently been getting annoyed with usual music players, Clementine and Strawberry. Clementine is basically no longer maintained but it's one of few players that can cope with 80 thousand tracks! And it has a nice Android app to control it from my phone. But it's got some annoying bugs that will never be fixed so I have been trying to look for alternatives. Strawberry is a fork of Clementine but doesn't fix the bugs that bother me and there's no Android app for it, so I decided to give MPD another go since I haven't tried MPD for years.


This time when I installed MPD, I made sure it ran properly as my user rather than its own user, with the config in my Home folder. And this time it seems to see all my collection, and has clearly improved since I last tried it.  I used the brilliant guide on the Arch wiki and adapted it for KDE Neon (a distro of sorts based on Kubuntu but with latest KDE). Most of the guides I used before were for Ubuntu but usually they would create an MPD user, which is where the problems had begun.  Apart from setting the music directory, I have enabled Replaygain for audio normalisation. The sound was also distorting slightly on my desktop machine without Replaygain enabled. I haven't yet worked out how to make MPD run on startup in KDE, I usually just run it in my favourite drop-down terminal, Yakuake. Edit: you can set mpd to run automatically by adding it as a service with this command: systemctl --user enable mpd.service

The great thing about MPD is it runs in the background consuming very little resources, and then you control it with a front-end of your choice, either lightweight or heavy and control it from anywhere on the local network. At first it had problems choosing the right soundcard, as I use a USB interface, but changing it to use Pulseaudio instead of ALSA fixed that. One slight annoyance with MPD is it does not remember the previously played track or playlist the next time MPD is started.

This time round, after looking round at other front-ends, I ended up choosing Cantata as it seemed to be the best of thea KDE friendly apps, it works well  apart from the 16,000 track limit on playlists is a bit annoying. I have now got into a habit of just listening to albums in full or all of one artist etc, whereas in Clementine I would just have all my 80,000+ in a single playlist on Shuffle! 

I then discovered Mpdevil, which although a fairly simple player, it looks more modern than Cantata. I have Mpdevil running nicely on my main desktop and my main laptop, both are running KDE Neon (a distro based on Kubuntu but with the very latest KDE version). I also have MPD on my old Dell Vostro, which runs Manjaro,

One very noticeable difference between the two is that Cantata has a "locate in Library" option in the right click menu whereas Mpdevil only has the option of "Show" which locates the track in the file manager which is far less useful to me. I usually want to find the album a track is from and play it. 

Mpdevil 'Show' which opens a location in a file manager

Cantata 'Locate In Library' which shows where the track is in the app.

One other thing I really like in Cantata is it's easier to find and switch between MPD servers in the settings with it's Discover button. It isn't as simple to do that with Mpdevil. 

Mpdevil is basically a more minimal player, it lacks Last.fm support and, as far as i can tell, doesn't fetch missing covers, whereas Cantata has both of those features. As far as I know, there isn't an easy way to get Scrobbling in the MPD backend itself so it's useful to have that in the front-end. If you want a great looking player and don't need advanced features, mpdevil does the job fine but if you need the advanced features, Cantata does a better job, so I will stick with Canatata for now. I am open to suggestions though for an even better KDE-friendly MPD client.