🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.postscript
Article #3328

Re: beginner's question on image

#3328
From: Steve Phillips
Date: Thu, 11 Oct 1990 02:44
44 lines
1721 bytes
In article <1990Oct7.185320.172@cho006.cho.ge.com> niles_v@cho006.cho.ge.com writes:
>
>How do I print more than one copy of an image on the same sheet?
>Here's what I am trying to do:
>
>/test_img 
><ff.....BIG image string ....
>......ff> def
>100 100 translate
>270 110 scale
>800 392 1 [800 0 0 392 0 0] {test_img} image
>200 200 translate
>270 110 scale
>800 392 1 [800 0 0 392 0 0] {test_img} image
>showpage
>
>but I just can't seem to get the second image to print.

It looks like your problem is that you're forgetting to un-translate
and un-scale after each image, so you're drawing multiple images
but they're ending up off the page.  Try using gsave/grestore:

...
gsave
    100 100 translate
    270 110 scale
    800 392 1 [800 0 0 392 0 0] {test_img} image
grestore
gsave
    200 200 translate
    270 110 scale
    800 392 1 [800 0 0 392 0 0] {test_img} image
grestore
showpage

Hope this helps,

Steve

-- 
============================================================================
Steve Phillips                           "Never put off until tomorrow what
Tegra-Varityper, Inc., Billerica, MA      you can do the day after tomorrow" 
tegra!phillips@uunet.com                                     - Mark Twain
Technical Details
Message-ID: <1580@robbie.tegra.COM>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!wang!shyoon!tegra!phillips
References: <1990Oct7.185320.172@cho006.cho.ge.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!wang!shyoon!tegra!phillips
From: phillips@tegra.COM (Steve Phillips)
Newsgroups: comp.lang.postscript
Subject: Re: beginner's question on image
Message-ID: <1580@robbie.tegra.COM>
Date: 11 Oct 90 02:44:19 GMT
References: <1990Oct7.185320.172@cho006.cho.ge.com>
Reply-To: phillips@robbie.UUCP (Steve Phillips)
Organization: Tegra-Varityper, Inc. Billerica, MA
Lines: 44