ImageFFT:
CEDAR
DEFINITIONS ~
BEGIN
Image:
TYPE ~
LIST
OF ComplexSequence;
Each pixel may be a complex value.
ComplexSequence:
TYPE ~ Seq.ComplexSequence;
PixelMap:
TYPE ~ ImagerPixelMaps.PixelMap;
Error:
ERROR [code:
ATOM];
FromPixelMap:
PROC [pixelMap: PixelMap]
RETURNS [a: Image];
Transform:
PROC [a: Image, inverse:
BOOLEAN];
Mul:
PROC [dest, source: Image];
does componentwise multipication.
TransferToPixels:
PROC [dest: ImagerPixelMaps.PixelMap, source: Image, scalar:
REAL];
Transfers the absolute values multiplied by the scalar, clipped to fit.
MakeMask:
PROC [a: Image, threshold:
REAL]
RETURNS [bitmap: PixelMap];
The bitmap has a one bit where the absolute value of the corresponding pixel exceeds the threshold.
ApplyMask:
PROC [a: Image, mask: PixelMap];
Forces all the masked pixels to zero.
Store:
PROC [image: Image, fileName: Rope.
ROPE];
Stores the square image in raw form.
Load:
PROC [fileName: Rope.
ROPE, scratch: Image ←
NIL]
RETURNS [Image];
ScalarMul:
PROC [a: Image, scalar: Complex.Vec];
Add:
PROC [dest, source: Image];
Subtract:
PROC [dest, source: Image];
Width:
PROC [a: Image]
RETURNS [width:
NAT];
Height:
PROC [a: Image]
RETURNS [width:
NAT];
Range:
PROC [a: Image]
RETURNS [xmin, ymin, xmax, ymax:
REAL];
MaskedRange:
PROC [a: Image, bitmap: PixelMap]
RETURNS [xmin, ymin, xmax, ymax:
REAL];
Copy:
PROC [a: Image, scratch: Image ←
NIL]
RETURNS [b: Image];
Destroy:
PROC [a: Image]
RETURNS [Image ←
NIL];
Transpose:
PROC [a: Image]
RETURNS [b: Image];
InSituTranspose:
PROC [a: Image];
TransformRows:
PROC [a: Image, inverse:
BOOLEAN];
END.