[MPlayer-users] Cache empty, consider increasing -cache and/or -cache-min. [performance issue]

Erik Auerswald auerswal at unix-ag.uni-kl.de
Thu Oct 23 19:44:00 CEST 2014


On Thu, Oct 23, 2014 at 04:14:49PM +0100, Jim Cross wrote:
> Thanks for the detail and correction Erik. Trying again I get the 'Cache
> empty' messages and does not play as copied further below.

I have just checked with the mplayer provided by Ubuntu 14.04, that results
in stuttering noise and a non-responsive MPlayer. It seems as if the Debian
and Ubuntu provided mplayer binaries are not up-to-par. :-(

> My user config file contains:-
> noar=yes
> nomouseinput=yes
> nolirc=yes
> nojoystick=yes
> noconsolecontrols=yes
> ao=alsa,pulse,sdl:aalib

You might try pulse in preference to alsa iff you use PulseAudio, e.g.
because of some desktop environment installation.

> There are a couple of considerations I have:
>  - I am working with this software on a raspberry pi and have written
> python code to scrape web sites for their playlists and/or webcasting
> URL's. Most data I get back plays well with MPlayer without using 'wget' -
> I would like to keep to this method.

That model should work™, IMHO there is bug (or missing feature) in the HTTP
code used by MPlayer. Using wget is a working around this limitation.
However, I am not familiar with that code and don't have any idea where to
start looking for the problem or how to fix it. :-(

>  - I am new to linux, MPlayer and the such and have no experience in
> 'building' apps (such as MPlayer) using the latest version especially to a
> raspberry pi and its CPU - Not sure where to start or if latest MPlayer
> version would work on a RPi.... Anything more than 'sudo apt-get install
> mplayer' is beyond me at the moment :(

IMHO you should consider learning how to build software from a development
repository. Using the Pi to compile MPlayer will take quite some time, but
it is probably easier than setting up a cross-compilation environment. The
current MPlayer should compile and work on a Pi AFAIK. I don't have a
Raspberry Pi and have never tried building MPlayer for it, so I might be

For a native compilation on a Debian based system you would do the

# install prerequisites
sudo apt-get install build-essential
sudo apt-get install subversion
sudo apt-get install git
sudo apt-get build-dep mplayer

# check out MPlayer
svn checkout svn://svn.mplayerhq.hu/mplayer/trunk mplayer

# configure MPlayer -- this will checkout ffmpeg via git as well
cd mplayer

# build mplayer

# run MPlayer

> $ wget -q http://ai-radio.org:8000/radio.opus -O- | mplayer -cache 320 -
> MPlayer svn r34540 (Debian), built with gcc-4.6 (C) 2000-2012 MPlayer Team
> Playing -.
> Reading from stdin...
> Cache fill:  0.00% (0 bytes)
> libavformat version 53.21.1 (external)
> Mismatching header version 53.19.0
> libavformat file format detected.
> [ogg @ 0xb64c0ee8]Codec not found

This seems to be the next problem to fix. Perhaps the used codec was not
supported by MPlayer resp. ffmpeg at that time. The codec in question is

[lavf] stream 0: audio (opus), -aid 0, OPUS 64KB

Additionally, there is a video codec in the stream:

[lavf] stream 1: video (png), -vid 0

Perhaps that combination was not supported back in 2012?

Since this works with a current MPlayer, you should consider obtaining a
newer version. If the HTTP bug is fixed in MPlayer, you will need to do so
as well, because it takes quite some time for newer program versions to
enter the Debian (or another) GNU/Linux distribution. Especially since
MPlayer has been dropped from Debian/Jessie.

[T]hat idiotic "use html by default even for text" is just crazy.
                        -- Linus Torvalds

More information about the MPlayer-users mailing list