Figure 4
Transforming the EPS file
Translate to new origin
Scale to fit placement box
Translate to final position
Assuming that the bounding box found in the header of the EPS file is
%%BoundingBox: -100 -100 100 100
, the following PostScript language code
fragment properly places the EPS file on the printed page:
400 400 translate
.8 .8 scale
100 100 translate
% Translate to new origin
% Scale to fit “placement box”
% –llx –lly translate
This transformation code must be inserted into the PostScript stream
ahead
of the EPS code being sent to the printer.
Figures H.3 and H.4 and the corresponding PostScript code fragment assume
that the application coordinate system matches the default PostScript coordi-
nate system. The following section discusses a more general coordinate
system transformation.
General Coordinate System Transformation
Typically, an application transforms the PostScript coordinate system so the
native drawing units of the application space can be used as the operands to
the PostScript language operators defining the page. Consider Figure 5,
which represents an arbitrary application coordinate system and a placement
box for an EPS file.
18
(1 May 92)
Home Index Bookmark Pages
Pages: Home Index