Logo ©1994-2007 Kevin Boone
My professional interests
Computing
Law
Education
Science and research

My leisure interests
Martial arts
Heritage railways
Garden railways
Motorcycles
DIY

Downloads
Linux downloads
Windows downloads
Java downloads
Perl downloads
Home automation downloads

About me
Home & family
My CV

Site info
Contact the author
Download policy
Keyword index

  Home > Computing > Linux > Archos PMA430 (and other Archos AV) stuff > QMPlayer

QMPlayer release notes

Last modified: Fri Jul 8 12:12:00 2005

PMA430 port of mplayer
Version 0.01, July 2005
PMA430 code (c)2005 Kevin Boone

WARNING

This is work in progress. Before doing anything with this software, please refer to the project status page to see what works and what doesn't.

What is this?

qmplayer is first attempt at a port to the Archos PMA430 of the popular Linux media player MPlayer. In essence, it is a Qtopia user interface shoe-horned into the basic MPlayer console-mode code, a driver for the PMA framebuffer/image scaler hardware, and some modifications to work around bugs in the PMA audio driver.

MPlayer is a good choice for a general-purpose player, since the range of codecs available is absolutely enormous. In addition, unlike the built-in Archos media play it is stream-based, not file-based; this means that it doesn't care whether media data comes from a local file or a network source. However, most work has been done on the PC platform, and many of the MPlayer codecs don't yet work on the ARM architecture. To this problem must be added the complication that the PMA has an exceptionally slow CPU. These factors make it extremely challenging to get a workable implementation of mplayer on the PMA.

Command-line and GUI operation

qmplayer and mplayer are the GUI and command-line versions of the program respectively. All the standard mplayer command-line arguments still work with the GUI version, but some of them will not make sense, and many will break the program. If you launch the program from the launcher icon, it actually runs the command qmplayer -vo pma430 -framedrop -quiet If you try to play video files in command-line mode, it will most likely crash; it won't work, that's for sure.

Please bear in mind that mplayer is primarily a command-line Unix application; qmplayer is merely the same with a minimal Qtopia GUI wrapped around it. Most of features possible in command-line operation do not exist in the GUI version (yet).

Streaming support

qmplayer can stream over HTTP. In principle, it can stream over MMS and RTSP, although I have not got this working yet. It can stream ordinary files, by entering an HTTP URL to the server, e.g.,:
http://myserver/media/song.mp3
It can also stream Shoutcast and Icecast MP3, as used by many commercial broadcasters. In the GUI, select Playlist|Add URL, and enter the full URL in the box.

Full-screen mode

QMplayer does not attempt to scale video to fit the Qtopia user interface. To see the whole image, you'll need to put it into full-screen mode. Just tap anywhere in the playback window to go full-sceen, and the same again to restore the user interface.

Playlist file support

qmplayer recognizes some playlist file formats. However, the fact that the playlist file can be read properly does not mean that qmplayer will necessarily be able to play the media referenced in the playlist.

In general, popular playlist files do not have well-defined identifiers that allow them to be positively identified as such. There is, therefore, a risk that qmplayer will attempt to play a playlist as a stream which, of course, won't work. On the command line, you can force qmplayer to treat an unknown file as a playlist, by specifying the -playlist switch. This is the best way to integrate qmplayer into Opera for handling Shoutcast streams (see below).

In the GUI, any file with extension .m3u, .pls, .asx, or .smil is treated as a playlist. All URLs, rather than files, are assumed to be playable streams, not playlists.

Integration with Opera

qmplayer can play streams defined in ShoutCast playlist (.pls) and M3U files. Most websites that provide access to ShoutCast streams do so by linking to one or more .pls files. To play .pls and .m3u files from a browser, you will need to enable Opera to invoke qmplayer when you select these files. From the Opera `Preferences' menu, select `File types'. Click the button `Add new MIME type'. For the type, enter `audio/x-scpls'. Then choose `Use external program', and enter the program name and arguments:
qmplayer -playlist
Do the same for `audio/mpegurl'. The click `OK'. That should do the trick.

Please note that you can, in principle, associate MP3 files and other media types with qmplayer in Opera. However, this by itself won't give you streaming capabilities, because Opera will attempt to download the whole file before invoking the helper application.

