Path: utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!wuarchive!zaphod.mps.ohio-state.edu!think!ames!henry.jpl.nasa.gov!elroy.jpl.nasa.gov!gryphon!pnet02!lampi From: lampi@pnet02.gryphon.com (Michael Lampi) Newsgroups: comp.sys.apollo Subject: Re: APOLLO.gmf format Message-ID: <22938@gryphon.COM> Date: 2 Dec 89 02:40:46 GMT Sender: root@gryphon.COM Organization: People-Net [pnet02], Redondo Beach, CA. Lines: 50 The Apollo Graphics Map File format (GMF) is a binary streams file. There are 4 kinds of records: header records, scanline group records, scanline data records and end-of-bitmap records. Each occurrence of a header record means the beginning of a separate bitmap. The file must have a header record as the first record in the file. Following the header record of a bitmap is a series of scanline group records and scanline data records intermixed. At the end of a bitmap is an end-of-bitmap record. The header record has the following 16-bit fields: 0001 means 'this is a header record' 0001 version number of this file format x x dimension of bitmap in bits y y dimension of bitmap in bits bpi resolution of data in bits per inch, to whatever degree of accuracy is feasibe. (0 means each bit is one dot regardless of dot size of the output device.) The scanline group record has the following fields, both 16-bit: 0002 means "this is a scanline group record" n number of scanline records following A scanline group record signals that the following n records are not to be interpreted as anything but binary data for the bitmap (scanline data records). A scanline data record consists of bits of data for one scanline. Each record is a simple string of bytes, with the frirst byte in a record being the leftmost of the scanline and the first bit in a byte being the leftmost of the byte. Records that do not contain enough bits to equal the x dimension are to be interpreted as padded on the right with zero bits. Records exceeding the x dimension of the bitmap are truncated at the xth bit. If the end-of-bitmap record is encountered before the expected number of scanlines (y dimension) is read, the remaining scanlines are assumed to contain zeroes. Extra scanlines are ignored. One bits are to be printed in black, zero bits are to be printed in white. The end-of-bitmap record has the following format: 0003 means "this is an end-of-bitmap record" -------The above was copied from a memo from Apollo a long time ago.... Michael Lampi MDL Corporation 213/782-7888 fax 213/782-7927 UUCP: {ames!elroy, }!gryphon!pnet02!lampi INET: lampi@pnet02.gryphon.com "My opinions are that of my corporation!"