DIRECTORY ImagerColor USING [Color], ImagerPixelMap USING [DeviceRectangle], ImagerTransformation USING [Transformation], Vector2 USING [VEC]; ImagerDevice: CEDAR DEFINITIONS ~ BEGIN Color: TYPE ~ ImagerColor.Color; DeviceRectangle: TYPE ~ ImagerPixelMap.DeviceRectangle; Transformation: TYPE ~ ImagerTransformation.Transformation; VEC: TYPE ~ Vector2.VEC; HalftoneParameters: TYPE ~ RECORD[ dotsPerInch: REAL, angle: REAL, -- degrees anticlockwise from +x axis shape: REAL -- 0.5 is circular ]; RunProc: TYPE ~ PROC[sMin, fMin: INTEGER, fSize: NAT]; Device: TYPE ~ REF DeviceRep; DeviceRep: TYPE ~ RECORD[ class: Class, clipBox: DeviceRectangle, -- bounding rectangle, in device coordinates surfaceToDevice: Transformation, -- transformation from surface to device coordinates surfaceUnitsPerInch: VEC, -- x and y scale factors surfaceUnitsPerPixel: NAT, -- surface resolution may be a multiple of pixel resolution data: REF ]; Class: TYPE ~ REF ClassRep; ClassRep: TYPE ~ RECORD[ type: ATOM, SetColor: PROC[device: Device, color: Color, viewToDevice: Transformation], SetPriority: PROC[device: Device, priorityImportant: BOOL], SetHalftone: PROC[device: Device, halftone: HalftoneParameters], MaskRuns: PROC[device: Device, runs: PROC[RunProc]] ]; SetColor: PROC[device: Device, color: Color, viewToDevice: Transformation] ~ INLINE { device.class.SetColor[device: device, color: color, viewToDevice: viewToDevice] }; SetPriority: PROC[device: Device, priorityImportant: BOOL] ~ INLINE { device.class.SetPriority[device: device, priorityImportant: priorityImportant] }; SetHalftone: PROC[device: Device, halftone: HalftoneParameters] ~ INLINE { device.class.SetHalftone[device: device, halftone: halftone] }; MaskRuns: PROC[device: Device, runs: PROC[RunProc]] ~ INLINE { device.class.MaskRuns[device: device, runs: runs] }; END. <ImagerDevice.mesa Copyright c 1984 Xerox Corporation. All rights reserved. Doug Wyatt, October 19, 1984 11:13:09 am PDT Establish the color for following masks. Declare whether priority order is important for following masks. Set halftoning parameters. Apply the current color within the specified runs. ÊŠ˜šœ™Jšœ Ïmœ.™9Jšœ,™,—J˜šÏk ˜ Jšœ žœ ˜Jšœžœ˜'Jšœžœ˜,Jšœžœžœ˜J˜—Jšœžœž ˜Jšœž˜J˜Jšœžœ˜ Jšœžœ"˜7Jšœžœ'˜;Jšžœžœ žœ˜J˜šœžœžœ˜"Jšœ žœ˜JšœžœÏc%˜2JšœžœŸ˜J˜J˜—š œ žœžœ žœ žœ˜6J˜—Jšœžœžœ ˜šœ žœžœ˜Jšœ ˜ JšœŸ,˜FJšœ!Ÿ4˜UJšœžœŸ˜2JšœžœŸ;˜VJšœž˜ Jšœ˜J˜—Jšœžœžœ ˜šœ žœžœ˜Jšœžœ˜ JšÏnœžœ=˜KJš  œžœ$žœ˜;Jš  œžœ/˜@Jš œžœžœ ˜3J˜J˜—š œžœ<˜JJšœžœU˜]Jšœ(™(J™—š  œžœ$žœ˜:JšœžœT˜\Jšœ@™@J™—š  œžœ.˜?JšœžœB˜JJšœ™J™—š œžœžœ ˜3Jšœžœ7˜?Jšœ2™2J™—J˜Jšžœ˜—…—2 ø