Next: Example 5. Transforming a cursor position.
Up: Simple use of TRANSFORM Routines
Previous: Example 4. Plotting a graph of a user-specified function.
Transforming 2-Dimensional Coordinate Data
Transformations which inter-relate 2-dimensional coordinate systems are
common in graphical and image-processing applications, so a set of routines
is provided for applying the associated {
}
mappings to coordinate data.
These routines have names of the form TRN_TR2x, where x is either
I, R or D according to whether the data are
specified by
integer, real or double precision values respectively.
Thus, to apply a compiled {
} mapping to a set of
2-dimensional data points specified by two lists of real coordinates
and
, the following statement might be used:
CALL TRN_TR2R( BAD, NXY, XIN, YIN, ID, XOUT, YOUT, STATUS )
where:
- BAD is a logical value specifying whether the input
coordinates may contain bad values (see
Section
);
- NXY specifies the number of data points to be transformed;
- XIN and YIN are 1-dimensional arrays containing
the
and
coordinates of the input data points;
- ID is an identifier associated with the compiled
{
} mapping to be applied;
- XOUT and YOUT are 1-dimensional arrays to receive
the (transformed)
and
coordinates of the output data
points;
- STATUS is an inherited error status variable.
Subsections
Next: Example 5. Transforming a cursor position.
Up: Simple use of TRANSFORM Routines
Previous: Example 4. Plotting a graph of a user-specified function.
TRANSFORM Coordinate Transformation Facility
Starlink User Note 61
R.F. Warren-Smith
12th January 2006
E-mail:ussc@star.rl.ac.uk
Copyright © 2000 Council for the Central Laboratory of the Research Councils