ImagerPD.mesa
Copyright © 1983, 1984, 1985 by Xerox Corporation. All rights reserved.
Michael Plass, September 18, 1985 4:05:53 pm PDT
Doug Wyatt, April 15, 1985 1:59:11 pm PST
Tim Diebert: February 18, 1986 10:31:24 am PST
N.B. This interface is subject to change! Except in unusual circumstances, clients should not write PD files, but should write Interpress files instead. Refer to the ImagerInterpress interface to do so.
Eric Nickell February 18, 1986 6:30:52 pm PST
DIRECTORY
Imager USING [Context],
ImagerColor USING [CIEChromaticity],
ImagerColorDefs USING [Color, ConstantColor],
ImagerPixelMap USING [PixelMap, Tile],
Rope USING [ROPE];
ImagerPD: CEDAR DEFINITIONS
~ BEGIN OPEN Imager, ImagerColor, ImagerColorDefs, ImagerPixelMap, Rope;
Basic types
PD: TYPE ~ REF PDRep;
PDRep: TYPE;
Toner: TYPE ~ MACHINE DEPENDENT {black(0), cyan(1), magenta(2), yellow(3), last(15)};
Toners: TYPE ~ LIST OF Toner;
PrinterType: TYPE ~ {nil, raven300, raven384, o3, plateMaker, o5, puffin, colorVersatec, versatec, color400, c150, d4020, bw400, o13, o14, o15};
UCR: TYPE ~ RECORD [
blackGamma: REAL ← 0,
blackThreshold: REAL ← 0,
removedFraction: REAL ← 0
];
Basic operations
CreateFromPrinterType: PROC [name: ROPE, printerType: PrinterType, toners: Toners ← NIL, tonerUniverse: Toners ← NIL, pixelsPerHalftoneDot: REAL ← 5.0, ucr: UCR ← []] RETURNS [PD];
CreateFromParameters: PROC [name: ROPE, deviceCode: CARDINAL,
sResolution, fResolution: CARDINAL, -- pixels per inch
imageSSize, imageFSize: CARDINAL, -- pixels
toners: Toners, leftovers: BOOL, bandSSize: NAT, maxLoadWords: INT, fontTuning: ROPENIL, tonerUniverse: Toners ← NIL, pixelsPerHalftoneDot: REAL ← 5.0, ucr: UCR ← []] RETURNS [PD];
DoPage: PROC [pd: PD, action: PROC [context: Context], pixelUnits: BOOLFALSE];
UnimplementedColor: SIGNAL [color: Color];
Close: PROC [pd: PD];
Control of color and halftoning properties
CreateTile: PROC [pixelMap: PixelMap, phase: INTEGER ← 0, copy: BOOLTRUE] RETURNS [tile: Tile];
Like ImagerPixelMap.CreateTile, but does not replicate the pattern.
If copy, forces the entire contents to get copied.
ColorSeparationProc: TYPE ~ PROC [chrom: CIEChromaticity, luminance: REAL, toner: Toner, data: REF] RETURNS [t: REAL];
This procedure is used to do the color separation for ordinary colors, i.e., those that can be reasonably specified in terms of CIE parameters.
SpecialSeparationProc: TYPE ~ PROC [color: ConstantColor, toner: Toner, data: REF] RETURNS [tile: Tile, clear: BOOL];
This procedure is used to do the color separation for other constant colors. It should return a one-bit-per-pixel brick. Use clear=TRUE to specify that the bits should ORed into the page separation bitmap.
SetSeparationProperties: PROC [pd: PD, colorSep: ColorSeparationProc, colorData: REF, specialSep: SpecialSeparationProc, specialData: REF];
SetHalftoneProperties: PROC [pd: PD, toner: Toner, thresholdBrick: Tile];
END.