ImagerMasksPrivate.mesa
Michael Plass, September 29, 1983 1:31 pm
Edited by Doug Wyatt, November 22, 1983 11:47 am
Provides reader-style access to masks as runs.
DIRECTORY
ImagerMasks USING [Mask, RunBlock, RunsRep];
ImagerMasksPrivate: CEDAR DEFINITIONS
~ BEGIN
Mask: TYPE ~ ImagerMasks.Mask;
Representation: TYPE ~ {bitmap, runs, box};
Reader: TYPE ~ RECORD [
s, fMin, fMax: INTEGER,
firstRunOnLine: BOOLEAN,
repeatCount: CARDINAL,
done: BOOLEAN,
fTranslate: INTEGER,
index: CARDINAL,
refRep: REF,
representation: Representation,
bitmap =>
currentWord: INTEGER, -- the valid bits are high-order; non-valid bits are zero.
validBitCount: CARDINAL,
currentLinePtr: LONG POINTER,
nextWordPtr: LONG POINTER TO INTEGER,
fCurrent: CARDINAL,
fSize: CARDINAL,
sMax: INTEGER,
wordsPerLine: CARDINAL,
runs =>
blockDirectory: REF ImagerMasks.RunsRep,
blockDirectoryIndex: CARDINAL,
runBlock: ImagerMasks.RunBlock,
lineStartBlockDirectoryIndex: CARDINAL,
lineStartIndex: CARDINAL
];
SetReader: UNSAFE PROC [reader: POINTER TO Reader, mask: Mask];
Advance: UNSAFE PROC [r: POINTER TO Reader];
SkipTo: UNSAFE PROC [r: POINTER TO Reader, s: INTEGER];
END.