Pattern files are essentially a binary dump of a CAM8 space. Typically
he file represents a two dimensional dump. There is no header in the file
and the data is saved in raster scan order. This means that the upper left
most cell is first in the file and the lower right most cell is last. Cells
are saved in row major order so that the topmost row comes first.
Each cell is 16 bits of data and therefore a M by N pattern file contains
M times N times 2 bytes of data. The campat utility is a good
way to generate simple pattern files. The STEP software can load
normal or compressed pattaern files. If the filename ends in the
.pat suffix the software assumes it is a normal pattern file. If
it ends in the .pat.gz suffix then the GNU compression utility is used
to uncompress the file on-the-fly as it is loaded.
Pattern files can be accompanied by colormap files which are used by CAM8
for visualization. The least significant eight bits of every cell
is used to index the colormap and generate a color on the VGA display.
Colormap files are separate files from pattern files and end in the .map
suffix.