<> <<>> <> <<>> <> <> <> <> <<>> ImagerTransform: CEDAR DEFINITIONS = BEGIN Pair: TYPE ~ RECORD [x, y: REAL]; Rectangle: TYPE ~ RECORD [x, y, w, h: REAL]; IntRectangle: TYPE ~ RECORD [x, y, w, h: INTEGER]; Transformation: TYPE ~ REF TransformationRep; TransformationRep: TYPE ~ PRIVATE RECORD [a, b, c, d, e, f: --READONLY-- REAL]; TransformationRec: TYPE ~ RECORD [a, b, c, d, e, f: REAL]; <> <<>> Contents: PROC [m: Transformation] RETURNS [TransformationRec] ~ INLINE {RETURN [[m.a, m.b, m.c, m.d, m.e, m.f]]}; <> <<>> Translate: PROC [dx, dy: REAL] RETURNS [Transformation]; Scale: PROC [s: REAL] RETURNS [Transformation]; Scale2: PROC [sx, sy: REAL] RETURNS [Transformation]; Rotate: PROC [degrees: REAL] RETURNS [Transformation]; Concat: PROC [pre, post: Transformation] RETURNS [Transformation]; Invert: PROC [m: Transformation] RETURNS [Transformation]; Create: PROC [a, b, c, d, e, f: REAL] RETURNS [Transformation]; FromRec: PROC [t: TransformationRec] RETURNS [Transformation]; <> <<>> PreTranslate: PROC [dx, dy: REAL, m: Transformation] RETURNS [Transformation]; PreScale: PROC [s: REAL, m: Transformation] RETURNS [Transformation]; PreScale2: PROC [sx, sy: REAL, m: Transformation] RETURNS [Transformation]; PreRotate: PROC [degrees: REAL, m: Transformation] RETURNS [Transformation]; <<>> <> <<>> Transform: PROC [p: Pair, transform: Transformation] RETURNS [Pair]; InverseTransform: PROC [p: Pair, transform: Transformation] RETURNS [Pair]; TransformVec: PROC [p: Pair, transform: Transformation] RETURNS [Pair]; InverseTransformVec: PROC [p: Pair, transform: Transformation] RETURNS [Pair]; <<>> <> <<>> CloseEnough: PROC [s, t: Transformation, rangeSize: REAL _ 2000.0] RETURNS [BOOLEAN]; <> CloseToTranslation: PROC [s, t: Transformation, rangeSize: REAL _ 2000.0] RETURNS [BOOLEAN]; <> <> <<>> TransformRectangle: PROC [rect: Rectangle, transform: Transformation] RETURNS [Rectangle]; TransformIntRectangle: PROC [rect: Rectangle, transform: Transformation] RETURNS [IntRectangle]; <> SingularValues: PROC [transform: Transformation] RETURNS [Pair]; -- Returns the singular values of the non-translation portion of the transform. These are the square roots of the eigenvalues of the symmetric matrix MMT, where M is the non-translation portion. The x component is the larger of the two. These correspond to the maximum and minimum magnitudes that the image of a unit vector can achive. END.