Help for SINPROJ
PURPOSE:
SINPROJ reprojects a vicar image file of a sinusoidal projection of a given
projection longitude into an image file with a different projection longitude,
it also can produce an output file with the same projection longitude but of a
different size, i.e. sinproj will not change the pixel size of the image but
will change the width of the image by only reprojecting a fraction of the
original image.
SINPROJ expects the projection longitude (PROJ_LON), the starting (LON_CL) and
ending (LON_CR) longitudes, and the starting (LAT_UC) and ending (LAT_LC)
latitudes for the output file to be specified, although all these values can
be defaulted or specified by line and sample instead, with SINPROJ converting
them from one to another internally. The input image file should also have
these keys in its vicar label because they are needed to recalculate the new
projection and are are used as the default values if none are specified in the
parameters.
When SINPROJ is run with LON_CL and LON_CR specifying the size of the output
image and PROJ_LON not specified the projection longitude will default to the
longitude midway between LON_CL and LON_CR; similarly if only SS and NS are
specified PROJSAMP will be set to SS + NS/2. SINPROJ cannot reproject an image
into an oblique sinusoidal projection. If LAT_UC and LAT_LC are specified to be
smaller in the output image than they are in original image, the output image
will simply cut off at those latitudes. The equator is always taken to be the
latitude from which the projection is calculated.
examples
if the input image file has in its label:
PROJ_LON = 180.0
LON_CL = 0.0 LON_CR = 360.0
LAT_UC = 90.0 LAT_LC = -90.0
SINPROJ inp out PROJ_LON=0
output image is very lopsided with all of the image to the right
of the projection longitude (you probably don't want this) and
contains all of the input image
SINPROJ inp out PROJ_LON=0 LON_CL=180 LON_CR = 179
output image is centered around the projection longitude
SINPROJ inp out LON_CL=180 LON_CR = 220
output image is centered on a projection longitude of 200
and is only 1/9th as wide as the input image
SINPROJ inp out SS = 360 NS = 80
this will do the same as the previous example if there are
two samples per degree
HISTORY
Original Author: ???
Cognizant Programmer: m. jentoft-nilsen
history:
1990-02-22 FR 52797 mj-n
1992-03-06 MJ-N - mcr 1290 allow projections with lon_cl
or lon_cr outside of original longitude range of an
image
1995-01-02 J. Turner (CRI) - Made portable for UNIX
2019-09-17 W. Bunch - IDS-7922 - Initialized a variable; cleaned up -Wall warnings.
Partially ported "bin" to UNIX to obtain "weight" and "terrain" input
files used by tstsinproj.pdf. Add those and tstsinproj.log to git.
PARAMETERS:
INP
input image file
OUT
output image file
LON_CL
output left longitude
LON_CR
output right longitude
LAT_UC
output upper latitude
LAT_LC
output lower latitude
PROJ_LON
output projection longitude
SIZE
standard vicar size field
SL
starting line
SS
starting sample
NL
number of lines
NS
number of samples
PROJSAMP
sample number of the
output projection longitude
in input file sample
numbering
See Examples:
Cognizant Programmer: