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.
Screen Image Arrays and Compatibility
◄Contents► ◄Index► ◄Back►
──────────────────────────────────────────────────────────────────────────────
Screen Image Arrays and Compatibility
■ Use bits-per-pixel-per-plane ("Bits" below) and planes values ("Planes"
below) to determine the required size of the array that holds a graphics
screen image.
■ In addition to bits-per-pixel-per-plane and planes values, the horizontal
resolution also determines which screen modes are compatible:
Horizontal
Screen Mode Bits Planes Resolution (in Pixels)
════════════════════════════ ════ ══════ ═══════════════════════
1 2 1 320
2, 4, 11 1 1 640
3 1 1 720
7 1 4 320
8, 9 (>64K video memory), 12 1 4 640
9 (64K video memory), 10 1 2 640
13 8 1 320
■ The following formula gives the required size, in bytes, of an array used
to hold a captured image:
size% = 4 + INT(((PMAP (x2!, 0) - PMAP (x1!, 0) + 1) *
(bits-per-pixel-per-plane%) + 7) / 8) * planes% *
(PMAP (y2!, 1) - PMAP (y1!, 1) + 1)
■ GET and PUT operations are compatible in screen modes with the same
horizontal resolution, bits-per-pixel-per-plane, and planes values. For
example, screen modes 2, 4, and 11 are compatible, and screen modes 8 and
12 are compatible.
See: ◄GET Statement (Graphics)► ◄PUT Statement (Graphics)►
See: ◄Graphics Command Summary►