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►
──────────────────────────────────────────────────────────────────────────────
Use bits-per-pixel-per-plane and planes values to determine the required size
of the array that holds a graphics screen image. Bits-per-pixel-per-plane and
planes values, along with the horizontal resolution, also determine which
screen modes are compatibile:
Horizontal
Bits-per-pixel- resolution
Screen mode per-plane Planes (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 and 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 Also ◄SCREEN► ◄Screen Modes►