//------------------------------------------------------------------- // pcx.h // // Defines the layout of a .pcx graphic file's 128-byte header. // // Reference: Andrew Binstock et al, "HP LaserJet Programming," // Addison-Wesley Publishing Company (1991), pp. 313-317. // // programmer: ALLAN CRUSE // written on: 29 AUG 2003 //------------------------------------------------------------------- typedef struct { char manuf; // Always 10 for Paintbrush char vers; // Version (can be ignored) char rle; // Flag: 1=compressed-image char bitpx; // Bits-per-pixel short x1; // Picture bounds - left short y1; // - top short x2; // - right short y2; // - bottom short hres; // Display resolution (horiz) short vres; // Display resolution (vertl) char rgb[48]; // Palette (for 16-bit color) char vmode; // VGA mode-number (ignored) char nplanes; // Number of planes (v2.5=0) short bplin; // Bytes-per-line short palinfo; // Palette info (1=color,2=gray) short shres; // Scanner resolution (horiz) short svres; // Scanner resolution (vertl) char xtra[54]; // Extra space (filler) } PCX_FILE_HEADER; //-------------------------------------------------------- // NOTE: Total length of PCX_FILE_HEADER equals 128 bytes //--------------------------------------------------------