media-player


configurating the media-player

To configure the media-player you open the file etc/mediaplayer.conf in a text-editor.
You'll be presented with multiple entries in the format of
config NAME="VALUE"
The media-player knows 3 internal players that can play different files.
The default-player used JMF and needs not be configured. If that failes you can configure 2 commands for the CmdLnPlayer, that starts an external program and gives it a URL as a command-line-option and/or StreamCmdlnPlayer that starts an external program and writes the content to play to the stdin of that program (pipes the data).
The default-configuration in mediaplayer.conf uses /usr/bin/mpg123 that is found on many Linux and Unix/MacOS-X boxen to play files that cannot be played by JMF (e.g. because JMF is not (correctly/fully) installed).
You can also add macros that can be entered instead of while file-names/URLs. These macros have the format:
config jaugment2.mediaplayer.MediaPlayerService.macro{NUMBER}="{MACRONAME}->{URL}"
With the first number being 0 and all no "holes" in the numbering.
Also a default-playlist can be configured and if that playlist shall be played automatically uppon startup of the service.

playing media

Uppon starting the media-player you are presented with a (presumably empty) playlist and a number of buttons. To add a media you may enter a path or URL and press the button "add" next to it or press the button "add..." and select one or many local files.
To remove an entry, select it in the list and press "remove".
To play a single entry, just select it in the list and press "play".

recording media

Uppon hitting "record" you are presented with the recording-panel.
At the top of it you can select the recording-device or "from file".
If you select "from file" you don't need to select a format but for a device you need to select the desired format in the (now filled) combo-box below before you can begin recording.
Now just enter an output filename (the format will be guessed from the file-extension such as avi or wave)
After hitting record you'll be asked for the input-file if you selected "from file". Anyway you'll get a preview and a (device-dependent) control-panel for controlling the recording, if the device supports any of that.
If the format is not supported or input and output -format cannot be translated into each other by JMF you'll get an error-message on the console and in the error.log (and maybe a detailed explanation in a new file names jmf.log).

media database

You can add files to a media-database by selecting that action with the right mouse-button in the directory-service.
All information such as ID3-tags about that file(s) will thenb be indexed and can be searched in the media-player by hitting "mediaDB" and entering a search-expression.
The expression in a LDAP-regular-expression and the example presented should give you a fairly good understanding how such an expression is constructed.
The searchable fields are "genre", "cn"=common name, "filename" and the attributes you see in the directory service such as "album", "artist", "comment", "title", "track" and "year".