Disaster recovery

If qmplayer locks up -- and it might, if it tries very hard to play something it isn't equipped for -- you can forcibly terminate it at the console. Open a console and enter the command:
#killall -9 qmplayer

Limitations

PLEASE READ THIS BEFORE DOING ANYTHING :)
  • qmplayer will not play anything that mplayer cannot play. In fact, it can play fewer media types than the PC version of mplayer, because on a PC mplayer can take advantage of codecs implemented as Windows DLLs. On the PMA430 this is not possible -- it's not the same CPU
  • The colourspace conversions built in to mplayer are too accurate (i.e., slow) to work on the PMA. Most codecs output image data in YV12 format. I have codec a much faster implementation of a filter to convert this into the YUV422 format that the PMA requires. The same treatment will be necessary in due course for all the standard colourspace formats commonly encountered, but this is a long job. In practice, must codecs use YV12
  • This program can be used to write streams to disk, but please don't e-mail me to ask how. I have not been mean enough to take this feature out, but I'm not going to involve myself in copyright-breaking activities. Read the main mplayer documentation.
  • There is no support for HTTP proxies in the GUI. None at all. If you normally need a proxy to get to the Internet, forget it (for now -- it's on the to-do list). mplayer itself does support proxies, so you can get proxy support by running qmplayer from the console:
    # export http_proxy=myhost:myport
    # qmplayer & 
    
  • Don't expect to be able to do anything else with the PMA while using this program. Some limited multitasking is possible while playing low-bitrate audio streams, but with high-bitrate streams, playback will be badly affected -- even with all the code optimised to reduce CPU load, this program generally consumes at least 50% of the available CPU throughput just for audio playback.
  • Changing streams or files is not a fast operation. Among other things, the new stream has to be pre-buffered to allow for intermittent transmission. This will usually take a second or two, but can take ten seconds when using HTTP.
  • The Opera browser does not invoke helper applications through Qtopia -- it does it by invoking the Linux shell directly. This is a bad thing for qmplayer, because like all Qtopia applications it doesn't get a taskbar icon when it is launched this way. This means that if you switch to a different application while qmplayer is running, you won't be able to get back. I should stress that this is a consequence of the way Opera works, and not something that can be corrected in qmplayer. If you use this software to play a .pls file through Opera, for example, make sure you close qmplayer before switching back to Opera or another application. If you forget, there is a last desparate measure you can take, which is to shutdown qmplayer from the console as described above.
  • There is no support for ID3 tags or any clever way of organizing content. If you have 5,000 MP3 files in a single directory, qmplayer will fall over whilst trying to fit the directory into a listbox. I don't propose to fix this -- ID3 is a peculariarity of MP3 files, and qmplayer sets out to be a general-purpose player.
  • The user interface has a number of qwirky features
    • To add all the files in a directory, you need to open up the directory as if you were going to select a file in it -- highlighting the directory name won't do
    • To open a directory in `add directory' mode requires two clicks, while one click will do in `add file' mode

Known bugs

00001 qmplayer shuts down if a file is added to the playlist while
      playback is paused. Workaround: stop playback before adding
      files
00002 Playback stops while files are being selected to add to the
      playlist

Legal stuff

There is no warranty! I can't promise that this software will work for you. Like most software developers, I instinctively test my programs in ways which I know won't reveal any faults. I can't even promise that this software won't break your PMA. It hasn't broken mine, but I might just be lucky.

qmplayer is distributed according to the GNU Public Licence. In short, you may do whatever you wish with this code, provided that the original authors continue to be acknowledged, and source code is made available. If you would like the source code for this software, please ask me. Please send bug reports, suggestions for new features, etc., to me.

   
Search

WebThis site

Shameless plug

By the author of this site. Buy on-line from Amazon USA | UK

Editorial
So you want to be a university lecturer? Read this first!

Speak like your boss: new developments in managerese

Computing features
File handling in the Linux kernel: an in-depth look at how Linux handles files, filesystems, and file I/O

All sorts of Linux stuff

Confused about CLASSPATH? answers are here

First steps in EJB using jBoss (recently revised for jBoss 3.2)