[comp.sys.sgi] How Many Gray Scales On Laserwriter II NTX?

Tim_Buxton@UM.CC.UMICH.EDU (03/25/90)

         We are using the icut and tops commands to take grayscale images 
 from the screen and send 
 them to an Apple Laserwriter Plus NTX.
 We are getting  very "stair stepped" halftones.  That is,
 where a standard ramp is displayed on the screen varying
 smoothely from dark to light, the LaserWriter image will
 show a series of discrete bands.  The reason for this 
 evidently is the half-tone process. 
 
      As half-toning is explained in the "Red" PostScript
 Reference manual, each pixel you send is represented by
 "subpixel" dots, more of which are progressively turned on
 to darken the image pixel.  I had assumed that, having
 taken my eight bit pixel information on good faith, that
 PostScript would do its level best to give me 256 gray 
 levels.  This is not the case, as I proved by sending 
 a finely shaded image to the same IRIS screen which
 I had taken the 256 level image from using the psh <
  image.eps command.  The Postscript image showed banding
 instead of smooth gradations.  Doing an icut to produce
 an "rgb" image and doing the hist command on that file, I
 found that there were "spikes" at every tenth gray level.
 All of the level 30's were lumped into 30, the 40's to
 40, etc.  That meant in the 30 - 100 range I was looking
 at there were only 8 gray levels, and in the whole
 range there were only 25 real levels (~ 5bit resolution).
 
      The PS Reference Manual also indicates that the number
 of displayable grayscales is determined by the setscreen 
 command, which determines how many subpixels are in each
 pixel, and hence the scale resolution.  The first 2 
 arguments for the command, (angle? and density?) were
 doubled and halved by me with 
 no effect on the SCREEN display.
 There is an alternate "line" mode setscreen command 
 in the tops.c source code which I did not understand
 and have not tried.  Ways to change the resolution 
 were averred to be in the PS Cookbook, but what I
 saw did not seem to apply.
 
      So, help would be APPRECIATED from anyone who
 understands this, and (I hope) can tell me how to
 get 256 cool gray levels out of the LaserWriter Plus NTX
 or PostScript on the IRIS for that matter.  I don't
 mind if it takes longer to display, as long as we
 don't have to buy a Linotronic to get better pix.  Thanks.
 
                            -Tim Buxton
                             Tim_Buxton@um.cc.umich.edu
                             OptiMetrics, Inc.

root@sgzh.uucp (Bruno Pape) (03/26/90)

In article <5890597@um.cc.umich.edu> Tim_Buxton@UM.CC.UMICH.EDU writes:
>
>         We are using the icut and tops commands to take grayscale images 
> from the screen and send 
> them to an Apple Laserwriter Plus NTX.
> We are getting  very "stair stepped" halftones.  That is,
> where a standard ramp is displayed on the screen varying
> smoothely from dark to light, the LaserWriter image will
> show a series of discrete bands.  The reason for this 
> evidently is the half-tone process. 
> 

Yea, I have had the same problems on both a LaserWriter II and a
QMS ColorScript 100, and the problem seems to be with the half-toning.  

I think the problems lies with the default spot function that is provided
for the default screen definition, my guess that it is a compromise
between speed, memory, and beauty.

If one were to fully understand Program 15 / Filling an Area with a Pattern,
in the PostScript Language Tutorial and Cookbook one might have a better
idea of how to get better half-toning results.

I never did understand it well enough though.  You might try posting to
comp.lang.postscript.

Bruno Pape

blbates@AERO4.LARC.NASA.GOV ("Brent L. Bates AAD/TAB MS294 x42854") (03/27/90)

   I have created test image files from scratch, these images
were 8bit grayscales.  The laser printer gave me about 32 levels
of gray.  It seemed to me to be a limitation of the printer and
not the source file.
--

	Brent L. Bates
	NASA-Langley Research Center
	M.S. 361
	Hampton, Virginia  23665-5225
	(804) 864-2854
	E-mail: blbates@aero4.larc.nasa.gov or blbates@aero2.larc.nasa.gov

buck@drax.gsfc.nasa.gov (Loren (Buck) Buchanan) (03/28/90)

In article <1990Mar26.134330.12298@sgzh.uucp> root@sgzh.UUCP (Bruno Pape) writes:
>In article <5890597@um.cc.umich.edu> Tim_Buxton@UM.CC.UMICH.EDU writes:
>>
[[[about limited number of gray levels when printing]]]

The answer is you can change the number of gray levels by using the
setscreen command.  The trade off is that to get more gray levels you
have to increase the spot size.  For a 300 dpi printer, I believe the
default screen setting gives 37 shades of grey (36 pixels per spot).

For more information look at back issues of Computer Shopper and look
at the "Ask the Guru" column by Don Lancaster.

B Cing U

Buck

Loren "Buck" Buchanan | internet: buck@drax.gsfc.nasa.gov | standard disclaimer
CSC, 1100 West St.    | uucp: ...!ames!dftsrv!drax!buck   | "By the horns of a
Laurel, MD 20707      | phonenet: (301) 497-2531 or 9898  | sky demon..."

root@sgzh.uucp (Bruno Pape) (03/29/90)

In article <1465@dftsrv.gsfc.nasa.gov> buck@drax.gsfc.nasa.gov (Loren (Buck) Buchanan) writes:
>In article <1990Mar26.134330.12298@sgzh.uucp> root@sgzh.UUCP (Bruno Pape) writes:
>>In article <5890597@um.cc.umich.edu> Tim_Buxton@UM.CC.UMICH.EDU writes:
>>>
>[[[about limited number of gray levels when printing]]]
>
>The answer is you can change the number of gray levels by using the
>setscreen command.  The trade off is that to get more gray levels you
>have to increase the spot size.  For a 300 dpi printer, I believe the
>default screen setting gives 37 shades of grey (36 pixels per spot).
>

I was wrong about the spot function.  The spot function determines in what
order the pixels are changed from black to white when stepping through the
shades.  The PS Language Refenece Manual, page 85.

The problem with using 256 gray shades is the size of the spot required.
Using:
		currentscreen 3 -1 roll pop 18.75 3 1 roll setscreen

You can change the frequency to 18.75 which gives 257 gray shades.
( 16 dots x 16 dots = 256 dots = 257 shades, 300 dpi / 16 dots = 18.75 )
Which is almost 1/16 of an inch per cell.  It's a big cell.

A cell that is 1/18 of an inch will not look good in detail images, like
fractals, but it looks ok if you use the whole page to shade from black
to white.

On a 300 dpi QMS PS 810 the default frequency is 60.0, or a 5x5 spot size
for 26 shades of gray. 

And a couple questions for my friends in Mountain View.

	Why doesn't the above have any affect in psh?
		Your not really doing half-toning?

	If your not doing half-toning, because you can get all the
	shades you need by varing the intensity of every pixel, then
	why does psh only give about 10-20 shades of gray?

Thanks,

Bruno