WCSLIB 4.20
prj.h
Go to the documentation of this file.
1 /*============================================================================
2 
3  WCSLIB 4.20 - an implementation of the FITS WCS standard.
4  Copyright (C) 1995-2013, Mark Calabretta
5 
6  This file is part of WCSLIB.
7 
8  WCSLIB is free software: you can redistribute it and/or modify it under the
9  terms of the GNU Lesser General Public License as published by the Free
10  Software Foundation, either version 3 of the License, or (at your option)
11  any later version.
12 
13  WCSLIB is distributed in the hope that it will be useful, but WITHOUT ANY
14  WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
15  FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for
16  more details.
17 
18  You should have received a copy of the GNU Lesser General Public License
19  along with WCSLIB. If not, see http://www.gnu.org/licenses.
20 
21  Direct correspondence concerning WCSLIB to mark@calabretta.id.au
22 
23  Author: Mark Calabretta, Australia Telescope National Facility, CSIRO.
24  http://www.atnf.csiro.au/people/Mark.Calabretta
25  $Id: prj_8h_source.html,v 1.1 2014/02/12 21:11:36 irby Exp $
26 *=============================================================================
27 *
28 * WCSLIB 4.20 - C routines that implement the spherical map projections
29 * recognized by the FITS World Coordinate System (WCS) standard. Refer to
30 *
31 * "Representations of world coordinates in FITS",
32 * Greisen, E.W., & Calabretta, M.R. 2002, A&A, 395, 1061 (Paper I)
33 *
34 * "Representations of celestial coordinates in FITS",
35 * Calabretta, M.R., & Greisen, E.W. 2002, A&A, 395, 1077 (Paper II)
36 *
37 * Refer to the README file provided with WCSLIB for an overview of the
38 * library.
39 *
40 *
41 * Summary of the prj routines
42 * ---------------------------
43 * These routines implement the spherical map projections defined by the FITS
44 * WCS standard. They are based on the prjprm struct which contains all
45 * information needed for the computations. The struct contains some members
46 * that must be set by the user, and others that are maintained by these
47 * routines, somewhat like a C++ class but with no encapsulation.
48 *
49 * Routine prjini() is provided to initialize the prjprm struct with default
50 * values, prjfree() reclaims any memory that may have been allocated to store
51 * an error message, and prjprt() prints its contents.
52 *
53 * Setup routines for each projection with names of the form ???set(), where
54 * "???" is the down-cased three-letter projection code, compute intermediate
55 * values in the prjprm struct from parameters in it that were supplied by the
56 * user. The struct always needs to be set by the projection's setup routine
57 * but that need not be called explicitly - refer to the explanation of
58 * prjprm::flag.
59 *
60 * Each map projection is implemented via separate functions for the spherical
61 * projection, ???s2x(), and deprojection, ???x2s().
62 *
63 * A set of driver routines, prjset(), prjx2s(), and prjs2x(), provides a
64 * generic interface to the specific projection routines which they invoke
65 * via pointers-to-functions stored in the prjprm struct.
66 *
67 * In summary, the routines are:
68 * - prjini() Initialization routine for the prjprm struct.
69 * - prjprt() Routine to print the prjprm struct.
70 *
71 * - prjset(), prjx2s(), prjs2x(): Generic driver routines
72 *
73 * - azpset(), azpx2s(), azps2x(): AZP (zenithal/azimuthal perspective)
74 * - szpset(), szpx2s(), szps2x(): SZP (slant zenithal perspective)
75 * - tanset(), tanx2s(), tans2x(): TAN (gnomonic)
76 * - stgset(), stgx2s(), stgs2x(): STG (stereographic)
77 * - sinset(), sinx2s(), sins2x(): SIN (orthographic/synthesis)
78 * - arcset(), arcx2s(), arcs2x(): ARC (zenithal/azimuthal equidistant)
79 * - zpnset(), zpnx2s(), zpns2x(): ZPN (zenithal/azimuthal polynomial)
80 * - zeaset(), zeax2s(), zeas2x(): ZEA (zenithal/azimuthal equal area)
81 * - airset(), airx2s(), airs2x(): AIR (Airy)
82 * - cypset(), cypx2s(), cyps2x(): CYP (cylindrical perspective)
83 * - ceaset(), ceax2s(), ceas2x(): CEA (cylindrical equal area)
84 * - carset(), carx2s(), cars2x(): CAR (Plate carree)
85 * - merset(), merx2s(), mers2x(): MER (Mercator)
86 * - sflset(), sflx2s(), sfls2x(): SFL (Sanson-Flamsteed)
87 * - parset(), parx2s(), pars2x(): PAR (parabolic)
88 * - molset(), molx2s(), mols2x(): MOL (Mollweide)
89 * - aitset(), aitx2s(), aits2x(): AIT (Hammer-Aitoff)
90 * - copset(), copx2s(), cops2x(): COP (conic perspective)
91 * - coeset(), coex2s(), coes2x(): COE (conic equal area)
92 * - codset(), codx2s(), cods2x(): COD (conic equidistant)
93 * - cooset(), coox2s(), coos2x(): COO (conic orthomorphic)
94 * - bonset(), bonx2s(), bons2x(): BON (Bonne)
95 * - pcoset(), pcox2s(), pcos2x(): PCO (polyconic)
96 * - tscset(), tscx2s(), tscs2x(): TSC (tangential spherical cube)
97 * - cscset(), cscx2s(), cscs2x(): CSC (COBE spherical cube)
98 * - qscset(), qscx2s(), qscs2x(): QSC (quadrilateralized spherical cube)
99 * - hpxset(), hpxx2s(), hpxs2x(): HPX (HEALPix)
100 * - xphset(), xphx2s(), xphs2x(): XPH (HEALPix polar, aka "butterfly")
101 *
102 * Argument checking (projection routines):
103 * ----------------------------------------
104 * The values of phi and theta (the native longitude and latitude) normally lie
105 * in the range [-180,180] for phi, and [-90,90] for theta. However, all
106 * projection routines will accept any value of phi and will not normalize it.
107 *
108 * The projection routines do not explicitly check that theta lies within the
109 * range [-90,90]. They do check for any value of theta that produces an
110 * invalid argument to the projection equations (e.g. leading to division by
111 * zero). The projection routines for AZP, SZP, TAN, SIN, ZPN, and COP also
112 * return error 2 if (phi,theta) corresponds to the overlapped (far) side of
113 * the projection but also return the corresponding value of (x,y). This
114 * strict bounds checking may be relaxed at any time by setting
115 * prjprm::bounds%2 to 0 (rather than 1); the projections need not be
116 * reinitialized.
117 *
118 * Argument checking (deprojection routines):
119 * ------------------------------------------
120 * Error checking on the projected coordinates (x,y) is limited to that
121 * required to ascertain whether a solution exists. Where a solution does
122 * exist no check is made that the value of phi and theta obtained lie within
123 * the ranges [-180,180] for phi, and [-90,90] for theta.
124 *
125 * Accuracy:
126 * ---------
127 * No warranty is given for the accuracy of these routines (refer to the
128 * copyright notice); intending users must satisfy for themselves their
129 * adequacy for the intended purpose. However, closure to a precision of at
130 * least 1E-10 degree of longitude and latitude has been verified for typical
131 * projection parameters on the 1 degree graticule of native longitude and
132 * latitude (to within 5 degrees of any latitude where the projection may
133 * diverge). Refer to the tprj1.c and tprj2.c test routines that accompany
134 * this software.
135 *
136 *
137 * prjini() - Default constructor for the prjprm struct
138 * ----------------------------------------------------
139 * prjini() sets all members of a prjprm struct to default values. It should
140 * be used to initialize every prjprm struct.
141 *
142 * Returned:
143 * prj struct prjprm*
144 * Projection parameters.
145 *
146 * Function return value:
147 * int Status return value:
148 * 0: Success.
149 * 1: Null prjprm pointer passed.
150 *
151 *
152 * prjfree() - Destructor for the prjprm struct
153 * --------------------------------------------
154 * prjfree() frees any memory that may have been allocated to store an error
155 * message in the prjprm struct.
156 *
157 * Given:
158 * prj struct prjprm*
159 * Projection parameters.
160 *
161 * Function return value:
162 * int Status return value:
163 * 0: Success.
164 * 1: Null prjprm pointer passed.
165 *
166 *
167 * prjprt() - Print routine for the prjprm struct
168 * ----------------------------------------------
169 * prjprt() prints the contents of a prjprm struct using wcsprintf(). Mainly
170 * intended for diagnostic purposes.
171 *
172 * Given:
173 * prj const struct prjprm*
174 * Projection parameters.
175 *
176 * Function return value:
177 * int Status return value:
178 * 0: Success.
179 * 1: Null prjprm pointer passed.
180 *
181 *
182 * prjset() - Generic setup routine for the prjprm struct
183 * ------------------------------------------------------
184 * prjset() sets up a prjprm struct according to information supplied within
185 * it.
186 *
187 * Note that this routine need not be called directly; it will be invoked by
188 * prjx2s() and prjs2x() if prj.flag is anything other than a predefined magic
189 * value.
190 *
191 * The one important distinction between prjset() and the setup routines for
192 * the specific projections is that the projection code must be defined in the
193 * prjprm struct in order for prjset() to identify the required projection.
194 * Once prjset() has initialized the prjprm struct, prjx2s() and prjs2x() use
195 * the pointers to the specific projection and deprojection routines contained
196 * therein.
197 *
198 * Given and returned:
199 * prj struct prjprm*
200 * Projection parameters.
201 *
202 * Function return value:
203 * int Status return value:
204 * 0: Success.
205 * 1: Null prjprm pointer passed.
206 * 2: Invalid projection parameters.
207 *
208 * For returns > 1, a detailed error message is set in
209 * prjprm::err if enabled, see wcserr_enable().
210 *
211 *
212 * prjx2s() - Generic Cartesian-to-spherical deprojection
213 * ------------------------------------------------------
214 * Deproject Cartesian (x,y) coordinates in the plane of projection to native
215 * spherical coordinates (phi,theta).
216 *
217 * The projection is that specified by prjprm::code.
218 *
219 * Given and returned:
220 * prj struct prjprm*
221 * Projection parameters.
222 *
223 * Given:
224 * nx,ny int Vector lengths.
225 *
226 * sxy,spt int Vector strides.
227 *
228 * x,y const double[]
229 * Projected coordinates.
230 *
231 * Returned:
232 * phi,theta double[] Longitude and latitude (phi,theta) of the projected
233 * point in native spherical coordinates [deg].
234 *
235 * stat int[] Status return value for each vector element:
236 * 0: Success.
237 * 1: Invalid value of (x,y).
238 *
239 * Function return value:
240 * int Status return value:
241 * 0: Success.
242 * 1: Null prjprm pointer passed.
243 * 2: Invalid projection parameters.
244 * 3: One or more of the (x,y) coordinates were
245 * invalid, as indicated by the stat vector.
246 *
247 * For returns > 1, a detailed error message is set in
248 * prjprm::err if enabled, see wcserr_enable().
249 *
250 *
251 * prjs2x() - Generic spherical-to-Cartesian projection
252 * ----------------------------------------------------
253 * Project native spherical coordinates (phi,theta) to Cartesian (x,y)
254 * coordinates in the plane of projection.
255 *
256 * The projection is that specified by prjprm::code.
257 *
258 * Given and returned:
259 * prj struct prjprm*
260 * Projection parameters.
261 *
262 * Given:
263 * nphi,
264 * ntheta int Vector lengths.
265 *
266 * spt,sxy int Vector strides.
267 *
268 * phi,theta const double[]
269 * Longitude and latitude (phi,theta) of the projected
270 * point in native spherical coordinates [deg].
271 *
272 * Returned:
273 * x,y double[] Projected coordinates.
274 *
275 * stat int[] Status return value for each vector element:
276 * 0: Success.
277 * 1: Invalid value of (phi,theta).
278 *
279 * Function return value:
280 * int Status return value:
281 * 0: Success.
282 * 1: Null prjprm pointer passed.
283 * 2: Invalid projection parameters.
284 * 4: One or more of the (phi,theta) coordinates
285 * were, invalid, as indicated by the stat vector.
286 *
287 * For returns > 1, a detailed error message is set in
288 * prjprm::err if enabled, see wcserr_enable().
289 *
290 *
291 * ???set() - Specific setup routines for the prjprm struct
292 * --------------------------------------------------------
293 * Set up a prjprm struct for a particular projection according to information
294 * supplied within it.
295 *
296 * Given and returned:
297 * prj struct prjprm*
298 * Projection parameters.
299 *
300 * Function return value:
301 * int Status return value:
302 * 0: Success.
303 * 1: Null prjprm pointer passed.
304 * 2: Invalid projection parameters.
305 *
306 * For returns > 1, a detailed error message is set in
307 * prjprm::err if enabled, see wcserr_enable().
308 *
309 *
310 * ???x2s() - Specific Cartesian-to-spherical deprojection routines
311 * ----------------------------------------------------------------
312 * Transform (x,y) coordinates in the plane of projection to native spherical
313 * coordinates (phi,theta).
314 *
315 * Given and returned:
316 * prj struct prjprm*
317 * Projection parameters.
318 *
319 * Given:
320 * nx,ny int Vector lengths.
321 *
322 * sxy,spt int Vector strides.
323 *
324 * x,y const double[]
325 * Projected coordinates.
326 *
327 * Returned:
328 * phi,theta double[] Longitude and latitude of the projected point in
329 * native spherical coordinates [deg].
330 *
331 * stat int[] Status return value for each vector element:
332 * 0: Success.
333 * 1: Invalid value of (x,y).
334 *
335 * Function return value:
336 * int Status return value:
337 * 0: Success.
338 * 1: Null prjprm pointer passed.
339 * 2: Invalid projection parameters.
340 * 3: One or more of the (x,y) coordinates were
341 * invalid, as indicated by the stat vector.
342 *
343 * For returns > 1, a detailed error message is set in
344 * prjprm::err if enabled, see wcserr_enable().
345 *
346 *
347 * ???s2x() - Specific spherical-to-Cartesian projection routines
348 *---------------------------------------------------------------
349 * Transform native spherical coordinates (phi,theta) to (x,y) coordinates in
350 * the plane of projection.
351 *
352 * Given and returned:
353 * prj struct prjprm*
354 * Projection parameters.
355 *
356 * Given:
357 * nphi,
358 * ntheta int Vector lengths.
359 *
360 * spt,sxy int Vector strides.
361 *
362 * phi,theta const double[]
363 * Longitude and latitude of the projected point in
364 * native spherical coordinates [deg].
365 *
366 * Returned:
367 * x,y double[] Projected coordinates.
368 *
369 * stat int[] Status return value for each vector element:
370 * 0: Success.
371 * 1: Invalid value of (phi,theta).
372 *
373 * Function return value:
374 * int Status return value:
375 * 0: Success.
376 * 1: Null prjprm pointer passed.
377 * 2: Invalid projection parameters.
378 * 4: One or more of the (phi,theta) coordinates
379 * were, invalid, as indicated by the stat vector.
380 *
381 * For returns > 1, a detailed error message is set in
382 * prjprm::err if enabled, see wcserr_enable().
383 *
384 *
385 * prjprm struct - Projection parameters
386 * -------------------------------------
387 * The prjprm struct contains all information needed to project or deproject
388 * native spherical coordinates. It consists of certain members that must be
389 * set by the user ("given") and others that are set by the WCSLIB routines
390 * ("returned"). Some of the latter are supplied for informational purposes
391 * while others are for internal use only.
392 *
393 * int flag
394 * (Given and returned) This flag must be set to zero whenever any of the
395 * following prjprm struct members are set or changed:
396 *
397 * - prjprm::code,
398 * - prjprm::r0,
399 * - prjprm::pv[],
400 * - prjprm::phi0,
401 * - prjprm::theta0.
402 *
403 * This signals the initialization routine (prjset() or ???set()) to
404 * recompute the returned members of the prjprm struct. flag will then be
405 * reset to indicate that this has been done.
406 *
407 * Note that flag need not be reset when prjprm::bounds is changed.
408 *
409 * char code[4]
410 * (Given) Three-letter projection code defined by the FITS standard.
411 *
412 * double r0
413 * (Given) The radius of the generating sphere for the projection, a linear
414 * scaling parameter. If this is zero, it will be reset to its default
415 * value of 180/pi (the value for FITS WCS).
416 *
417 * double pv[30]
418 * (Given) Projection parameters. These correspond to the PVi_ma keywords
419 * in FITS, so pv[0] is PVi_0a, pv[1] is PVi_1a, etc., where i denotes the
420 * latitude-like axis. Many projections use pv[1] (PVi_1a), some also use
421 * pv[2] (PVi_2a) and SZP uses pv[3] (PVi_3a). ZPN is currently the only
422 * projection that uses any of the others.
423 *
424 * Usage of the pv[] array as it applies to each projection is described in
425 * the prologue to each trio of projection routines in prj.c.
426 *
427 * double phi0
428 * (Given) The native longitude, phi_0 [deg], and ...
429 * double theta0
430 * (Given) ... the native latitude, theta_0 [deg], of the reference point,
431 * i.e. the point (x,y) = (0,0). If undefined (set to a magic value by
432 * prjini()) the initialization routine will set this to a
433 * projection-specific default.
434 *
435 * int bounds
436 * (Given) Controls strict bounds checking. If bounds&1 then enable bounds
437 * checking for the sky-to-pixel (s2x) transformation for the AZP, SZP,
438 * TAN, SIN, ZPN, and COP projections. If bounds&2 then enable bounds
439 * checking for the pixel-to-sky transformation for the HPX and XPH
440 * projections. Set to 3 by prjini() by default which enables both. Zero
441 * it to disable all checking.
442 *
443 * The remaining members of the prjprm struct are maintained by the setup
444 * routines and must not be modified elsewhere:
445 *
446 * char name[40]
447 * (Returned) Long name of the projection.
448 *
449 * Provided for information only, not used by the projection routines.
450 *
451 * int category
452 * (Returned) Projection category matching the value of the relevant global
453 * variable:
454 *
455 * - ZENITHAL,
456 * - CYLINDRICAL,
457 * - PSEUDOCYLINDRICAL,
458 * - CONVENTIONAL,
459 * - CONIC,
460 * - POLYCONIC,
461 * - QUADCUBE, and
462 * - HEALPIX.
463 *
464 * The category name may be identified via the prj_categories character
465 * array, e.g.
466 *
467 = struct prjprm prj;
468 = ...
469 = printf("%s\n", prj_categories[prj.category]);
470 *
471 * Provided for information only, not used by the projection routines.
472 *
473 * int pvrange
474 * (Returned) Range of projection parameter indices: 100 times the first
475 * allowed index plus the number of parameters, e.g. TAN is 0 (no
476 * parameters), SZP is 103 (1 to 3), and ZPN is 30 (0 to 29).
477 *
478 * Provided for information only, not used by the projection routines.
479 *
480 * int simplezen
481 * (Returned) True if the projection is a radially-symmetric zenithal
482 * projection.
483 *
484 * Provided for information only, not used by the projection routines.
485 *
486 * int equiareal
487 * (Returned) True if the projection is equal area.
488 *
489 * Provided for information only, not used by the projection routines.
490 *
491 * int conformal
492 * (Returned) True if the projection is conformal.
493 *
494 * Provided for information only, not used by the projection routines.
495 *
496 * int global
497 * (Returned) True if the projection can represent the whole sphere in a
498 * finite, non-overlapped mapping.
499 *
500 * Provided for information only, not used by the projection routines.
501 *
502 * int divergent
503 * (Returned) True if the projection diverges in latitude.
504 *
505 * Provided for information only, not used by the projection routines.
506 *
507 * double x0
508 * (Returned) The offset in x, and ...
509 * double y0
510 * (Returned) ... the offset in y used to force (x,y) = (0,0) at
511 * (phi_0,theta_0).
512 *
513 * struct wcserr *err
514 * (Returned) If enabled, when an error status is returned this struct
515 * contains detailed information about the error, see wcserr_enable().
516 *
517 * void *padding
518 * (An unused variable inserted for alignment purposes only.)
519 *
520 * double w[10]
521 * (Returned) Intermediate floating-point values derived from the
522 * projection parameters, cached here to save recomputation.
523 *
524 * Usage of the w[] array as it applies to each projection is described in
525 * the prologue to each trio of projection routines in prj.c.
526 *
527 * int n
528 * (Returned) Intermediate integer value (used only for the ZPN and HPX
529 * projections).
530 *
531 * int (*prjx2s)(PRJX2S_ARGS)
532 * (Returned) Pointer to the projection ...
533 * int (*prjs2x)(PRJ_ARGS)
534 * (Returned) ... and deprojection routines.
535 *
536 *
537 * Global variable: const char *prj_errmsg[] - Status return messages
538 * ------------------------------------------------------------------
539 * Error messages to match the status value returned from each function.
540 *
541 *===========================================================================*/
542 
543 #ifndef WCSLIB_PROJ
544 #define WCSLIB_PROJ
545 
546 #include "wcserr.h"
547 
548 #ifdef __cplusplus
549 extern "C" {
550 #endif
551 
552 
553 /* Total number of projection parameters; 0 to PVN-1. */
554 #define PVN 30
555 
556 extern const char *prj_errmsg[];
557 
559  PRJERR_SUCCESS = 0, /* Success. */
560  PRJERR_NULL_POINTER = 1, /* Null prjprm pointer passed. */
561  PRJERR_BAD_PARAM = 2, /* Invalid projection parameters. */
562  PRJERR_BAD_PIX = 3, /* One or more of the (x, y) coordinates were
563  invalid. */
564  PRJERR_BAD_WORLD = 4 /* One or more of the (phi, theta) coordinates
565  were invalid. */
566 };
567 
568 extern const int CONIC, CONVENTIONAL, CYLINDRICAL, POLYCONIC,
570 extern const char prj_categories[9][32];
571 
572 extern const int prj_ncode;
573 extern const char prj_codes[28][4];
574 
575 #ifdef PRJX2S_ARGS
576 #undef PRJX2S_ARGS
577 #endif
578 
579 #ifdef PRJS2X_ARGS
580 #undef PRJS2X_ARGS
581 #endif
582 
583 /* For use in declaring deprojection function prototypes. */
584 #define PRJX2S_ARGS struct prjprm *prj, int nx, int ny, int sxy, int spt, \
585 const double x[], const double y[], double phi[], double theta[], int stat[]
586 
587 /* For use in declaring projection function prototypes. */
588 #define PRJS2X_ARGS struct prjprm *prj, int nx, int ny, int sxy, int spt, \
589 const double phi[], const double theta[], double x[], double y[], int stat[]
590 
591 
592 struct prjprm {
593  /* Initialization flag (see the prologue above). */
594  /*------------------------------------------------------------------------*/
595  int flag; /* Set to zero to force initialization. */
596 
597  /* Parameters to be provided (see the prologue above). */
598  /*------------------------------------------------------------------------*/
599  char code[4]; /* Three-letter projection code. */
600  double r0; /* Radius of the generating sphere. */
601  double pv[PVN]; /* Projection parameters. */
602  double phi0, theta0; /* Fiducial native coordinates. */
603  int bounds; /* Enable strict bounds checking. */
604 
605  /* Information derived from the parameters supplied. */
606  /*------------------------------------------------------------------------*/
607  char name[40]; /* Projection name. */
608  int category; /* Projection category. */
609  int pvrange; /* Range of projection parameter indices. */
610  int simplezen; /* Is it a simple zenithal projection? */
611  int equiareal; /* Is it an equal area projection? */
612  int conformal; /* Is it a conformal projection? */
613  int global; /* Can it map the whole sphere? */
614  int divergent; /* Does the projection diverge in latitude? */
615  double x0, y0; /* Fiducial offsets. */
616 
617  /* Error handling */
618  /*------------------------------------------------------------------------*/
619  struct wcserr *err;
620 
621  /* Private */
622  /*------------------------------------------------------------------------*/
623  void *padding; /* (Dummy inserted for alignment purposes.) */
624  double w[10]; /* Intermediate values. */
625  int m, n; /* Intermediate values. */
626 
627  int (*prjx2s)(PRJX2S_ARGS); /* Pointers to the spherical projection and */
628  int (*prjs2x)(PRJS2X_ARGS); /* deprojection functions. */
629 };
630 
631 /* Size of the prjprm struct in int units, used by the Fortran wrappers. */
632 #define PRJLEN (sizeof(struct prjprm)/sizeof(int))
633 
634 
635 /* Use the preprocessor to help declare function prototypes (see above). */
636 int prjini(struct prjprm *prj);
637 int prjfree(struct prjprm *prj);
638 int prjprt(const struct prjprm *prj);
639 
640 int prjset(struct prjprm *prj);
641 int prjx2s(PRJX2S_ARGS);
642 int prjs2x(PRJS2X_ARGS);
643 
644 int azpset(struct prjprm *prj);
645 int azpx2s(PRJX2S_ARGS);
646 int azps2x(PRJS2X_ARGS);
647 
648 int szpset(struct prjprm *prj);
649 int szpx2s(PRJX2S_ARGS);
650 int szps2x(PRJS2X_ARGS);
651 
652 int tanset(struct prjprm *prj);
653 int tanx2s(PRJX2S_ARGS);
654 int tans2x(PRJS2X_ARGS);
655 
656 int stgset(struct prjprm *prj);
657 int stgx2s(PRJX2S_ARGS);
658 int stgs2x(PRJS2X_ARGS);
659 
660 int sinset(struct prjprm *prj);
661 int sinx2s(PRJX2S_ARGS);
662 int sins2x(PRJS2X_ARGS);
663 
664 int arcset(struct prjprm *prj);
665 int arcx2s(PRJX2S_ARGS);
666 int arcs2x(PRJS2X_ARGS);
667 
668 int zpnset(struct prjprm *prj);
669 int zpnx2s(PRJX2S_ARGS);
670 int zpns2x(PRJS2X_ARGS);
671 
672 int zeaset(struct prjprm *prj);
673 int zeax2s(PRJX2S_ARGS);
674 int zeas2x(PRJS2X_ARGS);
675 
676 int airset(struct prjprm *prj);
677 int airx2s(PRJX2S_ARGS);
678 int airs2x(PRJS2X_ARGS);
679 
680 int cypset(struct prjprm *prj);
681 int cypx2s(PRJX2S_ARGS);
682 int cyps2x(PRJS2X_ARGS);
683 
684 int ceaset(struct prjprm *prj);
685 int ceax2s(PRJX2S_ARGS);
686 int ceas2x(PRJS2X_ARGS);
687 
688 int carset(struct prjprm *prj);
689 int carx2s(PRJX2S_ARGS);
690 int cars2x(PRJS2X_ARGS);
691 
692 int merset(struct prjprm *prj);
693 int merx2s(PRJX2S_ARGS);
694 int mers2x(PRJS2X_ARGS);
695 
696 int sflset(struct prjprm *prj);
697 int sflx2s(PRJX2S_ARGS);
698 int sfls2x(PRJS2X_ARGS);
699 
700 int parset(struct prjprm *prj);
701 int parx2s(PRJX2S_ARGS);
702 int pars2x(PRJS2X_ARGS);
703 
704 int molset(struct prjprm *prj);
705 int molx2s(PRJX2S_ARGS);
706 int mols2x(PRJS2X_ARGS);
707 
708 int aitset(struct prjprm *prj);
709 int aitx2s(PRJX2S_ARGS);
710 int aits2x(PRJS2X_ARGS);
711 
712 int copset(struct prjprm *prj);
713 int copx2s(PRJX2S_ARGS);
714 int cops2x(PRJS2X_ARGS);
715 
716 int coeset(struct prjprm *prj);
717 int coex2s(PRJX2S_ARGS);
718 int coes2x(PRJS2X_ARGS);
719 
720 int codset(struct prjprm *prj);
721 int codx2s(PRJX2S_ARGS);
722 int cods2x(PRJS2X_ARGS);
723 
724 int cooset(struct prjprm *prj);
725 int coox2s(PRJX2S_ARGS);
726 int coos2x(PRJS2X_ARGS);
727 
728 int bonset(struct prjprm *prj);
729 int bonx2s(PRJX2S_ARGS);
730 int bons2x(PRJS2X_ARGS);
731 
732 int pcoset(struct prjprm *prj);
733 int pcox2s(PRJX2S_ARGS);
734 int pcos2x(PRJS2X_ARGS);
735 
736 int tscset(struct prjprm *prj);
737 int tscx2s(PRJX2S_ARGS);
738 int tscs2x(PRJS2X_ARGS);
739 
740 int cscset(struct prjprm *prj);
741 int cscx2s(PRJX2S_ARGS);
742 int cscs2x(PRJS2X_ARGS);
743 
744 int qscset(struct prjprm *prj);
745 int qscx2s(PRJX2S_ARGS);
746 int qscs2x(PRJS2X_ARGS);
747 
748 int hpxset(struct prjprm *prj);
749 int hpxx2s(PRJX2S_ARGS);
750 int hpxs2x(PRJS2X_ARGS);
751 
752 int xphset(struct prjprm *prj);
753 int xphx2s(PRJX2S_ARGS);
754 int xphs2x(PRJS2X_ARGS);
755 
756 
757 /* Deprecated. */
758 #define prjini_errmsg prj_errmsg
759 #define prjprt_errmsg prj_errmsg
760 #define prjset_errmsg prj_errmsg
761 #define prjx2s_errmsg prj_errmsg
762 #define prjs2x_errmsg prj_errmsg
763 
764 #ifdef __cplusplus
765 }
766 #endif
767 
768 #endif /* WCSLIB_PROJ */