CompuServe Messages

#Make Foreign PICT

    10-Mar-91 07:08:39
Fm: Ed Ludwig 71210,1545
To: alan cima 74000,3416
alan, Making a PICT file which only consists of one 8-bit pixmap would not really be that difficult. In this regard, PICT is not any more difficult to export to than TIFF (as a matter of fact, TIFF is much nastier!). Just write out a 512 byte header, the low-order word of your total pic size, your picture rectangle. Then write out the static header stuff for the PICT 2 format and finish it off by writing the opcode for pixmap data (according to IM 5) and then the pixmap dat itself. Not too bad. Just be aware of your byte swapping. If you want to pack your data, the PackBits algorithm is mindlessly simple and is supported by the pixmap opcode. The algorithm is in a technote somewhere. Good Luck, Ed Ludwig, Abbott Systems Read action !