Mode X
|
Mode X is an undocumented video graphics display mode of the IBM VGA graphics hardware that was popularized by Michael Abrash, a writer for Dr. Dobb's Journal.
Mode X involves tweaking IBM's standard Mode 13h 256 colour graphics mode such that all the video memory is made available to the programmer in a planar fashion, at the expense of extra complexity in writing to video memory. For many programmers, this expense is well worth the effort as the extra video memory available makes it possible to produce high quality 2D games or demos, things that this mode was primarily used for.
The main uses of the extra memory are:
- Higher resolutions: up to 360×480 in 256 colours is possible
- Double Buffering for flicker free animation
- Hardware smooth scrolling
- Graphics store in 'off-screen' VRAM can quickly be moved around in VRAM using the VGA latches
- Planar mode allows up to 4 pixels to be modified in one byte write operation, which is ideal for solid filling of objects such as polygons, rectangles, lines, etc.
- Screen splitting, where one part of the display is taken from one area of memory and the other from a different area which is ideal for status displays in games utilising smooth hardware scrolling