Hi, just some time ago I noticed that MPlayer uses a lot of environment variables, almost none of which are documented. Here's a list of them, ordered by the place they appear in the code. The markup is roff-like, it's going to be a man page section after all. Some appear in multiple places. For a few of them I even knew what they do. I'd appreciate if somebody could fill in the blanks for the others. Diego .SH ENVIRONMENT VARIABLES There are a number of environment variables that can be used to control MPlayer and MEncoder. .IP MPLAYER_HOME Directory where MPlayer looks for user settings. libaf: .IP LADSPA_PATH If LADSPA_PATH is set, it searches for the specified file. If it is not set, you must supply a fully specified pathname. vidix: .IP VIDIX_CRT osdep: .IP TERM libvo: .IP DISPLAY .IP FRAMEBUFFER .IP HOME libmpdemux: .IP HOME .IP HOMEPATH .IP http_proxy .IP LOGNAME .IP USERPROFILE libmpcodecs: .IP XANIM_MOD_DIR libao2: .IP AO_SUN_DISABLE_SAMPLE_TIMING .IP AUDIODEV .IP AUDIOSERVER .IP DISPLAY GUI: .IP CHARSET .IP DISPLAY .IP HOME libmpdvdkit2: .IP DVDCSS_CACHE Directory where libdvdcss caches CSS keys. .IP DVDCSS_METHOD .IP DVDCSS_RAW_DEVICE .IP DVDCSS_VERBOSE .IP DVDREAD_NOKEYS .IP HOME libavformat: .IP AUDIO_FLIP_LEFT .IP BKTR_DEV .IP BKTR_FORMAT .IP BKTR_FREQUENCY .IP http_proxy .IP no_proxy
Diego Biurrun wrote:
libao2:
.IP AUDIOSERVER
Specifies the Network Audio System server to which ao_nas should connect. If unset DISPLAY is used instead. Examples: AUDIOSERVER=somehost:0 Connect to NAS server on somehost using default port and transport. AUDIOSERVER=tcp/somehost:8000 Connect to NAS server on somehost listening on tcp port 8000. -- Tobias PGP: http://9ac7e0bc.uguu.de
On Tue, Nov 29, 2005 at 09:10:38PM +0100, Tobias Diedrich wrote:
Diego Biurrun wrote:
.IP AUDIOSERVER
Specifies the Network Audio System server to which ao_nas should connect. If unset DISPLAY is used instead. Examples: AUDIOSERVER=somehost:0 Connect to NAS server on somehost using default port and transport. AUDIOSERVER=tcp/somehost:8000 Connect to NAS server on somehost listening on tcp port 8000.
So what other options do we have? udp as well? This sounds a bit incomplete... Diego
Diego Biurrun wrote:
On Tue, Nov 29, 2005 at 09:10:38PM +0100, Tobias Diedrich wrote:
Diego Biurrun wrote:
.IP AUDIOSERVER
Specifies the Network Audio System server to which ao_nas should connect. If unset DISPLAY is used instead. Examples: AUDIOSERVER=somehost:0 Connect to NAS server on somehost using default port and transport. AUDIOSERVER=tcp/somehost:8000 Connect to NAS server on somehost listening on tcp port 8000.
So what other options do we have? udp as well? This sounds a bit incomplete...
*reading the source* Basically just tcp and unix domain sockets (I'll ignore decnet :-)). tcp syntax should be: tcp/somehost:someport or somehost:someport unix domain socket syntax: unix:instancenumber or just :instancenumber Seems a bit inconsistent, I'd have expected unix/:0 or something like that (which happens to be what X11 is using and NAS is kind of based on the X protocol after all). So: Syntax: Same as DISPLAY, but unix:0 instead of unix/:0 Examples: AUDIOSERVER=(unix)?:0 Connect to NAS server instance 0 on localhost using unix domain sockets. AUDIOSERVER=(tcp/)?somehost:8000 Connect to NAS server on somehost listening on tcp port 8000. -- Tobias PGP: http://9ac7e0bc.uguu.de
On Wed, Nov 30, 2005 at 05:04:48PM +0100, Tobias Diedrich wrote:
*reading the source* [...]
Do you like this as summary? .IP AUDIOSERVER Specifies the Network Audio System server to which the nas audio output driver should connect and the transport that should be used. If unset DISPLAY is used instead. The transport can be one of tcp and unix. Syntax is [tcp/]somehost:someport or [unix]:instancenumber .RS .I EXAMPLES: .RE .PD 0 .RSs .IPs AUDIOSERVER=somehost:0 Connect to NAS server on somehost using default port and transport. .IPs AUDIOSERVER=tcp/somehost:8000 Connect to NAS server on somehost listening on TCP port 8000. .IPs AUDIOSERVER=(unix)?:0 Connect to NAS server instance 0 on localhost using unix domain sockets. .RE Diego
Diego Biurrun wrote:
Do you like this as summary?
Looks mostly good.
.IP AUDIOSERVER Specifies the Network Audio System server to which the nas audio output driver should connect and the transport that should be used. If unset DISPLAY is used instead. The transport can be one of tcp and unix. Syntax is [tcp/]somehost:someport or [unix]:instancenumber
My mistake, should be "Syntax is tcp/somehost:someport, somehost:instancenumber or [unix]:instancenumber"
.RS .I EXAMPLES: .RE .PD 0 .RSs .IPs AUDIOSERVER=somehost:0 Connect to NAS server on somehost listening on TCP port 8000. .IPs AUDIOSERVER=tcp/somehost:8000 Connect to NAS server on somehost listening on TCP port 8000. .IPs AUDIOSERVER=(unix)?:0 Connect to NAS server instance 0 on localhost using unix domain sockets. .RE
NAS base port is 8000 and 'instancenumber' is added to that. -- Tobias PGP: http://9ac7e0bc.uguu.de
On Thu, Dec 01, 2005 at 06:35:18PM +0100, Tobias Diedrich wrote:
Diego Biurrun wrote:
.IPs AUDIOSERVER=somehost:0 Connect to NAS server on somehost listening on TCP port 8000. .IPs AUDIOSERVER=tcp/somehost:8000 Connect to NAS server on somehost listening on TCP port 8000. .IPs AUDIOSERVER=(unix)?:0 Connect to NAS server instance 0 on localhost using unix domain sockets. .RE
NAS base port is 8000 and 'instancenumber' is added to that.
I don't understand. Diego
Diego Biurrun wrote:
NAS base port is 8000 and 'instancenumber' is added to that.
I don't understand.
Same as with X11: "X :1" will listen on tcp port 6000+1 "nasd :1" will listen on tcp port 8000+1 -- Tobias PGP: http://9ac7e0bc.uguu.de
On Tue, Nov 29, 2005 at 08:57:00PM +0100, Diego Biurrun wrote:
.IP DVDCSS_CACHE Directory where libdvdcss caches CSS keys.
Mention the special value "off" to indicate that there will be no cache. - ods15
On Tue, Nov 29, 2005 at 08:57:00PM +0100, Diego Biurrun wrote:
.IP DVDCSS_CACHE Directory where libdvdcss caches CSS keys.
.IP DVDCSS_METHOD
.IP DVDCSS_RAW_DEVICE
.IP DVDCSS_VERBOSE
.IP DVDREAD_NOKEYS
.IP HOME
Cut and paste from libdvdcss docs: Some environment variables can be used to change the behaviour of libdvdcss without having to modify the program which uses it. These variables are: * DVDCSS_VERBOSE: sets the verbosity level. o 0 outputs no messages at all. o 1 outputs error messages to stderr. o 2 outputs error messages and debug messages to stderr. * DVDCSS_METHOD: sets the authentication and decryption method that libdvdcss will use to read scrambled discs. Can be one of title, key or disc. o key is the default method. libdvdcss will use a set of calculated player keys to try and get the disc key. This can fail if the drive does not recognize any of the player keys. o disc is a fallback method when key has failed. Instead of using player keys, libdvdcss will crack the disc key using a brute force algorithm. This process is CPU intensive and requires 64 MB of memory to store temporary data. o title is the fallback when all other methods have failed. It does not rely on a key exchange with the DVD drive, but rather uses a crypto attack to guess the title key. On rare cases this may fail because there is not enough encrypted data on the disc to perform a statistical attack, but in the other hand it is the only way to decrypt a DVD stored on a hard disc, or a DVD with the wrong region on an RPC2 drive. * DVDCSS_RAW_DEVICE: specify the raw device to use. Exact usage will depend on your operating system, the Linux utility to set up raw devices is raw(8) for instance. Please note that on most operating systems, using a raw device requires highly aligned buffers: Linux requires a 2048 bytes alignment (which is the size of a DVD sector). * DVDCSS_CACHE: specify a directory in which to store title key values. This will speed up descrambling of DVDs which are in the cache. The DVDCSS_CACHE directory is created if it does not exist, and a subdirectory is created named after the DVD's title or manufacturing date. If DVDCSS_CACHE is not set or is empty, libdvdcss will use the default value which is "${HOME}/.dvdcss/" under Unix and "C:\Documents and Settings\$USER\Application Data\dvdcss\" under Win32. The special value "off" disables caching. DVDREAD_NOKEYS is MPlayer specific, but currently is not used. In the file libmpdvdkit2/dvd_reader.c DVDREAD_NOKEYS is used in the funcion initAllCSSKeys, but the only place where this function is called is commented. Giacomo
participants (4)
-
Diego Biurrun -
Giacomo Comes -
Oded Shimon -
Tobias Diedrich