🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.postscript
Article #716

Re: compressed images

#716
From: John Hascall
Date: Thu, 20 Jul 1989 17:52
51 lines
2070 bytes
In article <59760> jcm@nori.Philips.Com (John Martin) writes:
>The PostScript "image" operator works as follows: ...
 
>Has anyone implemented a PostScript run length decoder procedure that
>will allow run length compressed files to be sent to the printer?
>Assume that the compression is done by a C program in advance.

   Yes (here is an excerpt of output from such a program).
This may or may not be a "good" way to do this as this was one
of my first attempts at PostScript.

%!-Adobe-1.0                     
%%Title: p1                        
%%Creator: VAXstation MOVIE.BYU 6.2
18 108 translate    
 0.6667 0.6667 scale
/c 0 def /d 1 string def
/IB {/pix exch def save pix 1 8 [pix 0 0 1 0 0]} def 
/RL {c 0 eq {
       /c currentfile d readhexstring pop 0 get def
       currentfile d readhexstring pop pop
    } if
    /c c 1 sub def d
} def
/IE {translate pix 1 scale image restore} def
/NP {newpath} def /SK {stroke} def
/MT {moveto} def /LT {lineto} def 
/SC {setrgbcolor} def             
%%EndProlog
%%Page: 0 1
 33 IB {RL} 389 627 IE  
01151F0F010E            
 80 IB {RL} 357 626 IE  
010F010E0E1431150F0F    
106 IB {RL} 347 625 IE  
090F2115221B0F150F0F    
123 IB {RL} 337 624 IE  
090F09154E1B15150114050E

 
>I realize that the file transmission time will be more than offset by
>the decompression time, but am willing to trade off time for file
>size.

    I found that it was faster to send uncompressed data, than to
send compressed data (at least at 19.2 Kbaud which is what we run).


John Hascall
ISU Comp Center
Ames IA
Technical Details
Message-ID: <1231@atanasoff.cs.iastate.edu>
Path: arc1-ca.pugleaf.net!utzoo!attcan!utgpu!jarvis.csri.toronto.edu!rutgers!iuvax!uxc.cso.uiuc.edu!dino!atanasoff!hascall
References: <59760@philabs.Philips.Com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!utgpu!jarvis.csri.toronto.edu!rutgers!iuvax!uxc.cso.uiuc.edu!dino!atanasoff!hascall
From: hascall@atanasoff.cs.iastate.edu (John Hascall)
Newsgroups: comp.lang.postscript
Subject: Re: compressed images
Message-ID: <1231@atanasoff.cs.iastate.edu>
Date: 20 Jul 89 17:52:49 GMT
References: <59760@philabs.Philips.Com>
Reply-To: hascall@atanasoff.cs.iastate.edu.UUCP (John Hascall)
Organization: Iowa State Univ. Computation Center
Lines: 51