Next: 6.2 Data types
Up: 2 Configurationinitialization and
Previous: 2 Configurationinitialization and
This section describes all constants used in MIDAS initialization and
configuration. They are grouped according to the enum used to
define them.
enum MIDASdsoundModes
These constants are used to describe different MIDAS DirectSound usage modes.
By default MIDAS does not use DirectSound at all, and DirectSound usage can
be enabled by setting
MIDAS_OPTION_DSOUND_MODE. Note that
MIDAS_OPTION_DSOUND_HWND needs to
be set when using DirectSound. A complete discussion of using DirectSound with
MIDAS is available at MIDAS Programmer's
Guide.
- MIDAS_DSOUND_DISABLED
- DirectSound usage is disabled
- MIDAS_DSOUND_STREAM
- DirectSound is used in stream mode -
MIDAS will play to a DirectSound stream buffer. DirectSound usage is
disabled if DirectSound runs in emulation mode.
- MIDAS_DSOUND_PRIMARY
- DirectSound is used in primary buffer
mode if possible - MIDAS will play directly to DirectSound primary
buffer. If primary buffer is not available for writing, this mode
behaves like MIDAS_DSOUND_STREAM.
- MIDAS_DSOUND_FORCE_STREAM
- Behaves like
MIDAS_DSOUND_STREAM, except that DirectSound is used always,
even in emulation mode.
enum MIDASfilterModes
These constants are used to describe different MIDAS output filter modes.
By default, no output filter is enabled, but most programs can benefit
from using a slight output filter (MIDAS_FILTER_LESS), unless
all sounds are played exactly at the mixing frequency or an integer part
of it. Programs using low mixing rates, 22kHz or below, might sound
better with more filtering -- it is usually a good idea to check the
sound quality with different filters, and use the one that sounds best.
The filter mode can be set by changing the option
MIDAS_OPTION_FILTER_MODE with
the function MIDASsetOption.
- MIDAS_FILTER_NONE
- No filtering
- MIDAS_FILTER_LESS
- Some filtering
- MIDAS_FILTER_MORE
- More filtering
enum MIDASmodes
These constants are used to describe different MIDAS output modes. They are
used with the function MIDASsetOption, when changing the setting
MIDAS_OPTION_OUTPUTMODE.
- MIDAS_MODE_8BIT_MONO
- 8-bit mono output
- MIDAS_MODE_16BIT_MONO
- 16-bit mono output
- MIDAS_MODE_8BIT_STEREO
- 8-bit stereo output
- MIDAS_MODE_16BIT_STEREO
- 16-bit stereo output
enum MIDASoptions
These constants are used with the function MIDASsetOption
to change different MIDAS configuration options.
- MIDAS_OPTION_MIXRATE
- Output mixing rate
- MIDAS_OPTION_OUTPUTMODE
- Output mode, see enum
MIDASmodes
- MIDAS_OPTION_MIXBUFLEN
- Mixing buffer length, in
milliseconds
- MIDAS_OPTION_MIXBUFBLOCKS
- The number of blocks the buffer
should be divided into
- MIDAS_OPTION_DSOUND_MODE
- DirectSound mode to use, see
enum MIDASdsoundModes
- MIDAS_OPTION_DSOUND_HWND
- Window handle for DirectSound
support. The window handle is used by DirectSound to determine which
window has the focus. The window handle has to be set when using
DirectSound.
- MIDAS_OPTION_DSOUND_OBJECT
- The DirectSound object that
should be used. Setting this option forces DirectSound support on.
- MIDAS_OPTION_DSOUND_BUFLEN
- Output buffer
length fot DirectSound, in milliseconds.
This option is used instead of MIDAS_OPTION_MIXBUFLEN
when using DirectSound without emulation.
- MIDAS_OPTION_FILTER_MODE
- Output filter mode, see
enum MIDASfilterModes.
Next: 6.2 Data types
Up: 2 Configurationinitialization and
Previous: 2 Configurationinitialization and
Petteri Kangaslampi
Sat May 24 20:31:52 EEST 1997