Article View: comp.lang.postscript
Article #8810Re: 9600 bps bottleneck on Laserwriter Plus
From: Jef Poskanzer
Date: Thu, 11 Jan 1990 10:11
Date: Thu, 11 Jan 1990 10:11
66 lines
2865 bytes
2865 bytes
In the referenced message, ericbi@microsoft.UUCP (Eric BIDSTRUP) wrote:
}In article <1990Jan10.042555.19571@grian.cps.altadena.ca.us>, alex@grian.cps.altadena.ca.us (Alex Pournelle) writes:
}> Implement a postscript decompresso program
}
}As someone who has attempted to do this before, I recommend you
}save yourself the time & energy. What happened (in my case) was
}that the decompression routine took longer to execute & translate
}the data stream than simply sending the same data in a non-compressed
}format. I also remember seeing a thread here or on CIS about the
}same idea a year ago w/ others having similiar results.
That was here. As I recall, I posted my version of the PostScript
decompression routine (as generated by the PBMPLUS program pgmtops),
noted the same thing as you (that the compressed version took longer to
execute than the uncompressed took to transmit), and asked whether any
better PostScript hackers could come up with a more optimal routine
that might be a win. I got about five different versions posted or
mailed, and none were faster than uncompressed.
However! That was at AppleTalk speed. And even then, the uncompressed
bitmap was only about twice as fast as the compressed. At 9600 or even
38400, the compressed definitely wins by a large factor. Since Jim
says he is limited to using the serial line, compressing sounds like a
good plan.
Appended below is a sample bitmap done with the decompression routine.
---
Jef
Jef Poskanzer jef@well.sf.ca.us {ucbvax, apple, hplabs}!well!jef
"You tweachewous miscweant!" -- Elmer Fudd
%!PS-Adobe-2.0 EPSF-2.0
%%Creator: pgmtops
%%Title: a.ps
%%Pages: 1
%%BoundingBox: 295 392 316 399
%%EndComments
%%EndProlog
/rlestr1 1 string def
/rlestr 128 string def
/readrlestring {
currentfile rlestr1 readhexstring pop 0 get
dup 127 le {
currentfile rlestr 0 4 3 roll 1 add getinterval
readhexstring pop
} {
256 exch sub dup
currentfile rlestr1 readhexstring pop 0 get
exch 0 exch 1 exch 1 sub { rlestr exch 2 index put } for
pop rlestr exch 0 exch getinterval
} ifelse
} bind def
%%EndProlog
%%Page 1 1
gsave
295.92 392.64 translate
20.16 6.72 scale
21 7 1
[ 21 0 0 -7 0 7 ]
{ readrlestring }
image
fdff11bb8f1f9376efab76efbb76efbb8f1fffffff
grestore
showpage
%%Trailer
Technical Details
Message-ID:
<15469@well.UUCP>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!brutus.cs.uiuc.edu!apple!well!jefReferences:
<10213@microsoft.UUCP>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!brutus.cs.uiuc.edu!apple!well!jef From: jef@well.UUCP (Jef Poskanzer) Newsgroups: comp.lang.postscript Subject: Re: 9600 bps bottleneck on Laserwriter Plus Message-ID: <15469@well.UUCP> Date: 11 Jan 90 10:11:04 GMT References: <10213@microsoft.UUCP> Reply-To: Jef Poskanzer <jef@well.sf.ca.us> Organization: Paratheo-Anametamystikhood Of Eris Esoteric, Ada Lovelace Cabal Lines: 66