Important Notice
The pages on this site contain documentation for very old MS-DOS software,
purely for historical purposes.
If you're looking for up-to-date documentation, particularly for programming,
you should not rely on the information found here, as it will be woefully
out of date.
_GetVideoConfig Procedure
◄Summary► ◄Details► ◄Example► ◄Back►
Argument
vc Determines video information
Description
The _GetVideoConfig procedure gets information about the current
video environment. The _VideoConfig record contains the following
fields:
Element Contents
═════════════ ═════════════════════════════════
numxpixels Horizontal resolution in pixels
numypixels Vertical resolution in pixels
numtextcols Number of text columns available
numtextrows Number of text rows available
numcolors Number of colors available
bitsperpixel Number of bits per pixel
numvideopages Number of available video pages
mode Current video mode
adapter Active display adapter type
monitor Active display monitor type
memory Adapter video memory in kilobytes
The values for the mode field of the _VideoConfig record are
given by the constants shown below:
Constant Meaning
════════ ════════════════════════════════════
_MaxResMode Highest resolution graphics mode
_MaxColorMode Graphics mode with most colors
_DefaultMode Restore screen to original mode
_TextBW40 40-column text, 16 grey
_TextC40 40-column text, 16/8 color
_TextBW80 80-column text, 16 grey
_TextC80 80-column text, 16/8 color
_MRes4Color 320 x 200, 4 color
_MResNoColor 320 x 200, 4 grey
_HResBW 640 x 200, BW
_TextMono 80-column text, BW
_HercMono 720 x 348, BW for HGC
_MRes16Color 320 x 200, 16 color
_HRes16Color 640 x 200, 16 color
_EResNoColor 640 x 350, BW
_EResColor 640 x 350, 4 or 16 color
_VRes2Color 640 x 480, BW
_VRes16Color 640 x 480, 16 color
_MRes256Color 320 x 200, 256 color
_OResColor 640 x 400, 1 of 16 colors (Olivetti)
The values for the adapter field of the _VideoConfig record are
given by the constants shown below:
Constant Meaning
════════ ════════════════════════════════════════════
_MDPA Monochrome Display Printer Adapter
_CGA Color Graphics Adapter
_OCGA Olivetti(R) [AT&T(R)] Color Graphics Adapter
_EGA Enhanced Graphics Adapter
_OEGA Olivetti (AT&T) Enhanced Graphics Adapter
_VGA Video Graphics Array
_OVGA Olivetti (AT&T) Video Graphics Array
_MCGA Multicolor Graphics Array
_HGC Hercules(R) Graphics Card
Note that the Olivetti(R) adapters (_OCGA, _OEGA, or _OVGA) are
compatible with the corresponding _CGA, _EGA, or _VGA adapters, but
support an additional high resolution mode, _OResColor.
The values for the monitor field of the _VideoConfig record are
given by the constants below:
Constant Meaning
════════ ═══════════════════════════════════════════
_Mono Monochrome monitor
_Color Color (or enhanced monitor emulating color)
_EnhColor Enhanced color
_AnalogMono Analog (monochrome only)
_AnalogColor Analog (color only)
_Analog Analog (monochrome and color modes)
In all text modes, the _GetVideoConfig function returns the value
32 for the number of available colors. This value indicates the
range of values accepted by the _SetTextColor procedure (0-31),
including 16 non-blinking (0-15) and 16 blinking (16-31) colors.
(Select blinking by adding 16 to the normal color value.)
Since monochrome text mode has fewer unique display attributes,
some are redundant; however, the range of possible attributes is
the same (0-31) as for other text modes, and blinking is selected
in the same way.