SUMMARY:Raster Filter for Solaris 2.X

From: Lau, Victoria H (
Date: Tue Aug 08 1995 - 20:28:33 CDT

Thank you to all the Sun Managers who came to my rescue:

  Don (
  Mark Hamby
  Rick Fincher (
  Doug Jones
  Tim Evans (
  dan (
  Martin Achilli ( (per Martin Achilli)
  Rene OCCELLI (
  George Cameron (

My original question was: I'm looking for a filter to print raster files
on Solaris 2.X....


I took the advice from the majority and tested the printing of
raster files successfully using the "rash" command to convert
the raster files to postscript, then submit the converted
postscript file from the standard lp command:

  # rash > /tmp/

  # pr ${PR_OPTIONS} | /usr/lib/lp/postscript/postprint \
       ${POSTPRINT_OPTIONS} | lp -t -d ${PRINTER_NAME}

Rick Fincher sent me an XV program, and Martin Achilli and Tim Evans
suggested a program called ImageMagick which I'll definitely look
into for more advanced printing. Thank you.

Vicky Lau

Here are the responses:

I thought that's what rash was for.
See /usr/openwin/bin/rash, I don't know the params
and can't find the man page, but I'm sure that's what
it is.

        "me too" please?


Simon Gibbons
Technology Services Officer
Australian Institute of Family Studies
Melbourne, Australia
Tel: 61-3-9214 7880
Fax: 61-3-9214 7839
Try the rash command.

Hope this helps
Richard Skelton | e-mail :
I am certainly no expert on this, but have you looked at 'rash'?
It is a Sun raster to postscript filter.

There are also the PBMPlus utilities on the internet.

Cool nights,

Mark Hamby
RDA Logicon
Cant't you print with imagetool that is included in OpenWindows? If your
raster files are in a format imagetool can't use you may be able to convert
it with the enclosed program XV. It is compressed and will need to be
uncompressed to run.

There is a commercial version of XV that has more features and printing
capability there is info in the program.

Run XV then hit the right button in its window to open a menu window.

Hope this helps,

Rick Fincher
man rash

Doug Jones
Pick up ImageMagick from This is a full suite of
image manipulation utilities that'll allow you to convert from/to
virtually any format, including raster and ps.

Tim Evans, E.I. du Pont de Nemours & Co. 
I am  a Software developer for Xerox Engineering Systems,  which  used to be
Versatec.  This morning has me building some LP filters   for raster printing.
You want to write  to  and get the scoop  on what
he can help you with.


[I'd emailed my request to but did not receive any reply--Vicky Lau] ======================================================================== You should grab a very nice program called ImageMagick (please note the capital I and capital M when you perform an archie search) the current version is 3.6.3. It is a suite of 5 programs, one of them is called convert and will allow you to build a print filter very easily since it accepts stdin and writes to stdout. You can set various options, I am currently using it for the same thing, i.e. sun raster to ps2 conversion, the options which are best for me are:

convert -rotate 90 -page A4+17 sun:- ps2:- ^-name of program ^-rotate image to print in landscape mode ^-set papersize to A4 with horizontal margins of 17, this will use all of the usable print area in my case ^-input file format, the program will also autodetect but I am printing sun rf files only ^-output file format, Post Script lev 2, if you are printing bitmap images ps2 is 1/4 of the size of the corresponding ps file, please note the - sign for both input and output files they mean stdin in one case and stdout in the other.

The other option you can play around with is -gamma <num> all the other options are irrelevant or will only make things worse. I did a lot of experimenting, so don't waste time like I did. Please note that there is a small bug in the program for Ps2 output, I contacted the author and he sent me the solution after 15 minutes, please note 15 MINUTES and this program is public domain !! I have included his email about the bug so that you can fix the program too. Please give credit to the author of the program, not to me if you send out a summary. I think it is great and it has solved many of our IMG conversion tasks.

Bye, Martin

Martin Achilli - Consiglio Nazionale delle Ricerche - I.N.B. c/o Medicina Nucleare, Osp. San Raffaele 20132 Milano, Italy tel: +39/2/26433648 fax: ../26415202 --------------------------------------------------------------------------------

>From!cristy Fri Jun 9 16:42:34 1995 Date: Fri, 9 Jun 1995 11:14:40 -0330 From: (Cristy) To: Content-Length: 156

I think I see the problem. In magick/encode.c, in function WritePS2 you will see a strcmp(...,"PS"). Change that to strcmp(...,"PS2"). ======================================================================== On Solaris 2.4, use rash : rash(1) User Commands rash(1)

NAME rash - Sun Raster to PostScript translator

SYNOPSIS rash [ -2 ] [ -nxm ] [ -s width height [ [ -H height ] [ -S height ] [ -W width ] [ -l xpos ypos ] [ -c xpos ypos ] [ -R angle ] [ -e ] [ -i ] [ -m ] [ -n ] [ -p prolog ] [ -r ] [ -wwrapper ] [ filename... ]

DESCRIPTION rash converts a Sun Raster file into a PostScript file, using a PostScript "wrapper" to surround the raster input. By default, it creates a color PostScript file if given a color image and a monochrome PostScript file if given a monochrome image.

By default, rash centers the image on the page and orient and scale it to fill up as much of the printable area as possible while preserving the image's aspect ratio.

All the options regarding the size of the raster file take a number followed by a unit, where a unit is one of in, cm. mm, or point. measurements and units can be combined; it is possible to have a length of "1 in .5 cm", for example. The default measurement unit is points.

rash is most often used with the PreLimn filter manager, part of the NeWSprint package.

In /usr/lib/lp/postscript there are many filters to print files with differents formats:

Lucy% ls /usr/lib/lp/postscript postdaisy posttek postplot postdmd ps.requests postprint download picpack postio dpost postcomm postmd postreverse

+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + Rene OCCELLI + + Email: + ======================================================================== Try /usr/openwin/bin/ras2ps or /usr/openwin/bin/rash . Both have man pages with the details.


--------------------------------------------------------------------------- George Cameron

This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:10:31 CDT