--File CGBrick.mesa
--Last edited  By Pier,      22-Feb-82 10:03:36

DIRECTORY;

CGBrick: DEFINITIONS = {

--Types and Variables

BrickHandle: TYPE = REF Brick;
Brick: TYPE = RECORD
      [L, p: CARDINAL,           --dimensions of the matrix always positive
       D: INTEGER,               --shift value of succeeding matrix repetition
       u, v: CARDINAL,           --values matrix was derived from
       cBrick: SEQUENCE size: NAT OF REAL
      ];
      
currentBrick: REF BrickHandle;--global storage for the current brick

--Procedures

BuildBrick: PROC[freq: REAL, angle: REAL, filter: PROC[x,y:REAL] RETURNS [fvalue: REAL]]
            RETURNS [bH: BrickHandle];

FreeBrick: PROC[pbH: REF BrickHandle];
   
GetSize: PROC[bH: BrickHandle] RETURNS [L,p: CARDINAL, D: INTEGER];--brick is L long and p high
   
GetElement: PROC[bH: BrickHandle, x,y: CARDINAL] RETURNS [bElement: REAL];
   
GetCurrentBrick: PROC RETURNS [REF BrickHandle];
   
GetRow: PROC[bH: BrickHandle, x,y: CARDINAL] RETURNS [row: CARDINAL];
   
GetCol: PROC[bH: BrickHandle, x,y: CARDINAL] RETURNS [col: CARDINAL];
   
CGBrickImpl: PROGRAM;

}. --of CGBrick

LOG

--Created 21-Oct-81 11:27:15 By Pier
--changed BrickHandle to REF
--reformatted, 19-JAN-82
--changed brick definition to use L,p,D,cBrick field names, 2/22/82