Xerox DocuPrint Network Printer Series Guide Manual page 59

Guide to using page description languages
Hide thumbs Also See for DocuPrint Network Printer Series Guide:
Table of Contents

Advertisement

%!PS - Adobe - 3.0
% G4.example.ps
% Example using embedded CCITT group 4 (G4) data.
% Example using data in "normal" scan order, which has the fast scan
% direction left-to-right, and the slow scan direction top-to-bottom.
% Page size is roughly 8.5x11 (slightly clipped).
% Data has resolution of 300 spots per inch.
% Fast scan direction for the image is left-to-right across the page.
% Slow scan direction for the image is top-to-bottom down the page.
% This scan direction requires 90 degree internal rotation for
DocuPrint.
% printers, although the PostScript code has no explicit rotation given.
/lines 3296 def
/bpl 2528 def
/res 300.0 def
/useMask true def
save
bpl res div 72 mul lines res div 72 mul scale
bpl lines useMask {false} {1} ifelse
[bpl 0 0 lines neg 0 lines]
currentfile
<<
/CCITTFaxDecode filter useMask {imagemask} {image} ifelse
!!!! binary G4 data goes here !!!!
%%%%%%%% end of G4 data
restore
showpage
%%End of Example
XEROX DOCUPRINT NPS GUIDE TO USING PAGE DESCRIPTION LANGUAGES
Figure 2-12. PostScript with embedded image: normal scan
% lines in the image
% bits per line
% spots per inch of image resolution
% true => use imagemask, false => use image
/Uncompressed false
/K -1
/EndOfLine false
/EncodedByteAlign false
/Columns bpl
/Rows lines
/EndOfBlock false
/BlackIs1 true
>>
The following example illustrates the requirements for embedding
and printing an image in an enhanced scan. If a large number of
images are to be printed, it is best to avoid the internal rotation. To
do this, you must include the data in the order in which it is required,
which means that the fast scan direction for the image is bottom-to-
top, and the slow scan direction is left-to-right.
Assuming that the data was reordered in this way, the following
example shows a fragment of PostScript that produces the same
output as the previous fragment.
order
POSTSCRIPT
2-33

Advertisement

Table of Contents
loading

Table of Contents