Short: Port of Ghostscript 2.6.1 Author: Olaf Barthel Uploader: Stefan Becker Architecture: m68k-amigaos GNU Ghostscript 2.6.1 Amiga port ================================ This port requires: - An Amiga equipped with an '020 CPU and an '881 FPU or any successor CPU/FPU model and Kickstart 2.04 or higher. - Approx. 4.7 MBytes of hard disk space available. - A minimum of 1 MByte of chip memory, depending on what you will want to do with the interpreter. Printer output requires at least 2 MBytes of contiguous memory (any memory, not necessarily chip memory). - ixemul.library and a bunch of Postscript/Ghostscript fonts. New Amiga features in this release ---------------------------------- The v2.6.0 port used to implement only monochrome drivers, the v2.6.1 port supports colour output on most devices, exceptions where noted. You don't need a special brand of graphics hardware expansion, colour output will work on any Amiga model, provided there is enough memory available. All devices capable of doing colour output will reduce the number of colours to be displayed if in dire need of memory. As for the display oriented devices this will go mostly unnoticed as the Ghostscript halftoning algorithms will compensate for any colour reductions. However, printer output quality is very likely to suffer from colour reduction. So, watch out! As the display oriented devices start up in colour output mode, black & white rendering may be slightly slowed. The printer device is configured according to the Preferences settings; `Black & white' will result in monochrome output, `Grayscale 1' and `Grayscale 2' will also produce monochrome output but will internally use a true colour representation of the page, so does `Color'. Please note that `true colour' refers to the Amiga 12 bit colour model, at this time of writing 24 bit colour printing is not yet implemented. The default output device (a super-bitmap window to opened on the default public screen, such as Workbench) will take advantage of the Kickstart 3.0 pen sharing feature if enough colours (eight or more) available. The v2.6.0 port used to rely on printer drivers to initialize their maximum page size information upon startup. Several users reported problems with certain drivers which would make this information available only after having been asked to do so. The v2.6.1 port now follows the programmers' guidelines how to determine the maximum page size closely. The driver may still complain if configured for `Grayscale 1', `Grayscale 2' or `Color' output and there is not enough memory available for the page to be displayed. Installation ------------ Enter the command line interpreter, Create a directory on your hard disk drive, label it "ghostscript". Let's assume that the fully qualified name of this directory will be "Work:ghostscript". Enter this directory and unpack the archives "gs-2.6.1-amiga.lha" and "gs-2.6.1-fonts.lha". This will create the directory "Fonts" which holds all Ghostscript fonts, the directory "doc" which contains the Ghostscript documentation files, the directory "examples" which is to hold some Postscript example files and the directory "libs" which contains `ixemul.library'. Now edit your `S:User-Startup' file, adding the following lines: Assign ghostscript: "Work:ghostscript" Path ghostscript: add Assign Libs: ghostscript:libs add Save the file back to disk and reboot your machine. Running the interpreter ----------------------- Enter the command line interpreter, type "gs" and press return. The interpreter will be loaded and will try to initialize itself. If successfully initialized, a window should have been opened on the Workbench screen. The Shell window now should display the following text: Initializing... done. Ghostscript 2.6.1 (5/28/93) Copyright (C) 1990-1993 Aladdin Enterprises, Menlo Park, CA. All rights reserved. Ghostscript comes with NO WARRANTY: see the file COPYING for details. GS> At the command prompt, enter "(ghostscript:examples/golfer.ps) run" and press return. Click on the `Zoom' button in the top right corner of the window to bring it to full screen size, move the scrollers and watch what will happen. When rendering is finished, the Shell window will display the following text: >>showpage, press to continue<< Press return to erase the contents of the window and to continue. The interpreter will be in interactive mode again, enter "quit" and press return to end this session. For more information refer to the documentation in the "ghostscript:doc" drawer. How to print a document ----------------------- As the corresponding Ghostscript device will always keep the entire page in memory the printer need not be capable of strip-printing. The bad news is that the entire page will consume *a lot* of memory. This Amiga port will keep the page in any public memory area, so it will not necessarily eat up precious chip memory. This should make it possible to print pages on Amigas with only 1 MByte of chip memory or less, provided enough fast memory is available. Enter the command line interpreter, type "gs -sDEVICE=amiga_printer" and press return. This will invoke the Ghostscript interpreter with the "amiga_printer" device driver selected as the startup device. When the command prompt appears, enter "(ghostscript:examples/butterfly.ps) run" and press return. The rendered image will be sent to the printer. When printing is finished, press return and enter "quit" to end this session. Note: unless you want Ghostscript to prompt you to press return after each page is printed and ejected you should include "-dNOPAUSE" on the command line. Available device drivers ------------------------ This port implements the following seven device drivers: amiga (This is the default output device) Rendering takes place in a super-bitmap window to be opened on the Workbench screen. This window contains scroller handles to move around in the bitmap. Usually, the bitmap will be four times as large as the screen the window opens upon. amiga_low Renders into a low-resolution custom screen. amiga_high Renders into a high-resolution custom screen. amiga_super Renders into a super-high-resolution custom screen. amiga_a2024¹ Renders into an A2024 resolution custom screen. amiga_printer Outputs pages on the currently configured preferences printer. Respects density and resolution settings. Requires a lot of memory to run. amiga_ilbm¹ Will prompt for a file name to save the current page contents to. The page will be saved as a standard IFF-ILBM picture, including DPI information, suitable for postprocessing using standard image processing and editing software. ¹) Monochrome output only Properties ---------- With Ghostscript 2.6.1 one can specify several driver specific options on the command line. As for the Amiga drivers, they support the following properties: - PageWidth and PageHeight The dimensions of the page to render into. The physical page size Ghostscript will use for rendering is limited by these dimensions. On startup The Amiga drivers will default to a page size roughly equivalent to A4 unless different dimensions are specified. The size definitions may include measuring units (e.g. "-sPageWidth=21cm"), the following units are supported: pt (points, the default if no unit is given), pc (picas), in (inches), cm (centimeters), mm (millimeters), dd (didot points), cc (ciceros). - OutputFile The amiga_ilbm device pays attention to this property, which it will use to construct the output file names for pages to be saved with. Thus, `-sOutputFile="ram:page"' yields the files "ram:page0001.ilbm", "ram:page0002.ilbm", etc. Not all devices will pay attention to DPI page resolutions. Installing fonts ---------------- The Ghostscript distribution includes a number of public-domain or otherwise freely distributable fonts. However, these are mostly of poor quality. In order to install a new font or to replace a font with a different one, the following steps are required: 1. The font must be converted to Ghostscript format. For font files in BDF-format (such as the fonts included in the X-Windows distribution) this requires processing with the "bdftops" script file (syntax is "bdftops "). Fonts in standard ASCII text format (".PFA" format) or packed binary file format (".PFB" format), such as most Adobe-Type-1 hinted outline fonts to be purchased from various vendors, need not be converted as this is the native format Ghostscript expects. 2. Copy the resulting output file to the "ghostscript:fonts" drawer, choose a suitable name (see the file "ghostscript:fontmap" for more information). 3. Edit the file "ghostscript:fontmap" to include the font which will make it visible to the interpreter. Read this file carefully as it gives basic hints how to name a font file and how to edit the corresponding font entry. The Workbench window -------------------- The default output device (the Workbench window) can be controlled both by mouse and by keyboard: Cursor keys will move the currently visible area of the page, holding down a Shift or Control key will increase the size of the scrolling steps. Control+C and Escape will send the interpreter a signal to terminate processing, so does clicking the window close button. By default the page size will always be four times as large as the currently visible portion of the Workbench screen, see the section entitled "Page sizes and resolutions" for more information. Troubleshooting --------------- This interpreter implementation requires a lot of chip memory to run. In order to assure that enough memory will be available, close any Workbench drawers or Shell windows which are not necessarily require to run the interpreter. Most Postscript documents use hard-coded document page sizes, i.e. the output page size will not be scaled to fit the currently set output page size. In these cases you may want to make use of the Postscript "scale" operator. Say, you wish to preview the file "butterfly.ps" in just half its size. Enter "0.5 dup scale" and press return, now enter "(butterfly.ps) run" and press return; et voilą: the butterfly will be rendered just half as large as usual. Some documents, such as "porsche.ps", contain no "showpage" command to finish the batch job. In this case, type "showpage" and press return or enter "erasepage" and press return to clear the page. About the Amiga port -------------------- This port is based on Ghostscript 2.6.1. It was implemented using GCC 2.3.3, so you will have to refer to the file "COPYING" for copying and licensing information. This Amiga port was created by: Olaf `Olsen' Barthel Brabeckstrasse 35 D-30559 Hannover Federal Republic of Germany eMail: olsen@sourcery.han.de o.barthel@a-link-h.comlink.de The source code is included in the "amiga-src" drawer.