Environment variables

From DoomWiki.org

Environment variables are variables stored in the operating system itself which can be retrieved by programs. They can be used to store certain configuration settings shared by many different applications. An environment variable named VAR will often be called $VAR (on Unix systems) or %VAR% (on Windows systems), according to the conventions used to refer to them in a command line environment.

Environment variables that affect Doom engine games and ports include:

DOOMWADDIR[edit]

Used by Linux Doom, and most source ports

This variable contains the path to the directory containing the IWADs.

DOOMWADPATH[edit]

Used by source ports: Chocolate Doom, Eternity Engine, Odamex, ReMooD...

This variable is similar to DOOMWADDIR, however it contains a list of directory paths; each separated from the others by colons.

DMXOPTION[edit]

Used by vanilla Doom, Heretic, Hexen, Strife...

This variable is used by the DMX library. Setting it to -opl3 makes OPL playback stereo, if OPL3 hardware is present (and selected as the music device in the setup program). Setting it to -phase enables phase-shifted sounds (this is not related to random pitch shifting). The check to see if they are set is case-sensitive, so for example "-Phase" or "-OPL3" would not work. Both these options were normally disabled for stability reasons.

Readme files and manual sometimes refer to it as DMXOPTIONS (plural), however looking at the strings contained in the executables confirm that it is DMXOPTION (singular).

DMXTRACE[edit]

Used by vanilla Doom, Heretic, Hexen, Strife...

If this variable is set to 4096, additional debug information is displayed by the DMX code during startup. Notably, it indicates the DSP version, as well as the IRQ and DMA channel numbers. This feature was never publicly documented.