pouët.net

Go to bottom

Dual Module Player


                                 DMP.DOC

             Documentation for the Dual Module Player v4.00

        Copyright (C) 1992,1995 Otto Chrons. All rights reserved



    Dual Module Player is a program for playing music modules on different
    sound systems on IBM PC compatible machines. It uses DSMI sound
    programming interface (Digital Sound & Music Interface) to achieve
    high quality sound and wide sound card support.

    This packet includes both the realmode (DMP.EXE) and protected mode
    (DMP32.EXE) versions of DMP. Usually DMP32 gives you better
    performance and also more memory in the DOS shell but it may not work
    very well under some multitaskers. You shouldn't even try to run
    either version as a background task under Windows.

    DMP32 and M2AMF use the PMODE/W DOS extender to run in 32-bit protected
    mode under plain DOS. Thanks for PMODE/W go to Charles Scheffold and
    Thomas Pytel.

    DMP is careware so you can freely copy it to your friends and
    distribute it to BBSes etc. If you like DMP you should send me some
    money that will be directed to charity. See the end screen of DMP for
    more information.


    Currently DMP supports following module formats:


        MOD,NST     The original Amiga module format (SoundTracker,
                    NoiseTracker). Also supported by many PC trackers.
                    Original format supported only 4 channels but many
                    variants can support up to 32 channels.

        STM,S3M     Scream Tracker format. S3M can support up to 16
                    channels while STM is limited to 4.

        669         Composer669 module format using 8 channels.

        FAR         Farandole tracker format capable of using 16 channels.

        MTM         MultiTracker format. It's a MOD variant with up to 32
                    channels.

        AMF         DSMI's internal module format. You can convert all the
                    previous formats to AMF with M2AMF but not vice versa.
                    Using AMF format saves you disk space because AMFs are
                    usually smaller than other module formats. DMP can
                    also load AMFs faster than other formats. But remember
                    that you cannot play AMFs on any other player, nor can
                    you convert AMFs back to any other format.



    DMP is a simple program without any fancy graphics or mouse support.
    Most DMP options can be set with command line parameters, or by
    setting them into DMP envrionment variable or DMP.INI setup file.


    This is the command line syntax of DMP:


        DMP [options] [modulename] [@listfile] [options]

    where,

        [modulename]    Name of the module (or modules) to play.  Wild
                        cards are allowed.

        [@listfile]     name of a file containing a list of module names.
                        You can also use wild cards within the list file.

        [options]       DMP settings

                        -H,  -?         Show help screen about options.

                        -Nxx            Set default panning to xx. Most
                                        module formats don't support
                                        default panning, the channels are
                                        either left or right. With this
                                        option you can bring the channels
                                        close to the middle position.
                                        Value 0 means middle panning, 63
                                        sets the channels as much apart as
                                        possible and 100 forces surround
                                        sound.

                        -Fxx            Select digital effect xx as the
                                        default effect. Digital effects
                                        are defined in DMP.INI

                        -E              Disable extended (BPM) tempos. Use
                                        this option if you encounter tempo
                                        problems with old modules.

                        -L              Inhibit looping. If you are
                                        playing just one module DMP will
                                        by default loop the module
                                        forever.

                        -O              Randomize the playing order of
                                        modules.

                        -B              Disable EMS usage.

                        -W[command]     Run [command] after staring to
                                        play the module. If you want to
                                        give command line parameters to
                                        [command], put quotation marks (")
                                        around the option i.e.
                                        "-Wdir *.mod"

                                        If [command] exits with error
                                        level 68, DMP terminates
                                        immediately.

                        -X              Inhibit all output. DMP writes
                                        absolutely nothing on the screen.





                          Using default options
                          ---------------------



    If you find yourself using the same options all the time you can make
    them default options by setting up a DMP evironment variable or
    including them into DMP.INI.

    For example,

        You always want to use quality mode and sampling rate of 22kHz and
        mono mode, put following line into your AUTOEXEC.BAT

        SET DMP=-q -s22 -m

    NOTE!  You cannot override single letter options (-l,-o,-m,-q) with
    command line parameters. All other options can be overriden.

    Alternatively you can use the CmdLine parameter in DMP.INI for same
    purpose.



                      Setting up your sound system
                      ----------------------------

    Before running DMP you must select and setup the sound driver with the
    included DSETUP program. The program will let you choose a sound card
    and then select the hardware setup and other options for that sound
    device. Finally it saves the configuration into SOUND.CFG which DMP
    uses to load and initialize the sound card driver.


                             Playing modules
                             ---------------

    DMP automatically goes to the file selection screen if no valid
    modules have been selected on the command line.

    You can also build up play lists for DMP (with an external shell
    program for example). DMP reads this list file and scans each line for
    a module name. There should be only one file name per line. The name
    extension apply also for module names in play list.

    Example:

        DMP beyond.mod *.NST @goodmods

        goodmods is a text file containing following lines:

        occ-san.stm
        stars.mod
        intro3.s3m

        DMP will play following modules: BEYOND.MOD, OCC-SAN.STM, STARS.MOD,
        INTRO3.S3M and all .NST-files in the current directory.



                          Module file selector
                          --------------------

    A new feature in DMP 4.00 is a handy module file selector that lets
    you interactively make a playlist of modules and edit that list. You
    can select modules from different directories and disk drives. Modules
    can be sorted by filename, extension, module name, size and data both
    in ascending and descending order. There is also a speed search
    function with which you can quickly jump to a module matching the
    search pattern. This feature works both for file name and module name.
    Active key commands can be seen on the right side of the screen.



                     DMP configuration file DMP.INI
                     ------------------------------

    DMP has a config file called DMP.INI. It should be placed in the same
    directory with DMP.EXE but DMP will also find it if it's somewhere in
    the PATH. See the file itself for explanations on config switches and
    strings.


                        DMP play screen and keys
                        ------------------------

    After DMP has loaded the first module and started to play it you see
    the playback screen. In this screen you can find a lot of information
    on the currently playing module, like the song name, how much memory
    is used by the module, where the player is currently playing etc.

    You also see channel specific information showing you the instrument
    name that is playing on that track and also other sound parameters.
    On the right are volume bars that give you an approximation of the
    sound volume on that track.

    Under the channel information is a list of instrument names. It is
    quite common that composers use this space for some messages instead
    of real instrument names.


    Pressing 'H' brings up a quick-help showing keys that control the
    program.

        Keys:

                F           Go to module file selector.

                P           Pause module playback. Pressing any key
                            resumes.

                1-9,0       Turn track 1-9 on/off. 0 turns selected track
                            on/off.

                S           Set selected track to solo mode i.e. all other
                            tracks are muted. Pressing 'S' again on the
                            same track unmutes other channels.

                up/down     Select a track.

                left/right  Jump to previous/next pattern.

                pgup/pgdn   Scroll instrument list up/down

                F1-F10,+,-  Set playback volume.

                [,]         Decrease/increase speed (module tempo).

                {,}         Decrease/increase module BPM tempo.

                L,M,R,U     Set panning to full left/middle/right or
                            surround.

                , .         Pan to left/right

                V           Select real/fake volume bars. Default is real.

                E           Select digital effect (not available on GUS).
                            Shows a menu where you can select the effect
                            with up/down or with numbers 0-9 and X.

                N           Stop playing current module and load next module.

                B           Stop playing current module and load previously
                            played module.

                D           DOS shell (write 'EXIT' to get back to DMP)

                ESC         Exit DMP.





                          Technical information
                          =====================

    DMP uses software mixing routines to play up to 32 different digital
    sounds on one mono/stereo digital channel of your sound system. With
    Gravis Ultrasound, however, DMP uses the GUS onboard processor to do
    all the sound mixing. The software mixing routines are highly
    optimized assembly language and there are multiple routines to achieve
    best performance with any sound system.



                              Quality mode
                              ------------

    Quality mode was orignally implemented only on 8-bit sounds cards to
    overcome the dynamic limitation of 8-bits. It uses 16-bit mixing
    routines to achieve 96dB dynamic range (instead of 48dB) and post
    processes the 16-bit data into 8-bits with a look-up table that
    amplifies the sound. Because of this post processing, the Quality mode
    takes more processor power but it's worth it. To further amplify the
    sound you can use '-Axx' command line option. Quality mode is always
    enabled with 8-bit sound cards.

    For 16-bit cards there's no need to use Quality mode to improve the
    quality of the sound. But with up to 32 channels the dynamics of
    individual channels go worse i.e. the volume is lower. You can of
    course select an aplification option in the sound setup to amplify the
    sound but there is always a risk of click and noise if the sound
    overruns.  This is where 16-bit Quality mode comes in. It uses a
    temporary 32-bit buffer to do the mixing and post processes the buffer
    by clipping values that can't fit to 16-bits. Unlike 8-bit Quality
    mode, there is no default amplification in 16-bit Quality mode. 16-bit
    quality mode is not enabled unless you use an amplification mode that
    enables it.


                             Digital effects
                             ---------------

    New to DMP 3.00 was the support for digital effects. Currently you can
    do reverb/echo style of effects and simple lowpass filtering. These
    effects are only available on sound systems where DMP does the mixing
    in software (i.e. the final sound data can be post processed), so you
    cannot use them with GUS.

    You can have up to 10 predefined effects (defined in DMP.INI) and
    select between them while playing by pressing 'E' or with command line
    parameter '-Fxx'.



                                 Filters

    You can use two different lowpass filters to filter the noise caused
    by aliasing in mixing routines. These filters are really simple so
    they don't use much processor power.

    Filter 1 algorithm is defined as:

            y(n) = 0.5*x(n) + 0.5*x(n-1)

    Filter 2 is:

            y(n) = 0.75*x(n) + 0.25*x(n-1)

    Of course the actual filter routines use simple additions and shifts
    instead of floating point multiplications to achieve best possible
    speed.

    See DMP.INI how to use these filters.

    By default DMP uses the Filter 2 (this can be changed in DMP.INI or
    with '-Fxx' command line parameter).



                           Reverb/echo effects

    DMP uses a user definable reverb/echo engine to create effects from
    massive reverbs to funny sounding echos. Here is the diagram of that
    engine.


     ÚÄÄÄÄÄ¿                                    ÚÄÄÄÄÄÄÄÄ¿
     ³InputÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÂÄÄ´        ³          ÚÄÄÄÄÄÄ¿
     ÀÄÄÄÄÄÙ                   ÚÄÄÄÄÄÄÄÄ¿    ³  ³ Filter ÃÄÄÄÄÄÄÄÄÄÄ´Output³
        ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´        ÃÄÄÄijÄÄ´        ³          ÀÄÄÄÄÄÄÙ
        ³        ÚÄÄÄÄÄÄÄÄÄÄÄÄÄ´ Filter ³    ³  ÀÄÄÄÄÄÄÄÄÙ
        ³        ³     ÚÄÄÄÄÄÄÄ´        ÃÄ¿  ³
        ³        ³     ³       ÀÄÄÄÄÄÄÄÄÙ ³  ³
        ³        ³     ³                  ³  ³
        ³        ³     ³                  ³  ³
        ³        ³     ³                  ³  ³
        ³        ³     ³                -----³
        ³        ³     ³        feedback\ G /³        G = gain
 "echos"³        ³     ³                 \_/ ³
       / \      / \   / \                 ³  ³        D = delay
      / G1\    / G2\ / G3\                ³  ³
      -----    ----- -----                ³  ³
        ³        ³     ³                 ÚÁÄÄÁ¿
        ³        ³     ³                 ³ ++ ³
        ³        ³     ³                 ÀÄÄÂÄÙ
        ³        ³     ³                    ³
        ³        ³     ³                    ³
     D1 ³     D2 ³  D3 ³                    ³
    ÚÄÄÄÁÄÄÄÄÄÄÄÄÁÄÄÄÄÄÁÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿    ³
  ÚÄ´        delay line                ³    ³
  ³ ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ    ³
  ³                                         ³
  ³                                         ³
  ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ


    The number of echos can be from one to eight and each has its own
    position on the delay line and its own gain value. You can change the
    number of echos and paramters for each echo in DMP.INI
    [DigitalEffects] section. You can also set the "feedback" value.

    You can also use negative gain values to create a 180 degree phase
    shift.

    The filters used in reverb are the same as in filter 1.

    Setting a reverb in DMP.INI looks like following:

    Effect1 = <effect_name> R <feedback> <echo 1 delay> <echo 1 gain> ...


    See DMP.INI for examples on reverbs and echos.



                           Reverb performance

    Calculating one echo in reverb engine requires a few simple arithmetic
    instructions and one multiplication. In addition calculating feedback
    requires another multiplication. So with a 6 echo reverb the routine
    must do seven multiplications and lots of simple instructions for EACH
    AND EVERY SAMPLE from input. In comparison the mixing routines in the
    actual sample playback engine require only a few simple instructions
    per sample.

    Unless you have a powerful 486 it's not wise to use stereo mode
    because this doubles the reverb overhead. Even on a 486/33 using
    reverb with 44kHz stereo data can bring the machine on its knees. On
    slower machines you will start to hear the playback buffer repeating
    as DMP can't keep up with sound card DMA.

    Using simple echos requires a lot less processor computing power, it's
    all dependant on the number of echos.

    Also notice that the reverb engine in DMP32 a bit more powerful than
    the one used in DMP because DMP32 can effectively make use of 32-bit
    instructions.




                          Contacting the author
                          =====================


    If you have suggestions/questions/problems about DMP, feel free to
    contact the author. Email is preferred.


        Mail address:

            Otto Chrons
            Vaajakatu 5 K 199
            FIN-33720 TAMPERE
            FINLAND


        Internet e-mail:

            otto.chrons@cs.tut.fi


        Internet WWW page:

            http://www.cs.tut.fi/~c142092



                       Getting new versions of DMP
                       ---------------------------

	Newest version is always available at:

        Internet FTP:
        -------------

            ftp.cdrom.com       /pub/demos/music/programs/players


    For a distribution site near you, check out SUPPORT.DMP.

    See DMP.REV for revision history.
Go to top