andy@cbmvax.UUCP (02/06/87)
At the suggestion of Dave B (thanks, Dave), and for all those who need them
*now*, here are the latest printer.device graphics autodocs.
andy finkel
------------------
Printer autodocs
(c) Copyright 1986, 1987 Commodore-Amiga, Inc.
/****** printer.device/DumpRPort *************************************
*
* NAME
* DumpRPort - dump the specified RastPort to a graphics printer.
*
* FUNCTION
* Print a rendition of the supplied RastPort, using the supplied
* ColorMap, position and scaling information, as specified in
* the printer preferences.
*
* IO REQUEST
* io_Message mn_ReplyPort set if quick I/O is not possible
* io_Command PRD_DUMPRPORT
* io_Flags IOB_QUICK set if quick I/O is possible
* io_RastPort ptr to a RastPort.
* io_ColorMap ptr to a ColorMap.
* io_Modes the 'modes' flag as from a ViewPort structure
* the upper word is reserved and should be zero
* io_SrcX the x offset into the RastPort
* io_SrcY the y offset into the RastPort
* io_SrcWidth the x size in the RastPort to be printed
* io_SrcHeight the y size in the RastPort to be printed
* io_DestCols ...
* io_DestRows these two parameters describe the size of the
* area to print to on the printer, as described
* below.
* io_Special interpretation of Dest parameters:
* - if SPECIAL_MIL is set, then the associated
* parameter is specified in thousandths of
* an inch on the printer.
* - if SPECIAL_FULL is set, then the dimension
* is set to the maximum possible (as
* determined by the printer limits or the
* configuration limits, whichever is less).
* - if SPECIAL_FRAC is set, the parameter is
* taken to be a longword binary fraction
* of the maximum for that dimension.
* - if ASPECT is set, one of the dimensions
* may be reduced to preserve the aspect
* ratio of the print.
* - if all bits for a dimension are clear, the
* parameter is specified in printer pixels.
* - if SPECIAL_DENSITY(1-4) is set, then the
* printer specific driver has the option of
* selecting a different dots per inch density
* (dpi) than the default one. As of this writing,
* the printer specific modules supporting this
* feature are the HP_LASERJET & the HP_LASERJET_PLUS.
* For these two printers, the densities are
* 75, 100, 150 & 300 dpi respectively. The HP_LASERJET
* always defaults to 75 dpi. The HP_LASERJET_PLUS
* defaults to 100 dpi if the preferences is set to
* DRAFT quality and 150 dpi with LETTER quality.
* - if SPECIAL_CENTER is set, then the picture will be
* horizontally centered on the paper.
*
* There following rules for the interpretation of io_DestRows and
* io_DestCols that may produce unexpected results when they are
* not greater than zero and io_Special is zero. They have been
* retained for compatability. The user will not trigger these
* other rules with well formed usage of io_Special.
*
* When io_Special is equal to 0, the following rules
* (from the V1.1 printer.device, and retained for compatibility
* reasons) take effect. Remember, these special rules are
* for io_DestRows and io_DestCols and only take effect
* IF io_Special is 0).
*
* a) DestCols>0 & DestRows>0 - use as absolute values.
* ie. DestCols=320 & DestRows=200 means that the picture
* will appear on the printer as 320x200 dots.
* b) DestCols=0 & DestRows>0 - use the printers maximum number
* of columns and print DestRows lines. ie. if DestCols=0
* and DestRows=200 than the picture will appear on the
* printer as wide as it can be and 200 dots high.
* c) DestCols=0 & DestRows=0 - same as above except the driver
* determines the proper number of lines to print based on
* the aspect ratio of the printer. ie. This results in the
* largest picture possible that is not distorted or inverted.
* Note: As of this writing, this is the call made by such
* program as DeluxePaint, GraphicCraft, and AegisImages.
* d) DestCols>0 &DestRows=0 - use the specified width and the
* driver determines the proper number of lines to print based
* on the aspect ratio of the printer. ie. if you desire a
* picture that is 500 pixels wide and aspect ratio correct,
* use DestCols=500 and DestRows=0.
* e) DestCols<0 or DestRows>0 - the final picture is either a
* reduction or expansion based on the fraction
* |DestCols| / DestRows in the proper aspect ratio.
* Some examples:
* 1) if DestCols=-2 & DestRows=1 then the printed picture will
* be 2x the AMIGA picture and in the proper aspect ratio.
* (2x is derived from |-2| / 1 which gives 2.0)
* 2) if DestCols=-1 & DestRows=2 then the printed picture will
* will be 1/2x the AMIGA picture in the proper aspect ratio.
* (1/2x is derived from |-1| / 2 which gives 0.5)
*
* HINTS
* The printer selected in preferences must have graphics
* capability to use this command. An error is returned
* immediately if the printer can not print graphics.
*
* Color printers may not be able to print black and white or
* greyscale pictures -- specifically, the Okimate 20 cannot
* print these with a color ribbon: you must use a black
* ribbon instead.
* If the printer has an input buffer option, use it.
* If the printer can be uni- or bi-directional, select
* uni-directional; this produces a much cleaner picture and
* in some cases a faster printout. Most printer drivers
* will attempt to set unidirectional printing if it is
* under software control.
*
* Please note that the width and height of the printable area on
* the printer is in terms of pixels and bounded by the folllowing:
* a) WIDTH = (RIGHT_MARGIN - LEFT_MARGIN + 1) / CHARACTERS_PER_INCH
* b) HEIGHT = LENGTH / LINES_PER_INCH
* Margins are set by preferences.
*
* For BGR printer support, the YMC values in the printer
* specific render.c functions equate to BGR respectively, ie.
* yellow is blue, magenta is green, and cyan is red.
*
*********************************************************************/
--
andy finkel
Commodore/Amiga
{ihnp4|seismo|allegra}!cbmvax!andy /or/ pyramid!amiga!andy
Any expressed opinions are mine; but feel free to share.
I disclaim all responsibilities, all shapes, all sizes, all colors.
"Never make anything simple and efficient when it can be complex and wonderful."