WCSLIB 8.2.2
|
Go to the source code of this file.
Data Structures | |
struct | prjprm |
Projection parameters. More... | |
Macros | |
#define | PVN 30 |
Total number of projection parameters. | |
#define | PRJX2S_ARGS |
For use in declaring deprojection function prototypes. | |
#define | PRJS2X_ARGS |
For use in declaring projection function prototypes. | |
#define | PRJLEN (sizeof(struct prjprm)/sizeof(int)) |
Size of the prjprm struct in int units. | |
#define | prjini_errmsg prj_errmsg |
Deprecated. | |
#define | prjprt_errmsg prj_errmsg |
Deprecated. | |
#define | prjset_errmsg prj_errmsg |
Deprecated. | |
#define | prjx2s_errmsg prj_errmsg |
Deprecated. | |
#define | prjs2x_errmsg prj_errmsg |
Deprecated. | |
Enumerations | |
enum | prj_errmsg_enum { PRJERR_SUCCESS = 0 , PRJERR_NULL_POINTER = 1 , PRJERR_BAD_PARAM = 2 , PRJERR_BAD_PIX = 3 , PRJERR_BAD_WORLD = 4 } |
Functions | |
int | prjini (struct prjprm *prj) |
Default constructor for the prjprm struct. | |
int | prjfree (struct prjprm *prj) |
Destructor for the prjprm struct. | |
int | prjsize (const struct prjprm *prj, int sizes[2]) |
Compute the size of a prjprm struct. | |
int | prjprt (const struct prjprm *prj) |
Print routine for the prjprm struct. | |
int | prjperr (const struct prjprm *prj, const char *prefix) |
Print error messages from a prjprm struct. | |
int | prjbchk (double tol, int nphi, int ntheta, int spt, double phi[], double theta[], int stat[]) |
Bounds checking on native coordinates. | |
int | prjset (struct prjprm *prj) |
Generic setup routine for the prjprm struct. | |
int | prjx2s (PRJX2S_ARGS) |
Generic Cartesian-to-spherical deprojection. | |
int | prjs2x (PRJS2X_ARGS) |
Generic spherical-to-Cartesian projection. | |
int | azpset (struct prjprm *prj) |
Set up a prjprm struct for the zenithal/azimuthal perspective (AZP ) projection. | |
int | azpx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the zenithal/azimuthal perspective (AZP ) projection. | |
int | azps2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the zenithal/azimuthal perspective (AZP ) projection. | |
int | szpset (struct prjprm *prj) |
Set up a prjprm struct for the slant zenithal perspective (SZP ) projection. | |
int | szpx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the slant zenithal perspective (SZP ) projection. | |
int | szps2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the slant zenithal perspective (SZP ) projection. | |
int | tanset (struct prjprm *prj) |
Set up a prjprm struct for the gnomonic (TAN ) projection. | |
int | tanx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the gnomonic (TAN ) projection. | |
int | tans2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the gnomonic (TAN ) projection. | |
int | stgset (struct prjprm *prj) |
Set up a prjprm struct for the stereographic (STG ) projection. | |
int | stgx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the stereographic (STG ) projection. | |
int | stgs2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the stereographic (STG ) projection. | |
int | sinset (struct prjprm *prj) |
Set up a prjprm struct for the orthographic/synthesis (SIN ) projection. | |
int | sinx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the orthographic/synthesis (SIN ) projection. | |
int | sins2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the orthographic/synthesis (SIN ) projection. | |
int | arcset (struct prjprm *prj) |
Set up a prjprm struct for the zenithal/azimuthal equidistant (ARC ) projection. | |
int | arcx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the zenithal/azimuthal equidistant (ARC ) projection. | |
int | arcs2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the zenithal/azimuthal equidistant (ARC ) projection. | |
int | zpnset (struct prjprm *prj) |
Set up a prjprm struct for the zenithal/azimuthal polynomial (ZPN ) projection. | |
int | zpnx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the zenithal/azimuthal polynomial (ZPN ) projection. | |
int | zpns2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the zenithal/azimuthal polynomial (ZPN ) projection. | |
int | zeaset (struct prjprm *prj) |
Set up a prjprm struct for the zenithal/azimuthal equal area (ZEA ) projection. | |
int | zeax2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the zenithal/azimuthal equal area (ZEA ) projection. | |
int | zeas2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the zenithal/azimuthal equal area (ZEA ) projection. | |
int | airset (struct prjprm *prj) |
Set up a prjprm struct for Airy's (AIR ) projection. | |
int | airx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for Airy's (AIR ) projection. | |
int | airs2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for Airy's (AIR ) projection. | |
int | cypset (struct prjprm *prj) |
Set up a prjprm struct for the cylindrical perspective (CYP ) projection. | |
int | cypx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the cylindrical perspective (CYP ) projection. | |
int | cyps2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the cylindrical perspective (CYP ) projection. | |
int | ceaset (struct prjprm *prj) |
Set up a prjprm struct for the cylindrical equal area (CEA ) projection. | |
int | ceax2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the cylindrical equal area (CEA ) projection. | |
int | ceas2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the cylindrical equal area (CEA ) projection. | |
int | carset (struct prjprm *prj) |
Set up a prjprm struct for the plate carrée (CAR ) projection. | |
int | carx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the plate carrée (CAR ) projection. | |
int | cars2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the plate carrée (CAR ) projection. | |
int | merset (struct prjprm *prj) |
Set up a prjprm struct for Mercator's (MER ) projection. | |
int | merx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for Mercator's (MER ) projection. | |
int | mers2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for Mercator's (MER ) projection. | |
int | sflset (struct prjprm *prj) |
Set up a prjprm struct for the Sanson-Flamsteed (SFL ) projection. | |
int | sflx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the Sanson-Flamsteed (SFL ) projection. | |
int | sfls2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the Sanson-Flamsteed (SFL ) projection. | |
int | parset (struct prjprm *prj) |
Set up a prjprm struct for the parabolic (PAR ) projection. | |
int | parx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the parabolic (PAR ) projection. | |
int | pars2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the parabolic (PAR ) projection. | |
int | molset (struct prjprm *prj) |
Set up a prjprm struct for Mollweide's (MOL ) projection. | |
int | molx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for Mollweide's (MOL ) projection. | |
int | mols2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for Mollweide's (MOL ) projection. | |
int | aitset (struct prjprm *prj) |
Set up a prjprm struct for the Hammer-Aitoff (AIT ) projection. | |
int | aitx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the Hammer-Aitoff (AIT ) projection. | |
int | aits2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the Hammer-Aitoff (AIT ) projection. | |
int | copset (struct prjprm *prj) |
Set up a prjprm struct for the conic perspective (COP ) projection. | |
int | copx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the conic perspective (COP ) projection. | |
int | cops2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the conic perspective (COP ) projection. | |
int | coeset (struct prjprm *prj) |
Set up a prjprm struct for the conic equal area (COE ) projection. | |
int | coex2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the conic equal area (COE ) projection. | |
int | coes2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the conic equal area (COE ) projection. | |
int | codset (struct prjprm *prj) |
Set up a prjprm struct for the conic equidistant (COD ) projection. | |
int | codx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the conic equidistant (COD ) projection. | |
int | cods2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the conic equidistant (COD ) projection. | |
int | cooset (struct prjprm *prj) |
Set up a prjprm struct for the conic orthomorphic (COO ) projection. | |
int | coox2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the conic orthomorphic (COO ) projection. | |
int | coos2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the conic orthomorphic (COO ) projection. | |
int | bonset (struct prjprm *prj) |
Set up a prjprm struct for Bonne's (BON ) projection. | |
int | bonx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for Bonne's (BON ) projection. | |
int | bons2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for Bonne's (BON ) projection. | |
int | pcoset (struct prjprm *prj) |
Set up a prjprm struct for the polyconic (PCO ) projection. | |
int | pcox2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the polyconic (PCO ) projection. | |
int | pcos2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the polyconic (PCO ) projection. | |
int | tscset (struct prjprm *prj) |
Set up a prjprm struct for the tangential spherical cube (TSC ) projection. | |
int | tscx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the tangential spherical cube (TSC ) projection. | |
int | tscs2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the tangential spherical cube (TSC ) projection. | |
int | cscset (struct prjprm *prj) |
Set up a prjprm struct for the COBE spherical cube (CSC ) projection. | |
int | cscx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the COBE spherical cube (CSC ) projection. | |
int | cscs2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the COBE spherical cube (CSC ) projection. | |
int | qscset (struct prjprm *prj) |
Set up a prjprm struct for the quadrilateralized spherical cube (QSC ) projection. | |
int | qscx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the quadrilateralized spherical cube (QSC ) projection. | |
int | qscs2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the quadrilateralized spherical cube (QSC ) projection. | |
int | hpxset (struct prjprm *prj) |
Set up a prjprm struct for the HEALPix (HPX ) projection. | |
int | hpxx2s (PRJX2S_ARGS) |
Cartesian-to-spherical transformation for the HEALPix (HPX ) projection. | |
int | hpxs2x (PRJS2X_ARGS) |
Spherical-to-Cartesian transformation for the HEALPix (HPX ) projection. | |
int | xphset (struct prjprm *prj) |
int | xphx2s (PRJX2S_ARGS) |
int | xphs2x (PRJS2X_ARGS) |
Variables | |
const char * | prj_errmsg [] |
Status return messages. | |
const int | CONIC |
Identifier for conic projections. | |
const int | CONVENTIONAL |
Identifier for conventional projections. | |
const int | CYLINDRICAL |
Identifier for cylindrical projections. | |
const int | POLYCONIC |
Identifier for polyconic projections. | |
const int | PSEUDOCYLINDRICAL |
Identifier for pseudocylindrical projections. | |
const int | QUADCUBE |
Identifier for quadcube projections. | |
const int | ZENITHAL |
Identifier for zenithal/azimuthal projections. | |
const int | HEALPIX |
Identifier for the HEALPix projection. | |
const char | prj_categories [9][32] |
Projection categories. | |
const int | prj_ncode |
The number of recognized three-letter projection codes. | |
const char | prj_codes [28][4] |
Recognized three-letter projection codes. | |
Routines in this suite implement the spherical map projections defined by the FITS World Coordinate System (WCS) standard, as described in
These routines are based on the prjprm struct which contains all information needed for the computations. The struct contains some members that must be set by the user, and others that are maintained by these routines, somewhat like a C++ class but with no encapsulation.
Routine prjini() is provided to initialize the prjprm struct with default values, prjfree() reclaims any memory that may have been allocated to store an error message, prjsize() computes its total size including allocated memory, and prjprt() prints its contents.
prjperr() prints the error message(s) (if any) stored in a prjprm struct. prjbchk() performs bounds checking on native spherical coordinates.
Setup routines for each projection with names of the form ???set(), where "???" is the down-cased three-letter projection code, compute intermediate values in the prjprm struct from parameters in it that were supplied by the user. The struct always needs to be set by the projection's setup routine but that need not be called explicitly - refer to the explanation of prjprm::flag.
Each map projection is implemented via separate functions for the spherical projection, ???s2x(), and deprojection, ???x2s().
A set of driver routines, prjset(), prjx2s(), and prjs2x(), provides a generic interface to the specific projection routines which they invoke via pointers-to-functions stored in the prjprm struct.
In summary, the routines are:
prjbchk() Bounds checking on native coordinates.
AZP
(zenithal/azimuthal perspective) SZP
(slant zenithal perspective) TAN
(gnomonic) STG
(stereographic) SIN
(orthographic/synthesis) ARC
(zenithal/azimuthal equidistant) ZPN
(zenithal/azimuthal polynomial) ZEA
(zenithal/azimuthal equal area) AIR
(Airy) CYP
(cylindrical perspective) CEA
(cylindrical equal area) CAR
(Plate carée) MER
(Mercator) SFL
(Sanson-Flamsteed) PAR
(parabolic) MOL
(Mollweide) AIT
(Hammer-Aitoff) COP
(conic perspective) COE
(conic equal area) COD
(conic equidistant) COO
(conic orthomorphic) BON
(Bonne) PCO
(polyconic) TSC
(tangential spherical cube) CSC
(COBE spherical cube) QSC
(quadrilateralized spherical cube) HPX
(HEALPix) Argument checking (projection routines):
The values of and (the native longitude and latitude) normally lie in the range for , and for . However, all projection routines will accept any value of and will not normalize it.
The projection routines do not explicitly check that lies within the range . They do check for any value of that produces an invalid argument to the projection equations (e.g. leading to division by zero). The projection routines for AZP
, SZP
, TAN
, SIN
, ZPN
, and COP
also return error 2 if corresponds to the overlapped (far) side of the projection but also return the corresponding value of . This strict bounds checking may be relaxed at any time by setting prjprm::bounds%2 to 0 (rather than 1); the projections need not be reinitialized.
Argument checking (deprojection routines):
Error checking on the projected coordinates is limited to that required to ascertain whether a solution exists. Where a solution does exist, an optional check is made that the value of and obtained lie within the ranges for , and for . This check, performed by prjbchk(), is enabled by default. It may be disabled by setting prjprm::bounds%4 to 0 (rather than 1); the projections need not be reinitialized.
Accuracy:
No warranty is given for the accuracy of these routines (refer to the copyright notice); intending users must satisfy for themselves their adequacy for the intended purpose. However, closure to a precision of at least of longitude and latitude has been verified for typical projection parameters on the degree graticule of native longitude and latitude (to within of any latitude where the projection may diverge). Refer to the tprj1.c and tprj2.c test routines that accompany this software.
#define PVN 30 |
Total number of projection parameters.
The total number of projection parameters numbered 0 to PVN-1.
#define PRJX2S_ARGS |
For use in declaring deprojection function prototypes.
Preprocessor macro used for declaring deprojection function prototypes.
#define PRJS2X_ARGS |
For use in declaring projection function prototypes.
Preprocessor macro used for declaring projection function prototypes.
#define PRJLEN (sizeof(struct prjprm)/sizeof(int)) |
#define prjini_errmsg prj_errmsg |
Deprecated.
#define prjprt_errmsg prj_errmsg |
Deprecated.
#define prjset_errmsg prj_errmsg |
Deprecated.
#define prjx2s_errmsg prj_errmsg |
Deprecated.
#define prjs2x_errmsg prj_errmsg |
Deprecated.
enum prj_errmsg_enum |
int prjini | ( | struct prjprm * | prj | ) |
Default constructor for the prjprm struct.
prjini() sets all members of a prjprm struct to default values. It should be used to initialize every prjprm struct.
PLEASE NOTE: If the prjprm struct has already been initialized, then before reinitializing, it prjfree() should be used to free any memory that may have been allocated to store an error message. A memory leak may otherwise result.
[out] | prj | Projection parameters. |
int prjfree | ( | struct prjprm * | prj | ) |
int prjsize | ( | const struct prjprm * | prj, |
int | sizes[2] | ||
) |
Compute the size of a prjprm struct.
prjsize() computes the full size of a prjprm struct, including allocated memory.
[in] | prj | Projection parameters. If NULL, the base size of the struct and the allocated size are both set to zero. |
[out] | sizes | The first element is the base size of the struct as returned by sizeof(struct prjprm). The second element is the total allocated size, in bytes. This figure includes memory allocated for the constituent struct, prjprm::err. It is not an error for the struct not to have been set up via prjset(). |
int prjprt | ( | const struct prjprm * | prj | ) |
Print routine for the prjprm struct.
prjprt() prints the contents of a prjprm struct using wcsprintf(). Mainly intended for diagnostic purposes.
[in] | prj | Projection parameters. |
int prjperr | ( | const struct prjprm * | prj, |
const char * | prefix | ||
) |
Print error messages from a prjprm struct.
prjperr() prints the error message(s) (if any) stored in a prjprm struct. If there are no errors then nothing is printed. It uses wcserr_prt(), q.v.
[in] | prj | Projection parameters. |
[in] | prefix | If non-NULL, each output line will be prefixed with this string. |
int prjbchk | ( | double | tol, |
int | nphi, | ||
int | ntheta, | ||
int | spt, | ||
double | phi[], | ||
double | theta[], | ||
int | stat[] | ||
) |
Bounds checking on native coordinates.
prjbchk() performs bounds checking on native spherical coordinates. As returned by the deprojection (x2s) routines, native longitude is expected to lie in the closed interval , with latitude in .
A tolerance may be specified to provide a small allowance for numerical imprecision. Values that lie outside the allowed range by not more than the specified tolerance will be adjusted back into range.
If prjprm::bounds&4 is set, as it is by prjini(), then prjbchk() will be invoked automatically by the Cartesian-to-spherical deprojection (x2s) routines with an appropriate tolerance set for each projection.
[in] | tol | Tolerance for the bounds check [deg]. |
[in] | nphi,ntheta | Vector lengths. |
[in] | spt | Vector stride. |
[in,out] | phi,theta | Native longitude and latitude [deg]. |
[out] | stat | Status value for each vector element:
|
int prjset | ( | struct prjprm * | prj | ) |
Generic setup routine for the prjprm struct.
prjset() sets up a prjprm struct according to information supplied within it.
Note that this routine need not be called directly; it will be invoked by prjx2s() and prjs2x() if prj.flag is anything other than a predefined magic value.
The one important distinction between prjset() and the setup routines for the specific projections is that the projection code must be defined in the prjprm struct in order for prjset() to identify the required projection. Once prjset() has initialized the prjprm struct, prjx2s() and prjs2x() use the pointers to the specific projection and deprojection routines contained therein.
[in,out] | prj | Projection parameters. |
int prjx2s | ( | PRJX2S_ARGS | ) |
Generic Cartesian-to-spherical deprojection.
Deproject Cartesian coordinates in the plane of projection to native spherical coordinates .
The projection is that specified by prjprm::code.
[in,out] | prj | Projection parameters. |
[in] | nx,ny | Vector lengths. |
[in] | sxy,spt | Vector strides. |
[in] | x,y | Projected coordinates. |
[out] | phi,theta | Longitude and latitude of the projected point in native spherical coordinates [deg]. |
[out] | stat | Status value for each vector element:
|
int prjs2x | ( | PRJS2X_ARGS | ) |
Generic spherical-to-Cartesian projection.
Project native spherical coordinates to Cartesian coordinates in the plane of projection.
The projection is that specified by prjprm::code.
[in,out] | prj | Projection parameters. |
[in] | nphi,ntheta | Vector lengths. |
[in] | spt,sxy | Vector strides. |
[in] | phi,theta | Longitude and latitude of the projected point in native spherical coordinates [deg]. |
[out] | x,y | Projected coordinates. |
[out] | stat | Status value for each vector element:
|
int azpset | ( | struct prjprm * | prj | ) |
int azpx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the zenithal/azimuthal perspective (AZP
) projection.
azpx2s() deprojects Cartesian coordinates in the plane of a zenithal/azimuthal perspective (AZP
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int azps2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the zenithal/azimuthal perspective (AZP
) projection.
azps2x() projects native spherical coordinates to Cartesian coordinates in the plane of a zenithal/azimuthal perspective (AZP
) projection.
See prjs2x() for a description of the API.
int szpset | ( | struct prjprm * | prj | ) |
int szpx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the slant zenithal perspective (SZP
) projection.
szpx2s() deprojects Cartesian coordinates in the plane of a slant zenithal perspective (SZP
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int szps2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the slant zenithal perspective (SZP
) projection.
szps2x() projects native spherical coordinates to Cartesian coordinates in the plane of a slant zenithal perspective (SZP
) projection.
See prjs2x() for a description of the API.
int tanset | ( | struct prjprm * | prj | ) |
int tanx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the gnomonic (TAN
) projection.
tanx2s() deprojects Cartesian coordinates in the plane of a gnomonic (TAN
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int tans2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the gnomonic (TAN
) projection.
tans2x() projects native spherical coordinates to Cartesian coordinates in the plane of a gnomonic (TAN
) projection.
See prjs2x() for a description of the API.
int stgset | ( | struct prjprm * | prj | ) |
int stgx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the stereographic (STG
) projection.
stgx2s() deprojects Cartesian coordinates in the plane of a stereographic (STG
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int stgs2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the stereographic (STG
) projection.
stgs2x() projects native spherical coordinates to Cartesian coordinates in the plane of a stereographic (STG
) projection.
See prjs2x() for a description of the API.
int sinset | ( | struct prjprm * | prj | ) |
int sinx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the orthographic/synthesis (SIN
) projection.
sinx2s() deprojects Cartesian coordinates in the plane of an orthographic/synthesis (SIN
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int sins2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the orthographic/synthesis (SIN
) projection.
sins2x() projects native spherical coordinates to Cartesian coordinates in the plane of an orthographic/synthesis (SIN
) projection.
See prjs2x() for a description of the API.
int arcset | ( | struct prjprm * | prj | ) |
int arcx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the zenithal/azimuthal equidistant (ARC
) projection.
arcx2s() deprojects Cartesian coordinates in the plane of a zenithal/azimuthal equidistant (ARC
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int arcs2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the zenithal/azimuthal equidistant (ARC
) projection.
arcs2x() projects native spherical coordinates to Cartesian coordinates in the plane of a zenithal/azimuthal equidistant (ARC
) projection.
See prjs2x() for a description of the API.
int zpnset | ( | struct prjprm * | prj | ) |
int zpnx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the zenithal/azimuthal polynomial (ZPN
) projection.
zpnx2s() deprojects Cartesian coordinates in the plane of a zenithal/azimuthal polynomial (ZPN
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int zpns2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the zenithal/azimuthal polynomial (ZPN
) projection.
zpns2x() projects native spherical coordinates to Cartesian coordinates in the plane of a zenithal/azimuthal polynomial (ZPN
) projection.
See prjs2x() for a description of the API.
int zeaset | ( | struct prjprm * | prj | ) |
int zeax2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the zenithal/azimuthal equal area (ZEA
) projection.
zeax2s() deprojects Cartesian coordinates in the plane of a zenithal/azimuthal equal area (ZEA
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int zeas2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the zenithal/azimuthal equal area (ZEA
) projection.
zeas2x() projects native spherical coordinates to Cartesian coordinates in the plane of a zenithal/azimuthal equal area (ZEA
) projection.
See prjs2x() for a description of the API.
int airset | ( | struct prjprm * | prj | ) |
int airx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for Airy's (AIR
) projection.
airx2s() deprojects Cartesian coordinates in the plane of an Airy (AIR
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int airs2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for Airy's (AIR
) projection.
airs2x() projects native spherical coordinates to Cartesian coordinates in the plane of an Airy (AIR
) projection.
See prjs2x() for a description of the API.
int cypset | ( | struct prjprm * | prj | ) |
int cypx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the cylindrical perspective (CYP
) projection.
cypx2s() deprojects Cartesian coordinates in the plane of a cylindrical perspective (CYP
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int cyps2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the cylindrical perspective (CYP
) projection.
cyps2x() projects native spherical coordinates to Cartesian coordinates in the plane of a cylindrical perspective (CYP
) projection.
See prjs2x() for a description of the API.
int ceaset | ( | struct prjprm * | prj | ) |
int ceax2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the cylindrical equal area (CEA
) projection.
ceax2s() deprojects Cartesian coordinates in the plane of a cylindrical equal area (CEA
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int ceas2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the cylindrical equal area (CEA
) projection.
ceas2x() projects native spherical coordinates to Cartesian coordinates in the plane of a cylindrical equal area (CEA
) projection.
See prjs2x() for a description of the API.
int carset | ( | struct prjprm * | prj | ) |
int carx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the plate carrée (CAR
) projection.
carx2s() deprojects Cartesian coordinates in the plane of a plate carrée (CAR
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int cars2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the plate carrée (CAR
) projection.
cars2x() projects native spherical coordinates to Cartesian coordinates in the plane of a plate carrée (CAR
) projection.
See prjs2x() for a description of the API.
int merset | ( | struct prjprm * | prj | ) |
int merx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for Mercator's (MER
) projection.
merx2s() deprojects Cartesian coordinates in the plane of a Mercator (MER
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int mers2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for Mercator's (MER
) projection.
mers2x() projects native spherical coordinates to Cartesian coordinates in the plane of a Mercator (MER
) projection.
See prjs2x() for a description of the API.
int sflset | ( | struct prjprm * | prj | ) |
int sflx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the Sanson-Flamsteed (SFL
) projection.
sflx2s() deprojects Cartesian coordinates in the plane of a Sanson-Flamsteed (SFL
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int sfls2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the Sanson-Flamsteed (SFL
) projection.
sfls2x() projects native spherical coordinates to Cartesian coordinates in the plane of a Sanson-Flamsteed (SFL
) projection.
See prjs2x() for a description of the API.
int parset | ( | struct prjprm * | prj | ) |
int parx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the parabolic (PAR
) projection.
parx2s() deprojects Cartesian coordinates in the plane of a parabolic (PAR
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int pars2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the parabolic (PAR
) projection.
pars2x() projects native spherical coordinates to Cartesian coordinates in the plane of a parabolic (PAR
) projection.
See prjs2x() for a description of the API.
int molset | ( | struct prjprm * | prj | ) |
int molx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for Mollweide's (MOL
) projection.
molx2s() deprojects Cartesian coordinates in the plane of a Mollweide (MOL
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int mols2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for Mollweide's (MOL
) projection.
mols2x() projects native spherical coordinates to Cartesian coordinates in the plane of a Mollweide (MOL
) projection.
See prjs2x() for a description of the API.
int aitset | ( | struct prjprm * | prj | ) |
int aitx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the Hammer-Aitoff (AIT
) projection.
aitx2s() deprojects Cartesian coordinates in the plane of a Hammer-Aitoff (AIT
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int aits2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the Hammer-Aitoff (AIT
) projection.
aits2x() projects native spherical coordinates to Cartesian coordinates in the plane of a Hammer-Aitoff (AIT
) projection.
See prjs2x() for a description of the API.
int copset | ( | struct prjprm * | prj | ) |
int copx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the conic perspective (COP
) projection.
copx2s() deprojects Cartesian coordinates in the plane of a conic perspective (COP
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int cops2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the conic perspective (COP
) projection.
cops2x() projects native spherical coordinates to Cartesian coordinates in the plane of a conic perspective (COP
) projection.
See prjs2x() for a description of the API.
int coeset | ( | struct prjprm * | prj | ) |
int coex2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the conic equal area (COE
) projection.
coex2s() deprojects Cartesian coordinates in the plane of a conic equal area (COE
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int coes2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the conic equal area (COE
) projection.
coes2x() projects native spherical coordinates to Cartesian coordinates in the plane of a conic equal area (COE
) projection.
See prjs2x() for a description of the API.
int codset | ( | struct prjprm * | prj | ) |
int codx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the conic equidistant (COD
) projection.
codx2s() deprojects Cartesian coordinates in the plane of a conic equidistant (COD
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int cods2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the conic equidistant (COD
) projection.
cods2x() projects native spherical coordinates to Cartesian coordinates in the plane of a conic equidistant (COD
) projection.
See prjs2x() for a description of the API.
int cooset | ( | struct prjprm * | prj | ) |
int coox2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the conic orthomorphic (COO
) projection.
coox2s() deprojects Cartesian coordinates in the plane of a conic orthomorphic (COO
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int coos2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the conic orthomorphic (COO
) projection.
coos2x() projects native spherical coordinates to Cartesian coordinates in the plane of a conic orthomorphic (COO
) projection.
See prjs2x() for a description of the API.
int bonset | ( | struct prjprm * | prj | ) |
int bonx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for Bonne's (BON
) projection.
bonx2s() deprojects Cartesian coordinates in the plane of a Bonne (BON
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int bons2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for Bonne's (BON
) projection.
bons2x() projects native spherical coordinates to Cartesian coordinates in the plane of a Bonne (BON
) projection.
See prjs2x() for a description of the API.
int pcoset | ( | struct prjprm * | prj | ) |
int pcox2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the polyconic (PCO
) projection.
pcox2s() deprojects Cartesian coordinates in the plane of a polyconic (PCO
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int pcos2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the polyconic (PCO
) projection.
pcos2x() projects native spherical coordinates to Cartesian coordinates in the plane of a polyconic (PCO
) projection.
See prjs2x() for a description of the API.
int tscset | ( | struct prjprm * | prj | ) |
int tscx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the tangential spherical cube (TSC
) projection.
tscx2s() deprojects Cartesian coordinates in the plane of a tangential spherical cube (TSC
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int tscs2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the tangential spherical cube (TSC
) projection.
tscs2x() projects native spherical coordinates to Cartesian coordinates in the plane of a tangential spherical cube (TSC
) projection.
See prjs2x() for a description of the API.
int cscset | ( | struct prjprm * | prj | ) |
int cscx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the COBE spherical cube (CSC
) projection.
cscx2s() deprojects Cartesian coordinates in the plane of a COBE spherical cube (CSC
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int cscs2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the COBE spherical cube (CSC
) projection.
cscs2x() projects native spherical coordinates to Cartesian coordinates in the plane of a COBE spherical cube (CSC
) projection.
See prjs2x() for a description of the API.
int qscset | ( | struct prjprm * | prj | ) |
int qscx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the quadrilateralized spherical cube (QSC
) projection.
qscx2s() deprojects Cartesian coordinates in the plane of a quadrilateralized spherical cube (QSC
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int qscs2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the quadrilateralized spherical cube (QSC
) projection.
qscs2x() projects native spherical coordinates to Cartesian coordinates in the plane of a quadrilateralized spherical cube (QSC
) projection.
See prjs2x() for a description of the API.
int hpxset | ( | struct prjprm * | prj | ) |
int hpxx2s | ( | PRJX2S_ARGS | ) |
Cartesian-to-spherical transformation for the HEALPix (HPX
) projection.
hpxx2s() deprojects Cartesian coordinates in the plane of a HEALPix (HPX
) projection to native spherical coordinates .
See prjx2s() for a description of the API.
int hpxs2x | ( | PRJS2X_ARGS | ) |
Spherical-to-Cartesian transformation for the HEALPix (HPX
) projection.
hpxs2x() projects native spherical coordinates to Cartesian coordinates in the plane of a HEALPix (HPX
) projection.
See prjs2x() for a description of the API.
int xphset | ( | struct prjprm * | prj | ) |
int xphx2s | ( | PRJX2S_ARGS | ) |
int xphs2x | ( | PRJS2X_ARGS | ) |
|
extern |
Status return messages.
Error messages to match the status value returned from each function.
|
extern |
Identifier for conic projections.
Identifier for conic projections, see prjprm::category.
const int CONVENTIONAL |
Identifier for conventional projections.
Identifier for conventional projections, see prjprm::category.
const int CYLINDRICAL |
Identifier for cylindrical projections.
Identifier for cylindrical projections, see prjprm::category.
const int POLYCONIC |
Identifier for polyconic projections.
Identifier for polyconic projections, see prjprm::category.
const int PSEUDOCYLINDRICAL |
Identifier for pseudocylindrical projections.
Identifier for pseudocylindrical projections, see prjprm::category.
const int QUADCUBE |
Identifier for quadcube projections.
Identifier for quadcube projections, see prjprm::category.
const int ZENITHAL |
Identifier for zenithal/azimuthal projections.
Identifier for zenithal/azimuthal projections, see prjprm::category.
const int HEALPIX |
Identifier for the HEALPix projection.
Identifier for the HEALPix projection, see prjprm::category.
|
extern |
Projection categories.
Names of the projection categories, all in lower-case except for "HEALPix".
Provided for information only, not used by the projection routines.
|
extern |
The number of recognized three-letter projection codes.
The number of recognized three-letter projection codes (currently 27), see prj_codes.
|
extern |
Recognized three-letter projection codes.
List of all recognized three-letter projection codes (currently 27), e.g. SIN
, TAN
, etc.