ANSI-C program: ras_pt.c
NAME
ras_pt - draw point list locations on a SUN/BMP raster image
SYNOPSIS
ras_pt <plist> <pmask> <ras_in>
<ras_out> [rlks] [azlks] [r] [g] [b] [xs] [zflg] [mflg]
[np_ref]
<plist> | (input) point list (int) |
<pmask> | (input) point data stack of mask values (uchar, set to - to accept all points) |
<ras_in> | (input) SUN/BMP raster file (8 or 24 bits/sample, enter - for none) |
<ras_out> | (output) SUN/BMP raster file with marked point list locations |
[rlks] | range looks of raster image relative to point coordinates (default=1.0) |
[azlks] | azimuth looks of raster image relative to point coordinates (default=1.0) |
[r] | cross color value red (0 --> 255, default: 255) |
[g] | cross color value green (0 --> 255, default: 255) |
[b] | cross color value blue (0 --> 255, default: 0) |
[xs] | size of cross in pixels, set to 1 for single points (default: 3) |
[zflg] | zero image flag 0: retain image values (default) 1: set all image values to 0 except crosses |
[mflg] |
point mask flag 0: display points only where pmask[i]=1 (default) 1: display points where pmask[i]=0) 2: display single point (e.g. reference point) specified as position of np_ref |
np_ref | index of single
point to draw |
EXAMPLE
ras_pt plist - hector.mli.ras
hector_pt.mli.ras 1 5
Generates an 8-bit SUN rasterfile which corresponds to the input 8-bit SUN rasterfile testsite.pwr.ras except for yellow crosses added at the coordinates of all points of the point list.
ras_pt plist - hector_rgb.ras hector_rgb_pt.ras 1 5 255 0 0 5
Generates an 24-bit SUN raster image which corresponds to the input 24-bit SUN raster iimage hector_rgb.ras except for enlarged red crosses added at the coordinates of all valid points of the point list.
DESCRIPTION
In the IPTA point lists contain the coordinates (range and
azimuth pixel number relative to the reference SLC geometry) of
the selected points. Data at these points (SLC values,
interferogram values, ...) are stored in point data stacks with
each record corresponding to a different SLC or interferogram.
The point data stack of mask values contains for each point a
flag (0 or 1) which indicates if the data of a point are valid
(1) or not valid (0).
ras_pt supports the generation of a SUN/BMP raster file image which shows the point list locations in the spatial context. As background the input SUN/BMP raster file is used. For the input SUN/BMP raster file (in the "normal" 2-D raster image format) can either be in the SLC geometry used for the point list coordinates or in a multi-looked geometry (relative to the same SLC geometry, without offsets in range and azimuth).
The input SUN/BMP raster file can be 8-bit or 24-bits per sample. The output SUN/BMP raster file will be of the same type as the input SUN/BMP raster file. In the 8-bit case the color of the crosses is added to the color table if there are additional entries possible (initial color table length is less than 256). In the case the number of existing color table entries is 256, pixels belonging to color 255 are moved to color 254 and color 255 is used for the color of the crosses.
For the crosses the color (red, green, blue values in the
range of 0 to 255 ) and the size (in pixels) can be entered on
the command line. Using a size of 1 will plot a single pixel. Up
to a size of 9, the cross is made of lines with single pixel
width. For crosses with size greater or equal to 9, the line
width is increased to 3 pixels.
Instead of using the input SUN/BMP raster file as background
only the crosses can be written to the output raster file if the
image zero flag is set to 1. Using this feature with
a cross size one results in a rasterfile which can serve as a
mask with non-zero values only at the point locations.
Finally it is possible to plot points where the mask values
are 0 rather than 1 by setting the mflg command line parameter to
1. This is useful to determine if groups of points have been lost
possibly due to searching an insufficiently large range of
deformation rates or height differences.
SEE ALSO
ipta.h.