[comp.lang.postscript] Compressing simple vector plots

gl8f@astsun9.astro.Virginia.EDU (Greg Lindahl) (07/23/90)

This is a very simple question from someone who doesn't know any
postscript, so please bear with me.

Various graphics packages generate postscript files which are just
vector plots -- draw a line from a to b, then from c to d, repeat
ad nauseum. These plot files can be huge, and the bottleneck is
transmitting them to the printer, it would seem.

The existing plot files look like this:

< preamble >
< a few definitions for "efficiency": >
/l {moveto rlineto currentpoint stroke moveto} bind def
/c {rlineto currentpoint stroke moveto} bind def
/d {moveto 0 0 rlineto currentpoint stroke moveto} bind def
< set scale, etc. >

0 90 4447 780 l 0 45 5364 780 l 0 90 6281 780 l 0 45 7198 780 l 0 90 8115 780 l 0 45 9031 780 l 0 -90 780 7019 l 0 -45 1697 7019 l
0 -90 2614 7019 l 0 -45 3530 7019 l 0 -90 4447 7019 l 0 -45 5364 7019 l 0 -90 6281 7019 l 0 -45 7198 7019 l 0 -90 8115 7019 l

Ok, so I want to make this half this size. Can I transmit these
numbers using something more efficient than decimal numbers, e.g. use
numbers and upper case letters, giving me 36 possible digits? Could
l,c, or d be optimized?

--
"In fact you should not be involved in IRC." -- Phil Howard