ImagerImageWorks.mesa
Copyright Ó 1993 by Xerox Corporation. All rights reserved.
Michael Plass, March 29, 1993 3:16 pm PST
DIRECTORY
IO USING [STREAM],
ImagerColor USING [ColorOperator],
ImagerDevice USING [Device],
ImagerPixel USING [PixelMap],
ImagerSample USING [SampleMap],
ImagerTransformation USING [Transformation],
SF USING [Box];
ImagerImageWorks: CEDAR DEFINITIONS
= BEGIN
ColorOperator: PRIVATE TYPE = ImagerColor.ColorOperator;
Device: PRIVATE TYPE = ImagerDevice.Device;
Transformation: PRIVATE TYPE = ImagerTransformation.Transformation;
DrawBufferedImage: PROC [device: Device, buffer: ImagerPixel.PixelMap, box: SF.Box, colorOperator: ColorOperator, pixelToView: Transformation, viewToDevice: Transformation];
Draws a portion of the buffered image, using any data outside of the box for any interpolation or other anti-aliasing that might be done. The box will typically specify most of the image, with only a few scanlines of context from adjacent bands.
Sets the device color to black.
DrawInterleavedImage: PROC [device: Device, buffer: ImagerSample.SampleMap, samplesPerPixel: NAT, box: SF.Box, colorOperator: ColorOperator, pixelToView: Transformation, viewToDevice: Transformation];
Like DrawBufferedImage, but the samples are interleaved in the buffer. Note that the buffer fSize should be >= samplesPerPixel times the box fSize.
Sets the device color to black.
StreamImage: PROC [device: Device, sSize: NAT, fSize: NAT, bitsPerSample: NAT, samplesPerPixel: NAT ¬ 1, padMod: NAT ¬ 8, pixelToView: Transformation, viewToDevice: Transformation, co: ColorOperator, source: IO.STREAM];
Draws the image into the device; takes care of breaking the image into managable pieces.
The image data is pulled from the stream, and is always interleaved, with each scanline starting at a bit index that is zero MOD padMod.
Sets the device color to black.
END.