Borland Graphics Interface

The Borland Graphics Interface is a graphics library used by DOS programs, which includes the ability to use loadable drivers. These drivers have the file extension .BGI.

Identification
Most BGI files begin with a 4-byte signature:. Note the similarity to CHR font files used by BGI.

Newer versions have an 8-byte signature:.

Following the signature is some text that names the driver, and gives copyright information. It usually begins with " " or " ".

The header format was no doubt deliberately designed to be friendly to file viewers similar to the MS-DOS  command. The  bytes could be interpreted as backspace characters, which will hide the signature.

Main Entry
The first 160 bytes of the driver file are a header. This is followed by the driver code segment. Far calls will be made to this address with SI containing the function number to execute.

Related formats

 * BGI image
 * CHR (Borland font)

Specifications

 * ftp://ftp.musoftware.de/pub/uz/bgi/ contains documentation and source code for creating BGI drivers, along with several complete drivers.
 * A message about the driver format

Sample files
The standard BGI drivers supplied by Borland were distributed with many software packages. There are at least a few different versions of the drivers. The following filenames are known: ATT.BGI, CGA.BGI, EGAVGA.BGI, HERC.BGI, IBM8514.BGI, PC3270.BGI, VGA256.BGI.


 * Examples of software containing the Borland drivers:, , ,
 * Examples of third-party drivers: VESA.BGI, svga16.bgi, svga256.bgi
 * egavga.bgi - A v3 driver with the "FBGD" signature

Links

 * Borland Graphics Interface