Path: utzoo!attcan!uunet!seismo!sundc!pitstop!sun!wind!naughton From: naughton%wind@Sun.COM (Patrick Naughton) Newsgroups: comp.lang.postscript Subject: Re: Help! What am I doing wrong here? Message-ID: <78010@sun.uucp> Date: 17 Nov 88 04:42:31 GMT References: <4181@teklds.TEK.COM> Sender: news@sun.uucp Reply-To: naughton@sun.UUCP (Patrick Naughton) Organization: Sun Microsystems, Mountain View Lines: 40 In article <4181@teklds.TEK.COM> tims@teklds.TEK.COM (Tim Stoehr) writes: >I'm having a problem with my first use of the 'image' operator. >72 72 scale >20 20 1 [20 0 0 20 0 0] {fffff f800f fbfff fbfff fbfff fbfff f81ff fbfff >fbfff fbfff fbfff fbfff fffff fffff fffff fffff>} >image >showpage > >I expected a black upside-down 'F' to be generated, instead I got random >garbage. Any distribution of blanks in the hex string made no difference. >What am I doing wrong? You are describing your string incorrectly. Read page 24 of the Red Book. "A string may be described in hex... by bracketing a sequence of hex characters... Each pair of hex digits defines one character of the string. ... Spaces, tabs, and newlines are ignored." if you want some bits in the upper nibble (left half for depth 1) of a byte you need to specify the lower nibble as zero. Your example: f81ff fbfff translates to: f8 1f ff bf ff not as expected: f8 1f f0 fb ff f0 Here's your upside down F: %! 72 72 scale 20 20 1 [20 0 0 20 0 0] { } image showpage -Patrick ______________________________________________________________________ Patrick J. Naughton ARPA: naughton@Sun.COM Window Systems Group UUCP: ...!sun!naughton Sun Microsystems, Inc. AT&T: (415) 336 - 1080