From eb31a3163620baaa8e4b4e6d80f0a05daf2952ed Mon Sep 17 00:00:00 2001 From: Matt Hilton Date: Wed, 20 Mar 2024 14:05:00 +0200 Subject: [PATCH] Swig fix for Python 3.12 Also updated bundled wcssubs to 3.9.7. Bumped version number --- MANIFEST.in | 14 +- PyWCSTools/wcs.py | 690 ++---- PyWCSTools/wcscon.py | 117 +- PyWCSTools/wcssubs-3.9.5/COPYING | 460 ---- PyWCSTools/wcssubs-3.9.5/Makefile | 36 - PyWCSTools/wcssubs-3.9.5/Readme | 36 - PyWCSTools/wcssubs-3.9.5/fileutil.c | 867 -------- PyWCSTools/wcssubs-3.9.5/wcs.py | 255 --- PyWCSTools/wcssubs-3.9.5/wcscon.py | 73 - PyWCSTools/wcssubs-3.9.7/Files | 179 ++ .../{wcssubs-3.9.5 => wcssubs-3.9.7}/NEWS | 22 +- .../{wcssubs-3.9.5 => wcssubs-3.9.7}/cel.c | 0 .../dateutil.c | 202 +- .../distort.c | 0 .../{wcssubs-3.9.5 => wcssubs-3.9.7}/dsspos.c | 0 PyWCSTools/wcssubs-3.9.7/fileutil.c | 1755 +++++++++++++++ .../fitsfile.c | 8 +- .../fitsfile.h | 166 +- .../fitshead.h | 0 .../{wcssubs-3.9.5 => wcssubs-3.9.7}/hget.c | 21 +- .../{wcssubs-3.9.5 => wcssubs-3.9.7}/hput.c | 17 +- .../{wcssubs-3.9.5 => wcssubs-3.9.7}/iget.c | 0 .../imhfile.c | 0 .../{wcssubs-3.9.5 => wcssubs-3.9.7}/imio.c | 0 .../{wcssubs-3.9.5 => wcssubs-3.9.7}/imio.h | 0 .../{wcssubs-3.9.5 => wcssubs-3.9.7}/lin.c | 0 .../platepos.c | 0 .../{wcssubs-3.9.5 => wcssubs-3.9.7}/poly.c | 0 .../{wcssubs-3.9.5 => wcssubs-3.9.7}/proj.c | 0 .../{wcssubs-3.9.5 => wcssubs-3.9.7}/sph.c | 0 .../{wcssubs-3.9.5 => wcssubs-3.9.7}/tnxpos.c | 0 .../{wcssubs-3.9.5 => wcssubs-3.9.7}/wcs.c | 28 +- .../{wcssubs-3.9.5 => wcssubs-3.9.7}/wcs.h | 13 +- .../{wcssubs-3.9.5 => wcssubs-3.9.7}/wcs.i | 0 .../wcs_wrap.c | 1944 ++++++++++------- .../{wcssubs-3.9.5 => wcssubs-3.9.7}/wcscon.c | 0 .../{wcssubs-3.9.5 => wcssubs-3.9.7}/wcscon.i | 0 .../wcscon_wrap.c | 1211 +++++----- .../wcsinit.c | 11 +- .../{wcssubs-3.9.5 => wcssubs-3.9.7}/wcslib.c | 0 .../{wcssubs-3.9.5 => wcssubs-3.9.7}/wcslib.h | 0 .../wcstrig.c | 0 .../worldpos.c | 0 .../{wcssubs-3.9.5 => wcssubs-3.9.7}/zpxpos.c | 0 astLib/__init__.py | 6 +- setup.py | 34 +- 46 files changed, 4554 insertions(+), 3611 deletions(-) delete mode 100644 PyWCSTools/wcssubs-3.9.5/COPYING delete mode 100644 PyWCSTools/wcssubs-3.9.5/Makefile delete mode 100644 PyWCSTools/wcssubs-3.9.5/Readme delete mode 100644 PyWCSTools/wcssubs-3.9.5/fileutil.c delete mode 100644 PyWCSTools/wcssubs-3.9.5/wcs.py delete mode 100644 PyWCSTools/wcssubs-3.9.5/wcscon.py create mode 100644 PyWCSTools/wcssubs-3.9.7/Files rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/NEWS (94%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/cel.c (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/dateutil.c (96%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/distort.c (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/dsspos.c (100%) create mode 100644 PyWCSTools/wcssubs-3.9.7/fileutil.c rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/fitsfile.c (99%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/fitsfile.h (89%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/fitshead.h (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/hget.c (99%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/hput.c (99%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/iget.c (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/imhfile.c (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/imio.c (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/imio.h (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/lin.c (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/platepos.c (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/poly.c (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/proj.c (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/sph.c (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/tnxpos.c (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/wcs.c (99%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/wcs.h (99%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/wcs.i (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/wcs_wrap.c (87%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/wcscon.c (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/wcscon.i (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/wcscon_wrap.c (81%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/wcsinit.c (99%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/wcslib.c (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/wcslib.h (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/wcstrig.c (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/worldpos.c (100%) rename PyWCSTools/{wcssubs-3.9.5 => wcssubs-3.9.7}/zpxpos.c (100%) diff --git a/MANIFEST.in b/MANIFEST.in index 42693ab..4d0ee3c 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,12 +1,12 @@ recursive-include docs * recursive-include astLib/data * -recursive-include PyWCSTools/wcssubs-3.9.5 *.c* -recursive-include PyWCSTools/wcssubs-3.9.5 *.h* -recursive-include PyWCSTools/wcssubs-3.9.5 *.i* -recursive-include PyWCSTools/wcssubs-3.9.5 Makefile -recursive-include PyWCSTools/wcssubs-3.9.5 Readme -recursive-include PyWCSTools/wcssubs-3.9.5 COPYING -recursive-include PyWCSTools/wcssubs-3.9.5 NEWS +recursive-include PyWCSTools/wcssubs-3.9.7 *.c* +recursive-include PyWCSTools/wcssubs-3.9.7 *.h* +recursive-include PyWCSTools/wcssubs-3.9.7 *.i* +recursive-include PyWCSTools/wcssubs-3.9.7 Makefile +recursive-include PyWCSTools/wcssubs-3.9.7 Readme +recursive-include PyWCSTools/wcssubs-3.9.7 COPYING +recursive-include PyWCSTools/wcssubs-3.9.7 NEWS recursive-include examples/* *.py include LICENSE include CHANGE_LOG diff --git a/PyWCSTools/wcs.py b/PyWCSTools/wcs.py index e4bf720..662248a 100644 --- a/PyWCSTools/wcs.py +++ b/PyWCSTools/wcs.py @@ -1,468 +1,250 @@ -# This file was automatically generated by SWIG (http://www.swig.org). -# Version 2.0.7 +# This file was automatically generated by SWIG (https://www.swig.org). +# Version 4.2.1 # -# Do not make changes to this file unless you know what you are doing--modify +# Do not make changes to this file unless you know what you are doing - modify # the SWIG interface file instead. - - -from sys import version_info -if version_info >= (2,6,0): - def swig_import_helper(): - from os.path import dirname - import imp - fp = None - try: - fp, pathname, description = imp.find_module('_wcs', [dirname(__file__)]) - except ImportError: - import _wcs - return _wcs - if fp is not None: - try: - _mod = imp.load_module('_wcs', fp, pathname, description) - finally: - fp.close() - return _mod - _wcs = swig_import_helper() - del swig_import_helper +from sys import version_info as _swig_python_version_info +# Import the low-level C/C++ module +if __package__ or "." in __name__: + from . import _wcs else: import _wcs -del version_info + try: - _swig_property = property -except NameError: - pass # Python < 2.2 doesn't have 'property'. -def _swig_setattr_nondynamic(self,class_type,name,value,static=1): - if (name == "thisown"): return self.this.own(value) - if (name == "this"): - if type(value).__name__ == 'SwigPyObject': - self.__dict__[name] = value - return - method = class_type.__swig_setmethods__.get(name,None) - if method: return method(self,value) - if (not static): - self.__dict__[name] = value - else: - raise AttributeError("You cannot add attributes to %s" % self) - -def _swig_setattr(self,class_type,name,value): - return _swig_setattr_nondynamic(self,class_type,name,value,0) - -def _swig_getattr(self,class_type,name): - if (name == "thisown"): return self.this.own() - method = class_type.__swig_getmethods__.get(name,None) - if method: return method(self) - raise AttributeError(name) + import builtins as __builtin__ +except ImportError: + import __builtin__ def _swig_repr(self): - try: strthis = "proxy of " + self.this.__repr__() - except: strthis = "" + try: + strthis = "proxy of " + self.this.__repr__() + except __builtin__.Exception: + strthis = "" return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,) -try: - _object = object - _newclass = 1 -except AttributeError: - class _object : pass - _newclass = 0 - - - -def new_doubleArray(*args): - """new_doubleArray(nelements) -> double *""" - return _wcs.new_doubleArray(*args) - -def delete_doubleArray(*args): - """delete_doubleArray(ary)""" - return _wcs.delete_doubleArray(*args) - -def doubleArray_getitem(*args): - """doubleArray_getitem(ary, index) -> double""" - return _wcs.doubleArray_getitem(*args) - -def doubleArray_setitem(*args): - """doubleArray_setitem(ary, index, value)""" - return _wcs.doubleArray_setitem(*args) - -def wcsinit(*args): - """wcsinit(hstring) -> WorldCoor""" - return _wcs.wcsinit(*args) - -def wcsxinit(*args): - """wcsxinit(cra, cdec, secpix, xrpix, yrpix, nxpix, nypix, rotate, equinox, epoch, proj) -> WorldCoor""" - return _wcs.wcsxinit(*args) - -def wcskinit(*args): - """ - wcskinit(nxpix, nypix, ctype1, ctype2, crpix1, crpix2, crval1, crval2, cd, cdelt1, cdelt2, - crota, equinox, epoch) -> WorldCoor - """ - return _wcs.wcskinit(*args) - -def iswcs(*args): - """iswcs(wcs) -> int""" - return _wcs.iswcs(*args) - -def nowcs(*args): - """nowcs(wcs) -> int""" - return _wcs.nowcs(*args) - -def wcs2pix(*args): - """wcs2pix(wcs, xpos, ypos)""" - return _wcs.wcs2pix(*args) - -def pix2wcs(*args): - """pix2wcs(wcs, xpix, ypix)""" - return _wcs.pix2wcs(*args) - -def wcscent(*args): - """wcscent(wcs)""" - return _wcs.wcscent(*args) - -def getradecsys(*args): - """getradecsys(wcs) -> char *""" - return _wcs.getradecsys(*args) - -def wcsoutinit(*args): - """wcsoutinit(wcs, coorsys)""" - return _wcs.wcsoutinit(*args) - -def wcsininit(*args): - """wcsininit(wcs, coorsys)""" - return _wcs.wcsininit(*args) - -def getwcsout(*args): - """getwcsout(wcs) -> char *""" - return _wcs.getwcsout(*args) - -def getwcsin(*args): - """getwcsin(wcs) -> char *""" - return _wcs.getwcsin(*args) - -def wcssize(*args): - """wcssize(wcs)""" - return _wcs.wcssize(*args) - -def wcsfull(*args): - """wcsfull(wcs)""" - return _wcs.wcsfull(*args) -class WorldCoor(_object): - """Proxy of C WorldCoor struct""" - __swig_setmethods__ = {} - __setattr__ = lambda self, name, value: _swig_setattr(self, WorldCoor, name, value) - __swig_getmethods__ = {} - __getattr__ = lambda self, name: _swig_getattr(self, WorldCoor, name) + +def _swig_setattr_nondynamic_instance_variable(set): + def set_instance_attr(self, name, value): + if name == "this": + set(self, name, value) + elif name == "thisown": + self.this.own(value) + elif hasattr(self, name) and isinstance(getattr(type(self), name), property): + set(self, name, value) + else: + raise AttributeError("You cannot add instance attributes to %s" % self) + return set_instance_attr + + +def _swig_setattr_nondynamic_class_variable(set): + def set_class_attr(cls, name, value): + if hasattr(cls, name) and not isinstance(getattr(cls, name), property): + set(cls, name, value) + else: + raise AttributeError("You cannot add class attributes to %s" % cls) + return set_class_attr + + +def _swig_add_metaclass(metaclass): + """Class decorator for adding a metaclass to a SWIG wrapped class - a slimmed down version of six.add_metaclass""" + def wrapper(cls): + return metaclass(cls.__name__, cls.__bases__, cls.__dict__.copy()) + return wrapper + + +class _SwigNonDynamicMeta(type): + """Meta class to enforce nondynamic attributes (no new attributes) for a class""" + __setattr__ = _swig_setattr_nondynamic_class_variable(type.__setattr__) + + + +def new_doubleArray(nelements): + r"""new_doubleArray(nelements) -> double *""" + return _wcs.new_doubleArray(nelements) + +def delete_doubleArray(ary): + r"""delete_doubleArray(ary)""" + return _wcs.delete_doubleArray(ary) + +def doubleArray_getitem(ary, index): + r"""doubleArray_getitem(ary, index) -> double""" + return _wcs.doubleArray_getitem(ary, index) + +def doubleArray_setitem(ary, index, value): + r"""doubleArray_setitem(ary, index, value)""" + return _wcs.doubleArray_setitem(ary, index, value) + +def wcsinit(hstring): + r"""wcsinit(hstring) -> WorldCoor""" + return _wcs.wcsinit(hstring) + +def wcsxinit(cra, cdec, secpix, xrpix, yrpix, nxpix, nypix, rotate, equinox, epoch, proj): + r"""wcsxinit(cra, cdec, secpix, xrpix, yrpix, nxpix, nypix, rotate, equinox, epoch, proj) -> WorldCoor""" + return _wcs.wcsxinit(cra, cdec, secpix, xrpix, yrpix, nxpix, nypix, rotate, equinox, epoch, proj) + +def wcskinit(nxpix, nypix, ctype1, ctype2, crpix1, crpix2, crval1, crval2, cd, cdelt1, cdelt2, crota, equinox, epoch): + r"""wcskinit(nxpix, nypix, ctype1, ctype2, crpix1, crpix2, crval1, crval2, cd, cdelt1, cdelt2, crota, equinox, epoch) -> WorldCoor""" + return _wcs.wcskinit(nxpix, nypix, ctype1, ctype2, crpix1, crpix2, crval1, crval2, cd, cdelt1, cdelt2, crota, equinox, epoch) + +def iswcs(wcs): + r"""iswcs(wcs) -> int""" + return _wcs.iswcs(wcs) + +def nowcs(wcs): + r"""nowcs(wcs) -> int""" + return _wcs.nowcs(wcs) + +def wcs2pix(wcs, xpos, ypos): + r"""wcs2pix(wcs, xpos, ypos)""" + return _wcs.wcs2pix(wcs, xpos, ypos) + +def pix2wcs(wcs, xpix, ypix): + r"""pix2wcs(wcs, xpix, ypix)""" + return _wcs.pix2wcs(wcs, xpix, ypix) + +def wcscent(wcs): + r"""wcscent(wcs)""" + return _wcs.wcscent(wcs) + +def getradecsys(wcs): + r"""getradecsys(wcs) -> char *""" + return _wcs.getradecsys(wcs) + +def wcsoutinit(wcs, coorsys): + r"""wcsoutinit(wcs, coorsys)""" + return _wcs.wcsoutinit(wcs, coorsys) + +def wcsininit(wcs, coorsys): + r"""wcsininit(wcs, coorsys)""" + return _wcs.wcsininit(wcs, coorsys) + +def getwcsout(wcs): + r"""getwcsout(wcs) -> char *""" + return _wcs.getwcsout(wcs) + +def getwcsin(wcs): + r"""getwcsin(wcs) -> char *""" + return _wcs.getwcsin(wcs) + +def wcssize(wcs): + r"""wcssize(wcs)""" + return _wcs.wcssize(wcs) + +def wcsfull(wcs): + r"""wcsfull(wcs)""" + return _wcs.wcsfull(wcs) +class WorldCoor(object): + r"""Proxy of C WorldCoor struct.""" + + thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag") __repr__ = _swig_repr - __swig_setmethods__["xref"] = _wcs.WorldCoor_xref_set - __swig_getmethods__["xref"] = _wcs.WorldCoor_xref_get - if _newclass:xref = _swig_property(_wcs.WorldCoor_xref_get, _wcs.WorldCoor_xref_set) - __swig_setmethods__["yref"] = _wcs.WorldCoor_yref_set - __swig_getmethods__["yref"] = _wcs.WorldCoor_yref_get - if _newclass:yref = _swig_property(_wcs.WorldCoor_yref_get, _wcs.WorldCoor_yref_set) - __swig_setmethods__["xrefpix"] = _wcs.WorldCoor_xrefpix_set - __swig_getmethods__["xrefpix"] = _wcs.WorldCoor_xrefpix_get - if _newclass:xrefpix = _swig_property(_wcs.WorldCoor_xrefpix_get, _wcs.WorldCoor_xrefpix_set) - __swig_setmethods__["yrefpix"] = _wcs.WorldCoor_yrefpix_set - __swig_getmethods__["yrefpix"] = _wcs.WorldCoor_yrefpix_get - if _newclass:yrefpix = _swig_property(_wcs.WorldCoor_yrefpix_get, _wcs.WorldCoor_yrefpix_set) - __swig_setmethods__["xinc"] = _wcs.WorldCoor_xinc_set - __swig_getmethods__["xinc"] = _wcs.WorldCoor_xinc_get - if _newclass:xinc = _swig_property(_wcs.WorldCoor_xinc_get, _wcs.WorldCoor_xinc_set) - __swig_setmethods__["yinc"] = _wcs.WorldCoor_yinc_set - __swig_getmethods__["yinc"] = _wcs.WorldCoor_yinc_get - if _newclass:yinc = _swig_property(_wcs.WorldCoor_yinc_get, _wcs.WorldCoor_yinc_set) - __swig_setmethods__["rot"] = _wcs.WorldCoor_rot_set - __swig_getmethods__["rot"] = _wcs.WorldCoor_rot_get - if _newclass:rot = _swig_property(_wcs.WorldCoor_rot_get, _wcs.WorldCoor_rot_set) - __swig_setmethods__["cd"] = _wcs.WorldCoor_cd_set - __swig_getmethods__["cd"] = _wcs.WorldCoor_cd_get - if _newclass:cd = _swig_property(_wcs.WorldCoor_cd_get, _wcs.WorldCoor_cd_set) - __swig_setmethods__["dc"] = _wcs.WorldCoor_dc_set - __swig_getmethods__["dc"] = _wcs.WorldCoor_dc_get - if _newclass:dc = _swig_property(_wcs.WorldCoor_dc_get, _wcs.WorldCoor_dc_set) - __swig_setmethods__["equinox"] = _wcs.WorldCoor_equinox_set - __swig_getmethods__["equinox"] = _wcs.WorldCoor_equinox_get - if _newclass:equinox = _swig_property(_wcs.WorldCoor_equinox_get, _wcs.WorldCoor_equinox_set) - __swig_setmethods__["epoch"] = _wcs.WorldCoor_epoch_set - __swig_getmethods__["epoch"] = _wcs.WorldCoor_epoch_get - if _newclass:epoch = _swig_property(_wcs.WorldCoor_epoch_get, _wcs.WorldCoor_epoch_set) - __swig_setmethods__["nxpix"] = _wcs.WorldCoor_nxpix_set - __swig_getmethods__["nxpix"] = _wcs.WorldCoor_nxpix_get - if _newclass:nxpix = _swig_property(_wcs.WorldCoor_nxpix_get, _wcs.WorldCoor_nxpix_set) - __swig_setmethods__["nypix"] = _wcs.WorldCoor_nypix_set - __swig_getmethods__["nypix"] = _wcs.WorldCoor_nypix_get - if _newclass:nypix = _swig_property(_wcs.WorldCoor_nypix_get, _wcs.WorldCoor_nypix_set) - __swig_setmethods__["plate_ra"] = _wcs.WorldCoor_plate_ra_set - __swig_getmethods__["plate_ra"] = _wcs.WorldCoor_plate_ra_get - if _newclass:plate_ra = _swig_property(_wcs.WorldCoor_plate_ra_get, _wcs.WorldCoor_plate_ra_set) - __swig_setmethods__["plate_dec"] = _wcs.WorldCoor_plate_dec_set - __swig_getmethods__["plate_dec"] = _wcs.WorldCoor_plate_dec_get - if _newclass:plate_dec = _swig_property(_wcs.WorldCoor_plate_dec_get, _wcs.WorldCoor_plate_dec_set) - __swig_setmethods__["plate_scale"] = _wcs.WorldCoor_plate_scale_set - __swig_getmethods__["plate_scale"] = _wcs.WorldCoor_plate_scale_get - if _newclass:plate_scale = _swig_property(_wcs.WorldCoor_plate_scale_get, _wcs.WorldCoor_plate_scale_set) - __swig_setmethods__["x_pixel_offset"] = _wcs.WorldCoor_x_pixel_offset_set - __swig_getmethods__["x_pixel_offset"] = _wcs.WorldCoor_x_pixel_offset_get - if _newclass:x_pixel_offset = _swig_property(_wcs.WorldCoor_x_pixel_offset_get, _wcs.WorldCoor_x_pixel_offset_set) - __swig_setmethods__["y_pixel_offset"] = _wcs.WorldCoor_y_pixel_offset_set - __swig_getmethods__["y_pixel_offset"] = _wcs.WorldCoor_y_pixel_offset_get - if _newclass:y_pixel_offset = _swig_property(_wcs.WorldCoor_y_pixel_offset_get, _wcs.WorldCoor_y_pixel_offset_set) - __swig_setmethods__["x_pixel_size"] = _wcs.WorldCoor_x_pixel_size_set - __swig_getmethods__["x_pixel_size"] = _wcs.WorldCoor_x_pixel_size_get - if _newclass:x_pixel_size = _swig_property(_wcs.WorldCoor_x_pixel_size_get, _wcs.WorldCoor_x_pixel_size_set) - __swig_setmethods__["y_pixel_size"] = _wcs.WorldCoor_y_pixel_size_set - __swig_getmethods__["y_pixel_size"] = _wcs.WorldCoor_y_pixel_size_get - if _newclass:y_pixel_size = _swig_property(_wcs.WorldCoor_y_pixel_size_get, _wcs.WorldCoor_y_pixel_size_set) - __swig_setmethods__["ppo_coeff"] = _wcs.WorldCoor_ppo_coeff_set - __swig_getmethods__["ppo_coeff"] = _wcs.WorldCoor_ppo_coeff_get - if _newclass:ppo_coeff = _swig_property(_wcs.WorldCoor_ppo_coeff_get, _wcs.WorldCoor_ppo_coeff_set) - __swig_setmethods__["x_coeff"] = _wcs.WorldCoor_x_coeff_set - __swig_getmethods__["x_coeff"] = _wcs.WorldCoor_x_coeff_get - if _newclass:x_coeff = _swig_property(_wcs.WorldCoor_x_coeff_get, _wcs.WorldCoor_x_coeff_set) - __swig_setmethods__["y_coeff"] = _wcs.WorldCoor_y_coeff_set - __swig_getmethods__["y_coeff"] = _wcs.WorldCoor_y_coeff_get - if _newclass:y_coeff = _swig_property(_wcs.WorldCoor_y_coeff_get, _wcs.WorldCoor_y_coeff_set) - __swig_setmethods__["xpix"] = _wcs.WorldCoor_xpix_set - __swig_getmethods__["xpix"] = _wcs.WorldCoor_xpix_get - if _newclass:xpix = _swig_property(_wcs.WorldCoor_xpix_get, _wcs.WorldCoor_xpix_set) - __swig_setmethods__["ypix"] = _wcs.WorldCoor_ypix_set - __swig_getmethods__["ypix"] = _wcs.WorldCoor_ypix_get - if _newclass:ypix = _swig_property(_wcs.WorldCoor_ypix_get, _wcs.WorldCoor_ypix_set) - __swig_setmethods__["zpix"] = _wcs.WorldCoor_zpix_set - __swig_getmethods__["zpix"] = _wcs.WorldCoor_zpix_get - if _newclass:zpix = _swig_property(_wcs.WorldCoor_zpix_get, _wcs.WorldCoor_zpix_set) - __swig_setmethods__["xpos"] = _wcs.WorldCoor_xpos_set - __swig_getmethods__["xpos"] = _wcs.WorldCoor_xpos_get - if _newclass:xpos = _swig_property(_wcs.WorldCoor_xpos_get, _wcs.WorldCoor_xpos_set) - __swig_setmethods__["ypos"] = _wcs.WorldCoor_ypos_set - __swig_getmethods__["ypos"] = _wcs.WorldCoor_ypos_get - if _newclass:ypos = _swig_property(_wcs.WorldCoor_ypos_get, _wcs.WorldCoor_ypos_set) - __swig_setmethods__["crpix"] = _wcs.WorldCoor_crpix_set - __swig_getmethods__["crpix"] = _wcs.WorldCoor_crpix_get - if _newclass:crpix = _swig_property(_wcs.WorldCoor_crpix_get, _wcs.WorldCoor_crpix_set) - __swig_setmethods__["crval"] = _wcs.WorldCoor_crval_set - __swig_getmethods__["crval"] = _wcs.WorldCoor_crval_get - if _newclass:crval = _swig_property(_wcs.WorldCoor_crval_get, _wcs.WorldCoor_crval_set) - __swig_setmethods__["cdelt"] = _wcs.WorldCoor_cdelt_set - __swig_getmethods__["cdelt"] = _wcs.WorldCoor_cdelt_get - if _newclass:cdelt = _swig_property(_wcs.WorldCoor_cdelt_get, _wcs.WorldCoor_cdelt_set) - __swig_setmethods__["pc"] = _wcs.WorldCoor_pc_set - __swig_getmethods__["pc"] = _wcs.WorldCoor_pc_get - if _newclass:pc = _swig_property(_wcs.WorldCoor_pc_get, _wcs.WorldCoor_pc_set) - __swig_setmethods__["projp"] = _wcs.WorldCoor_projp_set - __swig_getmethods__["projp"] = _wcs.WorldCoor_projp_get - if _newclass:projp = _swig_property(_wcs.WorldCoor_projp_get, _wcs.WorldCoor_projp_set) - __swig_setmethods__["pvfail"] = _wcs.WorldCoor_pvfail_set - __swig_getmethods__["pvfail"] = _wcs.WorldCoor_pvfail_get - if _newclass:pvfail = _swig_property(_wcs.WorldCoor_pvfail_get, _wcs.WorldCoor_pvfail_set) - __swig_setmethods__["projppv"] = _wcs.WorldCoor_projppv_set - __swig_getmethods__["projppv"] = _wcs.WorldCoor_projppv_get - if _newclass:projppv = _swig_property(_wcs.WorldCoor_projppv_get, _wcs.WorldCoor_projppv_set) - __swig_setmethods__["inv_x"] = _wcs.WorldCoor_inv_x_set - __swig_getmethods__["inv_x"] = _wcs.WorldCoor_inv_x_get - if _newclass:inv_x = _swig_property(_wcs.WorldCoor_inv_x_get, _wcs.WorldCoor_inv_x_set) - __swig_setmethods__["inv_y"] = _wcs.WorldCoor_inv_y_set - __swig_getmethods__["inv_y"] = _wcs.WorldCoor_inv_y_get - if _newclass:inv_y = _swig_property(_wcs.WorldCoor_inv_y_get, _wcs.WorldCoor_inv_y_set) - __swig_setmethods__["longpole"] = _wcs.WorldCoor_longpole_set - __swig_getmethods__["longpole"] = _wcs.WorldCoor_longpole_get - if _newclass:longpole = _swig_property(_wcs.WorldCoor_longpole_get, _wcs.WorldCoor_longpole_set) - __swig_setmethods__["latpole"] = _wcs.WorldCoor_latpole_set - __swig_getmethods__["latpole"] = _wcs.WorldCoor_latpole_get - if _newclass:latpole = _swig_property(_wcs.WorldCoor_latpole_get, _wcs.WorldCoor_latpole_set) - __swig_setmethods__["rodeg"] = _wcs.WorldCoor_rodeg_set - __swig_getmethods__["rodeg"] = _wcs.WorldCoor_rodeg_get - if _newclass:rodeg = _swig_property(_wcs.WorldCoor_rodeg_get, _wcs.WorldCoor_rodeg_set) - __swig_setmethods__["imrot"] = _wcs.WorldCoor_imrot_set - __swig_getmethods__["imrot"] = _wcs.WorldCoor_imrot_get - if _newclass:imrot = _swig_property(_wcs.WorldCoor_imrot_get, _wcs.WorldCoor_imrot_set) - __swig_setmethods__["pa_north"] = _wcs.WorldCoor_pa_north_set - __swig_getmethods__["pa_north"] = _wcs.WorldCoor_pa_north_get - if _newclass:pa_north = _swig_property(_wcs.WorldCoor_pa_north_get, _wcs.WorldCoor_pa_north_set) - __swig_setmethods__["pa_east"] = _wcs.WorldCoor_pa_east_set - __swig_getmethods__["pa_east"] = _wcs.WorldCoor_pa_east_get - if _newclass:pa_east = _swig_property(_wcs.WorldCoor_pa_east_get, _wcs.WorldCoor_pa_east_set) - __swig_setmethods__["radvel"] = _wcs.WorldCoor_radvel_set - __swig_getmethods__["radvel"] = _wcs.WorldCoor_radvel_get - if _newclass:radvel = _swig_property(_wcs.WorldCoor_radvel_get, _wcs.WorldCoor_radvel_set) - __swig_setmethods__["zvel"] = _wcs.WorldCoor_zvel_set - __swig_getmethods__["zvel"] = _wcs.WorldCoor_zvel_get - if _newclass:zvel = _swig_property(_wcs.WorldCoor_zvel_get, _wcs.WorldCoor_zvel_set) - __swig_setmethods__["zpzd"] = _wcs.WorldCoor_zpzd_set - __swig_getmethods__["zpzd"] = _wcs.WorldCoor_zpzd_get - if _newclass:zpzd = _swig_property(_wcs.WorldCoor_zpzd_get, _wcs.WorldCoor_zpzd_set) - __swig_setmethods__["zpr"] = _wcs.WorldCoor_zpr_set - __swig_getmethods__["zpr"] = _wcs.WorldCoor_zpr_get - if _newclass:zpr = _swig_property(_wcs.WorldCoor_zpr_get, _wcs.WorldCoor_zpr_set) - __swig_setmethods__["imflip"] = _wcs.WorldCoor_imflip_set - __swig_getmethods__["imflip"] = _wcs.WorldCoor_imflip_get - if _newclass:imflip = _swig_property(_wcs.WorldCoor_imflip_get, _wcs.WorldCoor_imflip_set) - __swig_setmethods__["prjcode"] = _wcs.WorldCoor_prjcode_set - __swig_getmethods__["prjcode"] = _wcs.WorldCoor_prjcode_get - if _newclass:prjcode = _swig_property(_wcs.WorldCoor_prjcode_get, _wcs.WorldCoor_prjcode_set) - __swig_setmethods__["latbase"] = _wcs.WorldCoor_latbase_set - __swig_getmethods__["latbase"] = _wcs.WorldCoor_latbase_get - if _newclass:latbase = _swig_property(_wcs.WorldCoor_latbase_get, _wcs.WorldCoor_latbase_set) - __swig_setmethods__["ncoeff1"] = _wcs.WorldCoor_ncoeff1_set - __swig_getmethods__["ncoeff1"] = _wcs.WorldCoor_ncoeff1_get - if _newclass:ncoeff1 = _swig_property(_wcs.WorldCoor_ncoeff1_get, _wcs.WorldCoor_ncoeff1_set) - __swig_setmethods__["ncoeff2"] = _wcs.WorldCoor_ncoeff2_set - __swig_getmethods__["ncoeff2"] = _wcs.WorldCoor_ncoeff2_get - if _newclass:ncoeff2 = _swig_property(_wcs.WorldCoor_ncoeff2_get, _wcs.WorldCoor_ncoeff2_set) - __swig_setmethods__["zpnp"] = _wcs.WorldCoor_zpnp_set - __swig_getmethods__["zpnp"] = _wcs.WorldCoor_zpnp_get - if _newclass:zpnp = _swig_property(_wcs.WorldCoor_zpnp_get, _wcs.WorldCoor_zpnp_set) - __swig_setmethods__["changesys"] = _wcs.WorldCoor_changesys_set - __swig_getmethods__["changesys"] = _wcs.WorldCoor_changesys_get - if _newclass:changesys = _swig_property(_wcs.WorldCoor_changesys_get, _wcs.WorldCoor_changesys_set) - __swig_setmethods__["printsys"] = _wcs.WorldCoor_printsys_set - __swig_getmethods__["printsys"] = _wcs.WorldCoor_printsys_get - if _newclass:printsys = _swig_property(_wcs.WorldCoor_printsys_get, _wcs.WorldCoor_printsys_set) - __swig_setmethods__["ndec"] = _wcs.WorldCoor_ndec_set - __swig_getmethods__["ndec"] = _wcs.WorldCoor_ndec_get - if _newclass:ndec = _swig_property(_wcs.WorldCoor_ndec_get, _wcs.WorldCoor_ndec_set) - __swig_setmethods__["degout"] = _wcs.WorldCoor_degout_set - __swig_getmethods__["degout"] = _wcs.WorldCoor_degout_get - if _newclass:degout = _swig_property(_wcs.WorldCoor_degout_get, _wcs.WorldCoor_degout_set) - __swig_setmethods__["tabsys"] = _wcs.WorldCoor_tabsys_set - __swig_getmethods__["tabsys"] = _wcs.WorldCoor_tabsys_get - if _newclass:tabsys = _swig_property(_wcs.WorldCoor_tabsys_get, _wcs.WorldCoor_tabsys_set) - __swig_setmethods__["rotmat"] = _wcs.WorldCoor_rotmat_set - __swig_getmethods__["rotmat"] = _wcs.WorldCoor_rotmat_get - if _newclass:rotmat = _swig_property(_wcs.WorldCoor_rotmat_get, _wcs.WorldCoor_rotmat_set) - __swig_setmethods__["coorflip"] = _wcs.WorldCoor_coorflip_set - __swig_getmethods__["coorflip"] = _wcs.WorldCoor_coorflip_get - if _newclass:coorflip = _swig_property(_wcs.WorldCoor_coorflip_get, _wcs.WorldCoor_coorflip_set) - __swig_setmethods__["offscl"] = _wcs.WorldCoor_offscl_set - __swig_getmethods__["offscl"] = _wcs.WorldCoor_offscl_get - if _newclass:offscl = _swig_property(_wcs.WorldCoor_offscl_get, _wcs.WorldCoor_offscl_set) - __swig_setmethods__["wcson"] = _wcs.WorldCoor_wcson_set - __swig_getmethods__["wcson"] = _wcs.WorldCoor_wcson_get - if _newclass:wcson = _swig_property(_wcs.WorldCoor_wcson_get, _wcs.WorldCoor_wcson_set) - __swig_setmethods__["naxis"] = _wcs.WorldCoor_naxis_set - __swig_getmethods__["naxis"] = _wcs.WorldCoor_naxis_get - if _newclass:naxis = _swig_property(_wcs.WorldCoor_naxis_get, _wcs.WorldCoor_naxis_set) - __swig_setmethods__["naxes"] = _wcs.WorldCoor_naxes_set - __swig_getmethods__["naxes"] = _wcs.WorldCoor_naxes_get - if _newclass:naxes = _swig_property(_wcs.WorldCoor_naxes_get, _wcs.WorldCoor_naxes_set) - __swig_setmethods__["wcsproj"] = _wcs.WorldCoor_wcsproj_set - __swig_getmethods__["wcsproj"] = _wcs.WorldCoor_wcsproj_get - if _newclass:wcsproj = _swig_property(_wcs.WorldCoor_wcsproj_get, _wcs.WorldCoor_wcsproj_set) - __swig_setmethods__["linmode"] = _wcs.WorldCoor_linmode_set - __swig_getmethods__["linmode"] = _wcs.WorldCoor_linmode_get - if _newclass:linmode = _swig_property(_wcs.WorldCoor_linmode_get, _wcs.WorldCoor_linmode_set) - __swig_setmethods__["detector"] = _wcs.WorldCoor_detector_set - __swig_getmethods__["detector"] = _wcs.WorldCoor_detector_get - if _newclass:detector = _swig_property(_wcs.WorldCoor_detector_get, _wcs.WorldCoor_detector_set) - __swig_setmethods__["instrument"] = _wcs.WorldCoor_instrument_set - __swig_getmethods__["instrument"] = _wcs.WorldCoor_instrument_get - if _newclass:instrument = _swig_property(_wcs.WorldCoor_instrument_get, _wcs.WorldCoor_instrument_set) - __swig_setmethods__["ctype"] = _wcs.WorldCoor_ctype_set - __swig_getmethods__["ctype"] = _wcs.WorldCoor_ctype_get - if _newclass:ctype = _swig_property(_wcs.WorldCoor_ctype_get, _wcs.WorldCoor_ctype_set) - __swig_setmethods__["c1type"] = _wcs.WorldCoor_c1type_set - __swig_getmethods__["c1type"] = _wcs.WorldCoor_c1type_get - if _newclass:c1type = _swig_property(_wcs.WorldCoor_c1type_get, _wcs.WorldCoor_c1type_set) - __swig_setmethods__["c2type"] = _wcs.WorldCoor_c2type_set - __swig_getmethods__["c2type"] = _wcs.WorldCoor_c2type_get - if _newclass:c2type = _swig_property(_wcs.WorldCoor_c2type_get, _wcs.WorldCoor_c2type_set) - __swig_setmethods__["ptype"] = _wcs.WorldCoor_ptype_set - __swig_getmethods__["ptype"] = _wcs.WorldCoor_ptype_get - if _newclass:ptype = _swig_property(_wcs.WorldCoor_ptype_get, _wcs.WorldCoor_ptype_set) - __swig_setmethods__["units"] = _wcs.WorldCoor_units_set - __swig_getmethods__["units"] = _wcs.WorldCoor_units_get - if _newclass:units = _swig_property(_wcs.WorldCoor_units_get, _wcs.WorldCoor_units_set) - __swig_setmethods__["radecsys"] = _wcs.WorldCoor_radecsys_set - __swig_getmethods__["radecsys"] = _wcs.WorldCoor_radecsys_get - if _newclass:radecsys = _swig_property(_wcs.WorldCoor_radecsys_get, _wcs.WorldCoor_radecsys_set) - __swig_setmethods__["radecout"] = _wcs.WorldCoor_radecout_set - __swig_getmethods__["radecout"] = _wcs.WorldCoor_radecout_get - if _newclass:radecout = _swig_property(_wcs.WorldCoor_radecout_get, _wcs.WorldCoor_radecout_set) - __swig_setmethods__["radecin"] = _wcs.WorldCoor_radecin_set - __swig_getmethods__["radecin"] = _wcs.WorldCoor_radecin_get - if _newclass:radecin = _swig_property(_wcs.WorldCoor_radecin_get, _wcs.WorldCoor_radecin_set) - __swig_setmethods__["eqin"] = _wcs.WorldCoor_eqin_set - __swig_getmethods__["eqin"] = _wcs.WorldCoor_eqin_get - if _newclass:eqin = _swig_property(_wcs.WorldCoor_eqin_get, _wcs.WorldCoor_eqin_set) - __swig_setmethods__["eqout"] = _wcs.WorldCoor_eqout_set - __swig_getmethods__["eqout"] = _wcs.WorldCoor_eqout_get - if _newclass:eqout = _swig_property(_wcs.WorldCoor_eqout_get, _wcs.WorldCoor_eqout_set) - __swig_setmethods__["sysin"] = _wcs.WorldCoor_sysin_set - __swig_getmethods__["sysin"] = _wcs.WorldCoor_sysin_get - if _newclass:sysin = _swig_property(_wcs.WorldCoor_sysin_get, _wcs.WorldCoor_sysin_set) - __swig_setmethods__["syswcs"] = _wcs.WorldCoor_syswcs_set - __swig_getmethods__["syswcs"] = _wcs.WorldCoor_syswcs_get - if _newclass:syswcs = _swig_property(_wcs.WorldCoor_syswcs_get, _wcs.WorldCoor_syswcs_set) - __swig_setmethods__["sysout"] = _wcs.WorldCoor_sysout_set - __swig_getmethods__["sysout"] = _wcs.WorldCoor_sysout_get - if _newclass:sysout = _swig_property(_wcs.WorldCoor_sysout_get, _wcs.WorldCoor_sysout_set) - __swig_setmethods__["center"] = _wcs.WorldCoor_center_set - __swig_getmethods__["center"] = _wcs.WorldCoor_center_get - if _newclass:center = _swig_property(_wcs.WorldCoor_center_get, _wcs.WorldCoor_center_set) - __swig_setmethods__["wcsl"] = _wcs.WorldCoor_wcsl_set - __swig_getmethods__["wcsl"] = _wcs.WorldCoor_wcsl_get - if _newclass:wcsl = _swig_property(_wcs.WorldCoor_wcsl_get, _wcs.WorldCoor_wcsl_set) - __swig_setmethods__["lin"] = _wcs.WorldCoor_lin_set - __swig_getmethods__["lin"] = _wcs.WorldCoor_lin_get - if _newclass:lin = _swig_property(_wcs.WorldCoor_lin_get, _wcs.WorldCoor_lin_set) - __swig_setmethods__["cel"] = _wcs.WorldCoor_cel_set - __swig_getmethods__["cel"] = _wcs.WorldCoor_cel_get - if _newclass:cel = _swig_property(_wcs.WorldCoor_cel_get, _wcs.WorldCoor_cel_set) - __swig_setmethods__["prj"] = _wcs.WorldCoor_prj_set - __swig_getmethods__["prj"] = _wcs.WorldCoor_prj_get - if _newclass:prj = _swig_property(_wcs.WorldCoor_prj_get, _wcs.WorldCoor_prj_set) - __swig_setmethods__["lngcor"] = _wcs.WorldCoor_lngcor_set - __swig_getmethods__["lngcor"] = _wcs.WorldCoor_lngcor_get - if _newclass:lngcor = _swig_property(_wcs.WorldCoor_lngcor_get, _wcs.WorldCoor_lngcor_set) - __swig_setmethods__["latcor"] = _wcs.WorldCoor_latcor_set - __swig_getmethods__["latcor"] = _wcs.WorldCoor_latcor_get - if _newclass:latcor = _swig_property(_wcs.WorldCoor_latcor_get, _wcs.WorldCoor_latcor_set) - __swig_setmethods__["distcode"] = _wcs.WorldCoor_distcode_set - __swig_getmethods__["distcode"] = _wcs.WorldCoor_distcode_get - if _newclass:distcode = _swig_property(_wcs.WorldCoor_distcode_get, _wcs.WorldCoor_distcode_set) - __swig_setmethods__["distort"] = _wcs.WorldCoor_distort_set - __swig_getmethods__["distort"] = _wcs.WorldCoor_distort_get - if _newclass:distort = _swig_property(_wcs.WorldCoor_distort_get, _wcs.WorldCoor_distort_set) - __swig_setmethods__["command_format"] = _wcs.WorldCoor_command_format_set - __swig_getmethods__["command_format"] = _wcs.WorldCoor_command_format_get - if _newclass:command_format = _swig_property(_wcs.WorldCoor_command_format_get, _wcs.WorldCoor_command_format_set) - __swig_setmethods__["ltm"] = _wcs.WorldCoor_ltm_set - __swig_getmethods__["ltm"] = _wcs.WorldCoor_ltm_get - if _newclass:ltm = _swig_property(_wcs.WorldCoor_ltm_get, _wcs.WorldCoor_ltm_set) - __swig_setmethods__["ltv"] = _wcs.WorldCoor_ltv_set - __swig_getmethods__["ltv"] = _wcs.WorldCoor_ltv_get - if _newclass:ltv = _swig_property(_wcs.WorldCoor_ltv_get, _wcs.WorldCoor_ltv_set) - __swig_setmethods__["idpix"] = _wcs.WorldCoor_idpix_set - __swig_getmethods__["idpix"] = _wcs.WorldCoor_idpix_get - if _newclass:idpix = _swig_property(_wcs.WorldCoor_idpix_get, _wcs.WorldCoor_idpix_set) - __swig_setmethods__["ndpix"] = _wcs.WorldCoor_ndpix_set - __swig_getmethods__["ndpix"] = _wcs.WorldCoor_ndpix_get - if _newclass:ndpix = _swig_property(_wcs.WorldCoor_ndpix_get, _wcs.WorldCoor_ndpix_set) - __swig_setmethods__["wcs"] = _wcs.WorldCoor_wcs_set - __swig_getmethods__["wcs"] = _wcs.WorldCoor_wcs_get - if _newclass:wcs = _swig_property(_wcs.WorldCoor_wcs_get, _wcs.WorldCoor_wcs_set) - __swig_setmethods__["wcsdep"] = _wcs.WorldCoor_wcsdep_set - __swig_getmethods__["wcsdep"] = _wcs.WorldCoor_wcsdep_get - if _newclass:wcsdep = _swig_property(_wcs.WorldCoor_wcsdep_get, _wcs.WorldCoor_wcsdep_set) - __swig_setmethods__["wcsname"] = _wcs.WorldCoor_wcsname_set - __swig_getmethods__["wcsname"] = _wcs.WorldCoor_wcsname_get - if _newclass:wcsname = _swig_property(_wcs.WorldCoor_wcsname_get, _wcs.WorldCoor_wcsname_set) - __swig_setmethods__["wcschar"] = _wcs.WorldCoor_wcschar_set - __swig_getmethods__["wcschar"] = _wcs.WorldCoor_wcschar_get - if _newclass:wcschar = _swig_property(_wcs.WorldCoor_wcschar_get, _wcs.WorldCoor_wcschar_set) - __swig_setmethods__["logwcs"] = _wcs.WorldCoor_logwcs_set - __swig_getmethods__["logwcs"] = _wcs.WorldCoor_logwcs_get - if _newclass:logwcs = _swig_property(_wcs.WorldCoor_logwcs_get, _wcs.WorldCoor_logwcs_set) - def __init__(self): - """__init__(self) -> WorldCoor""" - this = _wcs.new_WorldCoor() - try: self.this.append(this) - except: self.this = this + xref = property(_wcs.WorldCoor_xref_get, _wcs.WorldCoor_xref_set, doc=r"""xref""") + yref = property(_wcs.WorldCoor_yref_get, _wcs.WorldCoor_yref_set, doc=r"""yref""") + xrefpix = property(_wcs.WorldCoor_xrefpix_get, _wcs.WorldCoor_xrefpix_set, doc=r"""xrefpix""") + yrefpix = property(_wcs.WorldCoor_yrefpix_get, _wcs.WorldCoor_yrefpix_set, doc=r"""yrefpix""") + xinc = property(_wcs.WorldCoor_xinc_get, _wcs.WorldCoor_xinc_set, doc=r"""xinc""") + yinc = property(_wcs.WorldCoor_yinc_get, _wcs.WorldCoor_yinc_set, doc=r"""yinc""") + rot = property(_wcs.WorldCoor_rot_get, _wcs.WorldCoor_rot_set, doc=r"""rot""") + cd = property(_wcs.WorldCoor_cd_get, _wcs.WorldCoor_cd_set, doc=r"""cd""") + dc = property(_wcs.WorldCoor_dc_get, _wcs.WorldCoor_dc_set, doc=r"""dc""") + equinox = property(_wcs.WorldCoor_equinox_get, _wcs.WorldCoor_equinox_set, doc=r"""equinox""") + epoch = property(_wcs.WorldCoor_epoch_get, _wcs.WorldCoor_epoch_set, doc=r"""epoch""") + nxpix = property(_wcs.WorldCoor_nxpix_get, _wcs.WorldCoor_nxpix_set, doc=r"""nxpix""") + nypix = property(_wcs.WorldCoor_nypix_get, _wcs.WorldCoor_nypix_set, doc=r"""nypix""") + plate_ra = property(_wcs.WorldCoor_plate_ra_get, _wcs.WorldCoor_plate_ra_set, doc=r"""plate_ra""") + plate_dec = property(_wcs.WorldCoor_plate_dec_get, _wcs.WorldCoor_plate_dec_set, doc=r"""plate_dec""") + plate_scale = property(_wcs.WorldCoor_plate_scale_get, _wcs.WorldCoor_plate_scale_set, doc=r"""plate_scale""") + x_pixel_offset = property(_wcs.WorldCoor_x_pixel_offset_get, _wcs.WorldCoor_x_pixel_offset_set, doc=r"""x_pixel_offset""") + y_pixel_offset = property(_wcs.WorldCoor_y_pixel_offset_get, _wcs.WorldCoor_y_pixel_offset_set, doc=r"""y_pixel_offset""") + x_pixel_size = property(_wcs.WorldCoor_x_pixel_size_get, _wcs.WorldCoor_x_pixel_size_set, doc=r"""x_pixel_size""") + y_pixel_size = property(_wcs.WorldCoor_y_pixel_size_get, _wcs.WorldCoor_y_pixel_size_set, doc=r"""y_pixel_size""") + ppo_coeff = property(_wcs.WorldCoor_ppo_coeff_get, _wcs.WorldCoor_ppo_coeff_set, doc=r"""ppo_coeff""") + x_coeff = property(_wcs.WorldCoor_x_coeff_get, _wcs.WorldCoor_x_coeff_set, doc=r"""x_coeff""") + y_coeff = property(_wcs.WorldCoor_y_coeff_get, _wcs.WorldCoor_y_coeff_set, doc=r"""y_coeff""") + xpix = property(_wcs.WorldCoor_xpix_get, _wcs.WorldCoor_xpix_set, doc=r"""xpix""") + ypix = property(_wcs.WorldCoor_ypix_get, _wcs.WorldCoor_ypix_set, doc=r"""ypix""") + zpix = property(_wcs.WorldCoor_zpix_get, _wcs.WorldCoor_zpix_set, doc=r"""zpix""") + xpos = property(_wcs.WorldCoor_xpos_get, _wcs.WorldCoor_xpos_set, doc=r"""xpos""") + ypos = property(_wcs.WorldCoor_ypos_get, _wcs.WorldCoor_ypos_set, doc=r"""ypos""") + crpix = property(_wcs.WorldCoor_crpix_get, _wcs.WorldCoor_crpix_set, doc=r"""crpix""") + crval = property(_wcs.WorldCoor_crval_get, _wcs.WorldCoor_crval_set, doc=r"""crval""") + cdelt = property(_wcs.WorldCoor_cdelt_get, _wcs.WorldCoor_cdelt_set, doc=r"""cdelt""") + pc = property(_wcs.WorldCoor_pc_get, _wcs.WorldCoor_pc_set, doc=r"""pc""") + projp = property(_wcs.WorldCoor_projp_get, _wcs.WorldCoor_projp_set, doc=r"""projp""") + pvfail = property(_wcs.WorldCoor_pvfail_get, _wcs.WorldCoor_pvfail_set, doc=r"""pvfail""") + projppv = property(_wcs.WorldCoor_projppv_get, _wcs.WorldCoor_projppv_set, doc=r"""projppv""") + inv_x = property(_wcs.WorldCoor_inv_x_get, _wcs.WorldCoor_inv_x_set, doc=r"""inv_x""") + inv_y = property(_wcs.WorldCoor_inv_y_get, _wcs.WorldCoor_inv_y_set, doc=r"""inv_y""") + longpole = property(_wcs.WorldCoor_longpole_get, _wcs.WorldCoor_longpole_set, doc=r"""longpole""") + latpole = property(_wcs.WorldCoor_latpole_get, _wcs.WorldCoor_latpole_set, doc=r"""latpole""") + rodeg = property(_wcs.WorldCoor_rodeg_get, _wcs.WorldCoor_rodeg_set, doc=r"""rodeg""") + imrot = property(_wcs.WorldCoor_imrot_get, _wcs.WorldCoor_imrot_set, doc=r"""imrot""") + pa_north = property(_wcs.WorldCoor_pa_north_get, _wcs.WorldCoor_pa_north_set, doc=r"""pa_north""") + pa_east = property(_wcs.WorldCoor_pa_east_get, _wcs.WorldCoor_pa_east_set, doc=r"""pa_east""") + radvel = property(_wcs.WorldCoor_radvel_get, _wcs.WorldCoor_radvel_set, doc=r"""radvel""") + zvel = property(_wcs.WorldCoor_zvel_get, _wcs.WorldCoor_zvel_set, doc=r"""zvel""") + zpzd = property(_wcs.WorldCoor_zpzd_get, _wcs.WorldCoor_zpzd_set, doc=r"""zpzd""") + zpr = property(_wcs.WorldCoor_zpr_get, _wcs.WorldCoor_zpr_set, doc=r"""zpr""") + imflip = property(_wcs.WorldCoor_imflip_get, _wcs.WorldCoor_imflip_set, doc=r"""imflip""") + prjcode = property(_wcs.WorldCoor_prjcode_get, _wcs.WorldCoor_prjcode_set, doc=r"""prjcode""") + latbase = property(_wcs.WorldCoor_latbase_get, _wcs.WorldCoor_latbase_set, doc=r"""latbase""") + ncoeff1 = property(_wcs.WorldCoor_ncoeff1_get, _wcs.WorldCoor_ncoeff1_set, doc=r"""ncoeff1""") + ncoeff2 = property(_wcs.WorldCoor_ncoeff2_get, _wcs.WorldCoor_ncoeff2_set, doc=r"""ncoeff2""") + zpnp = property(_wcs.WorldCoor_zpnp_get, _wcs.WorldCoor_zpnp_set, doc=r"""zpnp""") + changesys = property(_wcs.WorldCoor_changesys_get, _wcs.WorldCoor_changesys_set, doc=r"""changesys""") + printsys = property(_wcs.WorldCoor_printsys_get, _wcs.WorldCoor_printsys_set, doc=r"""printsys""") + ndec = property(_wcs.WorldCoor_ndec_get, _wcs.WorldCoor_ndec_set, doc=r"""ndec""") + degout = property(_wcs.WorldCoor_degout_get, _wcs.WorldCoor_degout_set, doc=r"""degout""") + tabsys = property(_wcs.WorldCoor_tabsys_get, _wcs.WorldCoor_tabsys_set, doc=r"""tabsys""") + rotmat = property(_wcs.WorldCoor_rotmat_get, _wcs.WorldCoor_rotmat_set, doc=r"""rotmat""") + coorflip = property(_wcs.WorldCoor_coorflip_get, _wcs.WorldCoor_coorflip_set, doc=r"""coorflip""") + offscl = property(_wcs.WorldCoor_offscl_get, _wcs.WorldCoor_offscl_set, doc=r"""offscl""") + wcson = property(_wcs.WorldCoor_wcson_get, _wcs.WorldCoor_wcson_set, doc=r"""wcson""") + naxis = property(_wcs.WorldCoor_naxis_get, _wcs.WorldCoor_naxis_set, doc=r"""naxis""") + naxes = property(_wcs.WorldCoor_naxes_get, _wcs.WorldCoor_naxes_set, doc=r"""naxes""") + wcsproj = property(_wcs.WorldCoor_wcsproj_get, _wcs.WorldCoor_wcsproj_set, doc=r"""wcsproj""") + linmode = property(_wcs.WorldCoor_linmode_get, _wcs.WorldCoor_linmode_set, doc=r"""linmode""") + detector = property(_wcs.WorldCoor_detector_get, _wcs.WorldCoor_detector_set, doc=r"""detector""") + instrument = property(_wcs.WorldCoor_instrument_get, _wcs.WorldCoor_instrument_set, doc=r"""instrument""") + ctype = property(_wcs.WorldCoor_ctype_get, _wcs.WorldCoor_ctype_set, doc=r"""ctype""") + c1type = property(_wcs.WorldCoor_c1type_get, _wcs.WorldCoor_c1type_set, doc=r"""c1type""") + c2type = property(_wcs.WorldCoor_c2type_get, _wcs.WorldCoor_c2type_set, doc=r"""c2type""") + ptype = property(_wcs.WorldCoor_ptype_get, _wcs.WorldCoor_ptype_set, doc=r"""ptype""") + units = property(_wcs.WorldCoor_units_get, _wcs.WorldCoor_units_set, doc=r"""units""") + radecsys = property(_wcs.WorldCoor_radecsys_get, _wcs.WorldCoor_radecsys_set, doc=r"""radecsys""") + radecout = property(_wcs.WorldCoor_radecout_get, _wcs.WorldCoor_radecout_set, doc=r"""radecout""") + radecin = property(_wcs.WorldCoor_radecin_get, _wcs.WorldCoor_radecin_set, doc=r"""radecin""") + eqin = property(_wcs.WorldCoor_eqin_get, _wcs.WorldCoor_eqin_set, doc=r"""eqin""") + eqout = property(_wcs.WorldCoor_eqout_get, _wcs.WorldCoor_eqout_set, doc=r"""eqout""") + sysin = property(_wcs.WorldCoor_sysin_get, _wcs.WorldCoor_sysin_set, doc=r"""sysin""") + syswcs = property(_wcs.WorldCoor_syswcs_get, _wcs.WorldCoor_syswcs_set, doc=r"""syswcs""") + sysout = property(_wcs.WorldCoor_sysout_get, _wcs.WorldCoor_sysout_set, doc=r"""sysout""") + center = property(_wcs.WorldCoor_center_get, _wcs.WorldCoor_center_set, doc=r"""center""") + wcsl = property(_wcs.WorldCoor_wcsl_get, _wcs.WorldCoor_wcsl_set, doc=r"""wcsl""") + lin = property(_wcs.WorldCoor_lin_get, _wcs.WorldCoor_lin_set, doc=r"""lin""") + cel = property(_wcs.WorldCoor_cel_get, _wcs.WorldCoor_cel_set, doc=r"""cel""") + prj = property(_wcs.WorldCoor_prj_get, _wcs.WorldCoor_prj_set, doc=r"""prj""") + lngcor = property(_wcs.WorldCoor_lngcor_get, _wcs.WorldCoor_lngcor_set, doc=r"""lngcor""") + latcor = property(_wcs.WorldCoor_latcor_get, _wcs.WorldCoor_latcor_set, doc=r"""latcor""") + distcode = property(_wcs.WorldCoor_distcode_get, _wcs.WorldCoor_distcode_set, doc=r"""distcode""") + distort = property(_wcs.WorldCoor_distort_get, _wcs.WorldCoor_distort_set, doc=r"""distort""") + command_format = property(_wcs.WorldCoor_command_format_get, _wcs.WorldCoor_command_format_set, doc=r"""command_format""") + ltm = property(_wcs.WorldCoor_ltm_get, _wcs.WorldCoor_ltm_set, doc=r"""ltm""") + ltv = property(_wcs.WorldCoor_ltv_get, _wcs.WorldCoor_ltv_set, doc=r"""ltv""") + idpix = property(_wcs.WorldCoor_idpix_get, _wcs.WorldCoor_idpix_set, doc=r"""idpix""") + ndpix = property(_wcs.WorldCoor_ndpix_get, _wcs.WorldCoor_ndpix_set, doc=r"""ndpix""") + wcs = property(_wcs.WorldCoor_wcs_get, _wcs.WorldCoor_wcs_set, doc=r"""wcs""") + wcsdep = property(_wcs.WorldCoor_wcsdep_get, _wcs.WorldCoor_wcsdep_set, doc=r"""wcsdep""") + wcsname = property(_wcs.WorldCoor_wcsname_get, _wcs.WorldCoor_wcsname_set, doc=r"""wcsname""") + wcschar = property(_wcs.WorldCoor_wcschar_get, _wcs.WorldCoor_wcschar_set, doc=r"""wcschar""") + logwcs = property(_wcs.WorldCoor_logwcs_get, _wcs.WorldCoor_logwcs_set, doc=r"""logwcs""") + + def __init__(self): + r"""__init__(self) -> WorldCoor""" + _wcs.WorldCoor_swiginit(self, _wcs.new_WorldCoor()) __swig_destroy__ = _wcs.delete_WorldCoor - __del__ = lambda self : None; -WorldCoor_swigregister = _wcs.WorldCoor_swigregister -WorldCoor_swigregister(WorldCoor) - -# This file is compatible with both classic and new-style classes. +# Register WorldCoor in _wcs: +_wcs.WorldCoor_swigregister(WorldCoor) diff --git a/PyWCSTools/wcscon.py b/PyWCSTools/wcscon.py index a82f4b7..0cc43da 100644 --- a/PyWCSTools/wcscon.py +++ b/PyWCSTools/wcscon.py @@ -1,80 +1,69 @@ -# This file was automatically generated by SWIG (http://www.swig.org). -# Version 2.0.7 +# This file was automatically generated by SWIG (https://www.swig.org). +# Version 4.2.1 # -# Do not make changes to this file unless you know what you are doing--modify +# Do not make changes to this file unless you know what you are doing - modify # the SWIG interface file instead. - - -from sys import version_info -if version_info >= (2,6,0): - def swig_import_helper(): - from os.path import dirname - import imp - fp = None - try: - fp, pathname, description = imp.find_module('_wcscon', [dirname(__file__)]) - except ImportError: - import _wcscon - return _wcscon - if fp is not None: - try: - _mod = imp.load_module('_wcscon', fp, pathname, description) - finally: - fp.close() - return _mod - _wcscon = swig_import_helper() - del swig_import_helper +from sys import version_info as _swig_python_version_info +# Import the low-level C/C++ module +if __package__ or "." in __name__: + from . import _wcscon else: import _wcscon -del version_info + try: - _swig_property = property -except NameError: - pass # Python < 2.2 doesn't have 'property'. -def _swig_setattr_nondynamic(self,class_type,name,value,static=1): - if (name == "thisown"): return self.this.own(value) - if (name == "this"): - if type(value).__name__ == 'SwigPyObject': - self.__dict__[name] = value - return - method = class_type.__swig_setmethods__.get(name,None) - if method: return method(self,value) - if (not static): - self.__dict__[name] = value - else: - raise AttributeError("You cannot add attributes to %s" % self) - -def _swig_setattr(self,class_type,name,value): - return _swig_setattr_nondynamic(self,class_type,name,value,0) - -def _swig_getattr(self,class_type,name): - if (name == "thisown"): return self.this.own() - method = class_type.__swig_getmethods__.get(name,None) - if method: return method(self) - raise AttributeError(name) + import builtins as __builtin__ +except ImportError: + import __builtin__ def _swig_repr(self): - try: strthis = "proxy of " + self.this.__repr__() - except: strthis = "" + try: + strthis = "proxy of " + self.this.__repr__() + except __builtin__.Exception: + strthis = "" return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,) -try: - _object = object - _newclass = 1 -except AttributeError: - class _object : pass - _newclass = 0 +def _swig_setattr_nondynamic_instance_variable(set): + def set_instance_attr(self, name, value): + if name == "this": + set(self, name, value) + elif name == "thisown": + self.this.own(value) + elif hasattr(self, name) and isinstance(getattr(type(self), name), property): + set(self, name, value) + else: + raise AttributeError("You cannot add instance attributes to %s" % self) + return set_instance_attr + + +def _swig_setattr_nondynamic_class_variable(set): + def set_class_attr(cls, name, value): + if hasattr(cls, name) and not isinstance(getattr(cls, name), property): + set(cls, name, value) + else: + raise AttributeError("You cannot add class attributes to %s" % cls) + return set_class_attr + + +def _swig_add_metaclass(metaclass): + """Class decorator for adding a metaclass to a SWIG wrapped class - a slimmed down version of six.add_metaclass""" + def wrapper(cls): + return metaclass(cls.__name__, cls.__bases__, cls.__dict__.copy()) + return wrapper + + +class _SwigNonDynamicMeta(type): + """Meta class to enforce nondynamic attributes (no new attributes) for a class""" + __setattr__ = _swig_setattr_nondynamic_class_variable(type.__setattr__) -def wcscon(*args): - """wcscon(sys1, sys2, eq1, eq2, INOUT, INOUT, epoch)""" - return _wcscon.wcscon(*args) -def wcscsys(*args): - """wcscsys(wcstring) -> int""" - return _wcscon.wcscsys(*args) -# This file is compatible with both classic and new-style classes. +def wcscon(sys1, sys2, eq1, eq2, arg5, arg6, epoch): + r"""wcscon(sys1, sys2, eq1, eq2, arg5, arg6, epoch)""" + return _wcscon.wcscon(sys1, sys2, eq1, eq2, arg5, arg6, epoch) +def wcscsys(wcstring): + r"""wcscsys(wcstring) -> int""" + return _wcscon.wcscsys(wcstring) diff --git a/PyWCSTools/wcssubs-3.9.5/COPYING b/PyWCSTools/wcssubs-3.9.5/COPYING deleted file mode 100644 index 6320024..0000000 --- a/PyWCSTools/wcssubs-3.9.5/COPYING +++ /dev/null @@ -1,460 +0,0 @@ - - GNU LESSER GENERAL PUBLIC LICENSE - Version 2.1, February 1999 - - Copyright (C) 1991, 1999 Free Software Foundation, Inc. - 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - -[This is the first released version of the Lesser GPL. It also counts - as the successor of the GNU Library Public License, version 2, hence - the version number 2.1.] - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -Licenses are intended to guarantee your freedom to share and change -free software--to make sure the software is free for all its users. - - This license, the Lesser General Public License, applies to some -specially designated software packages--typically libraries--of the -Free Software Foundation and other authors who decide to use it. You -can use it too, but we suggest you first think carefully about whether -this license or the ordinary General Public License is the better -strategy to use in any particular case, based on the explanations below. - - When we speak of free software, we are referring to freedom of use, -not price. Our General Public Licenses are designed to make sure that -you have the freedom to distribute copies of free software (and charge -for this service if you wish); that you receive source code or can get -it if you want it; that you can change the software and use pieces of -it in new free programs; and that you are informed that you can do -these things. - - To protect your rights, we need to make restrictions that forbid -distributors to deny you these rights or to ask you to surrender these -rights. These restrictions translate to certain responsibilities for -you if you distribute copies of the library or if you modify it. - - For example, if you distribute copies of the library, whether gratis -or for a fee, you must give the recipients all the rights that we gave -you. You must make sure that they, too, receive or can get the source -code. If you link other code with the library, you must provide -complete object files to the recipients, so that they can relink them -with the library after making changes to the library and recompiling -it. And you must show them these terms so they know their rights. - - We protect your rights with a two-step method: (1) we copyright the -library, and (2) we offer you this license, which gives you legal -permission to copy, distribute and/or modify the library. - - To protect each distributor, we want to make it very clear that -there is no warranty for the free library. Also, if the library is -modified by someone else and passed on, the recipients should know -that what they have is not the original version, so that the original -author's reputation will not be affected by problems that might be -introduced by others. - - Finally, software patents pose a constant threat to the existence of -any free program. We wish to make sure that a company cannot -effectively restrict the users of a free program by obtaining a -restrictive license from a patent holder. Therefore, we insist that -any patent license obtained for a version of the library must be -consistent with the full freedom of use specified in this license. - - Most GNU software, including some libraries, is covered by the -ordinary GNU General Public License. This license, the GNU Lesser -General Public License, applies to certain designated libraries, and -is quite different from the ordinary General Public License. We use -this license for certain libraries in order to permit linking those -libraries into non-free programs. - - When a program is linked with a library, whether statically or using -a shared library, the combination of the two is legally speaking a -combined work, a derivative of the original library. The ordinary -General Public License therefore permits such linking only if the -entire combination fits its criteria of freedom. The Lesser General -Public License permits more lax criteria for linking other code with -the library. - - We call this license the "Lesser" General Public License because it -does Less to protect the user's freedom than the ordinary General -Public License. It also provides other free software developers Less -of an advantage over competing non-free programs. These disadvantages -are the reason we use the ordinary General Public License for many -libraries. However, the Lesser license provides advantages in certain -special circumstances. - - For example, on rare occasions, there may be a special need to -encourage the widest possible use of a certain library, so that it becomes -a de-facto standard. To achieve this, non-free programs must be -allowed to use the library. A more frequent case is that a free -library does the same job as widely used non-free libraries. In this -case, there is little to gain by limiting the free library to free -software only, so we use the Lesser General Public License. - - In other cases, permission to use a particular library in non-free -programs enables a greater number of people to use a large body of -free software. For example, permission to use the GNU C Library in -non-free programs enables many more people to use the whole GNU -operating system, as well as its variant, the GNU/Linux operating -system. - - Although the Lesser General Public License is Less protective of the -users' freedom, it does ensure that the user of a program that is -linked with the Library has the freedom and the wherewithal to run -that program using a modified version of the Library. - - The precise terms and conditions for copying, distribution and -modification follow. Pay close attention to the difference between a -"work based on the library" and a "work that uses the library". The -former contains code derived from the library, whereas the latter must -be combined with the library in order to run. - - GNU LESSER GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License Agreement applies to any software library or other -program which contains a notice placed by the copyright holder or -other authorized party saying it may be distributed under the terms of -this Lesser General Public License (also called "this License"). -Each licensee is addressed as "you". - - A "library" means a collection of software functions and/or data -prepared so as to be conveniently linked with application programs -(which use some of those functions and data) to form executables. - - The "Library", below, refers to any such software library or work -which has been distributed under these terms. A "work based on the -Library" means either the Library or any derivative work under -copyright law: that is to say, a work containing the Library or a -portion of it, either verbatim or with modifications and/or translated -straightforwardly into another language. (Hereinafter, translation is -included without limitation in the term "modification".) - - "Source code" for a work means the preferred form of the work for -making modifications to it. For a library, complete source code means -all the source code for all modules it contains, plus any associated -interface definition files, plus the scripts used to control compilation -and installation of the library. - - Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running a program using the Library is not restricted, and output from -such a program is covered only if its contents constitute a work based -on the Library (independent of the use of the Library in a tool for -writing it). Whether that is true depends on what the Library does -and what the program that uses the Library does. - - 1. You may copy and distribute verbatim copies of the Library's -complete source code as you receive it, in any medium, provided that -you conspicuously and appropriately publish on each copy an -appropriate copyright notice and disclaimer of warranty; keep intact -all the notices that refer to this License and to the absence of any -warranty; and distribute a copy of this License along with the -Library. - - You may charge a fee for the physical act of transferring a copy, -and you may at your option offer warranty protection in exchange for a -fee. - - 2. You may modify your copy or copies of the Library or any portion -of it, thus forming a work based on the Library, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) The modified work must itself be a software library. - - b) You must cause the files modified to carry prominent notices - stating that you changed the files and the date of any change. - - c) You must cause the whole of the work to be licensed at no - charge to all third parties under the terms of this License. - - d) If a facility in the modified Library refers to a function or a - table of data to be supplied by an application program that uses - the facility, other than as an argument passed when the facility - is invoked, then you must make a good faith effort to ensure that, - in the event an application does not supply such function or - table, the facility still operates, and performs whatever part of - its purpose remains meaningful. - - (For example, a function in a library to compute square roots has - a purpose that is entirely well-defined independent of the - application. Therefore, Subsection 2d requires that any - application-supplied function or table used by this function must - be optional: if the application does not supply it, the square - root function must still compute square roots.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Library, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Library, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote -it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Library. - -In addition, mere aggregation of another work not based on the Library -with the Library (or with a work based on the Library) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may opt to apply the terms of the ordinary GNU General Public -License instead of this License to a given copy of the Library. To do -this, you must alter all the notices that refer to this License, so -that they refer to the ordinary GNU General Public License, version 2, -instead of to this License. (If a newer version than version 2 of the -ordinary GNU General Public License has appeared, then you can specify -that version instead if you wish.) Do not make any other change in -these notices. - - Once this change is made in a given copy, it is irreversible for -that copy, so the ordinary GNU General Public License applies to all -subsequent copies and derivative works made from that copy. - - This option is useful when you wish to copy part of the code of -the Library into a program that is not a library. - - 4. You may copy and distribute the Library (or a portion or -derivative of it, under Section 2) in object code or executable form -under the terms of Sections 1 and 2 above provided that you accompany -it with the complete corresponding machine-readable source code, which -must be distributed under the terms of Sections 1 and 2 above on a -medium customarily used for software interchange. - - If distribution of object code is made by offering access to copy -from a designated place, then offering equivalent access to copy the -source code from the same place satisfies the requirement to -distribute the source code, even though third parties are not -compelled to copy the source along with the object code. - - 5. A program that contains no derivative of any portion of the -Library, but is designed to work with the Library by being compiled or -linked with it, is called a "work that uses the Library". Such a -work, in isolation, is not a derivative work of the Library, and -therefore falls outside the scope of this License. - - However, linking a "work that uses the Library" with the Library -creates an executable that is a derivative of the Library (because it -contains portions of the Library), rather than a "work that uses the -library". The executable is therefore covered by this License. -Section 6 states terms for distribution of such executables. - - When a "work that uses the Library" uses material from a header file -that is part of the Library, the object code for the work may be a -derivative work of the Library even though the source code is not. -Whether this is true is especially significant if the work can be -linked without the Library, or if the work is itself a library. The -threshold for this to be true is not precisely defined by law. - - If such an object file uses only numerical parameters, data -structure layouts and accessors, and small macros and small inline -functions (ten lines or less in length), then the use of the object -file is unrestricted, regardless of whether it is legally a derivative -work. (Executables containing this object code plus portions of the -Library will still fall under Section 6.) - - Otherwise, if the work is a derivative of the Library, you may -distribute the object code for the work under the terms of Section 6. -Any executables containing that work also fall under Section 6, -whether or not they are linked directly with the Library itself. - - 6. As an exception to the Sections above, you may also combine or -link a "work that uses the Library" with the Library to produce a -work containing portions of the Library, and distribute that work -under terms of your choice, provided that the terms permit -modification of the work for the customer's own use and reverse -engineering for debugging such modifications. - - You must give prominent notice with each copy of the work that the -Library is used in it and that the Library and its use are covered by -this License. You must supply a copy of this License. If the work -during execution displays copyright notices, you must include the -copyright notice for the Library among them, as well as a reference -directing the user to the copy of this License. Also, you must do one -of these things: - - a) Accompany the work with the complete corresponding - machine-readable source code for the Library including whatever - changes were used in the work (which must be distributed under - Sections 1 and 2 above); and, if the work is an executable linked - with the Library, with the complete machine-readable "work that - uses the Library", as object code and/or source code, so that the - user can modify the Library and then relink to produce a modified - executable containing the modified Library. (It is understood - that the user who changes the contents of definitions files in the - Library will not necessarily be able to recompile the application - to use the modified definitions.) - - b) Use a suitable shared library mechanism for linking with the - Library. A suitable mechanism is one that (1) uses at run time a - copy of the library already present on the user's computer system, - rather than copying library functions into the executable, and (2) - will operate properly with a modified version of the library, if - the user installs one, as long as the modified version is - interface-compatible with the version that the work was made with. - - c) Accompany the work with a written offer, valid for at - least three years, to give the same user the materials - specified in Subsection 6a, above, for a charge no more - than the cost of performing this distribution. - - d) If distribution of the work is made by offering access to copy - from a designated place, offer equivalent access to copy the above - specified materials from the same place. - - e) Verify that the user has already received a copy of these - materials or that you have already sent this user a copy. - - For an executable, the required form of the "work that uses the -Library" must include any data and utility programs needed for -reproducing the executable from it. However, as a special exception, -the materials to be distributed need not include anything that is -normally distributed (in either source or binary form) with the major -components (compiler, kernel, and so on) of the operating system on -which the executable runs, unless that component itself accompanies -the executable. - - It may happen that this requirement contradicts the license -restrictions of other proprietary libraries that do not normally -accompany the operating system. Such a contradiction means you cannot -use both them and the Library together in an executable that you -distribute. - - 7. You may place library facilities that are a work based on the -Library side-by-side in a single library together with other library -facilities not covered by this License, and distribute such a combined -library, provided that the separate distribution of the work based on -the Library and of the other library facilities is otherwise -permitted, and provided that you do these two things: - - a) Accompany the combined library with a copy of the same work - based on the Library, uncombined with any other library - facilities. This must be distributed under the terms of the - Sections above. - - b) Give prominent notice with the combined library of the fact - that part of it is a work based on the Library, and explaining - where to find the accompanying uncombined form of the same work. - - 8. You may not copy, modify, sublicense, link with, or distribute -the Library except as expressly provided under this License. Any -attempt otherwise to copy, modify, sublicense, link with, or -distribute the Library is void, and will automatically terminate your -rights under this License. However, parties who have received copies, -or rights, from you under this License will not have their licenses -terminated so long as such parties remain in full compliance. - - 9. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Library or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Library (or any work based on the -Library), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Library or works based on it. - - 10. Each time you redistribute the Library (or any work based on the -Library), the recipient automatically receives a license from the -original licensor to copy, distribute, link with or modify the Library -subject to these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties with -this License. - - 11. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Library at all. For example, if a patent -license would not permit royalty-free redistribution of the Library by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Library. - -If any portion of this section is held invalid or unenforceable under any -particular circumstance, the balance of the section is intended to apply, -and the section as a whole is intended to apply in other circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 12. If the distribution and/or use of the Library is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Library under this License may add -an explicit geographical distribution limitation excluding those countries, -so that distribution is permitted only in or among countries not thus -excluded. In such case, this License incorporates the limitation as if -written in the body of this License. - - 13. The Free Software Foundation may publish revised and/or new -versions of the Lesser General Public License from time to time. -Such new versions will be similar in spirit to the present version, -but may differ in detail to address new problems or concerns. - -Each version is given a distinguishing version number. If the Library -specifies a version number of this License which applies to it and -"any later version", you have the option of following the terms and -conditions either of that version or of any later version published by -the Free Software Foundation. If the Library does not specify a -license version number, you may choose any version ever published by -the Free Software Foundation. - - 14. If you wish to incorporate parts of the Library into other free -programs whose distribution conditions are incompatible with these, -write to the author to ask for permission. For software which is -copyrighted by the Free Software Foundation, write to the Free -Software Foundation; we sometimes make exceptions for this. Our -decision will be guided by the two goals of preserving the free status -of all derivatives of our free software and of promoting the sharing -and reuse of software generally. - - NO WARRANTY - - 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO -WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. -EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR -OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY -KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE -LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME -THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN -WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY -AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU -FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR -CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE -LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING -RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A -FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF -SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH -DAMAGES. - - END OF TERMS AND CONDITIONS - diff --git a/PyWCSTools/wcssubs-3.9.5/Makefile b/PyWCSTools/wcssubs-3.9.5/Makefile deleted file mode 100644 index 9caa507..0000000 --- a/PyWCSTools/wcssubs-3.9.5/Makefile +++ /dev/null @@ -1,36 +0,0 @@ -OBJS = wcsinit.o wcs.o wcscon.o fitsfile.o imhfile.o \ - hget.o hput.o iget.o imio.o worldpos.o platepos.o \ - tnxpos.o zpxpos.o dsspos.o poly.o \ - wcslib.o lin.o cel.o proj.o sph.o wcstrig.o dateutil.o distort.o - -libwcs.a: $(OBJS) - ar rv $@ $? - ranlib $@ - -cel.o: wcslib.h -distort.o: wcs.h fitshead.h wcslib.h -fitsfile.o: fitsfile.h fitshead.h -hget.o: fitshead.h -hput.o: fitshead.h -iget.o: fitshead.h -imhfile.o: fitsfile.h fitshead.h -imio.o: fitshead.h -lin.o: wcslib.h -platepos.o: wcs.h fitshead.h wcslib.h -poly.o: wcslib.h -proj.o: wcslib.h -sph.o: wcslib.h -tnxpos.o: wcs.h fitshead.h wcslib.h -zpxpos.o: wcs.h fitshead.h wcslib.h -wcs.o: wcs.h fitshead.h wcslib.h -wcsinit.o: wcs.h fitshead.h wcslib.h -wcscon.o: wcs.h fitshead.h wcslib.h -wcslib.o: wcslib.h -wcstrig.o: wcslib.h -worldpos.o: wcs.h fitshead.h wcslib.h -dateutil.o: fitsfile.h fitshead.h -fileutil.o: fitsfile.h - -clean: - rm -f *.a *.o - diff --git a/PyWCSTools/wcssubs-3.9.5/Readme b/PyWCSTools/wcssubs-3.9.5/Readme deleted file mode 100644 index dad8e52..0000000 --- a/PyWCSTools/wcssubs-3.9.5/Readme +++ /dev/null @@ -1,36 +0,0 @@ -WCSsubs Subroutines - -These subroutines, developed as part of the WCSTools software package, -constitute a self-contained package for accessing the world coordinate -systems of FITS or IRAF(.imh) images, with image header I/O contained -in fitsfile.c and imhfile.c, and WCS initialization and use through the -subroutines in wcs.c. WCS information for an image is kept in a single -data structure defined in wcs.h. Pixel to WCS translations are done by -calls to pix2wcst() or pix2wcs(). WCS to pixel translations are done -by calls to wcs2pix() or wcsc2pix(). The contents of the files are -briefly described in Files. Dependencies between these files are given -in Makefile. Documentation, to some extent, is online at - -http://tdc-www.harvard.edu/software/wcstools/libwcs.wcs.html - -Documentation for the entire open-source WCSTools package is online at - -http://tdc-www.harvard.edu/software/wcstools/ - -Projection code in wcspos.c is by Bill Cotton of NRAO and is -protected by the Gnu Lesser General Public License, which is stated -in the file COPYING. Projection code in wcslib.c, -cel.c, lin.c, proj.c, wcstrig.c, and sph.c is by Mark Calabretta -of CSIRO and is also protected by the Gnu Lesser General Public -License. Code in slasubs.c is by Pat Wallace of the Starlink -project at Cambridge University. Jessica Mink is responsible for -the rest of the code, unless otherwise noted in the source file. -Unless otherwise noted, this code is Copyright 2017 by the -Smithsonian Astrophysical Observatory and protected by the Gnu -Lesser General Public License. - --Jessica Mink (jmink@cfa.harvard.edu) - Telescope Data Center - Harvard-Smithsonian Center for Astrophysics - Cambridge, Massachusetts - http://tdc-www.harvard.edu/mink diff --git a/PyWCSTools/wcssubs-3.9.5/fileutil.c b/PyWCSTools/wcssubs-3.9.5/fileutil.c deleted file mode 100644 index cf52903..0000000 --- a/PyWCSTools/wcssubs-3.9.5/fileutil.c +++ /dev/null @@ -1,867 +0,0 @@ -/*** File libwcs/fileutil.c - *** August 28, 2014 - *** By Jessica Mink, jmink@cfa.harvard.edu - *** Harvard-Smithsonian Center for Astrophysics - *** Copyright (C) 1999-2014 - *** Smithsonian Astrophysical Observatory, Cambridge, MA, USA - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Correspondence concerning WCSTools should be addressed as follows: - Internet email: jmink@cfa.harvard.edu - Postal address: Jessica Mink - Smithsonian Astrophysical Observatory - 60 Garden St. - Cambridge, MA 02138 USA - - * Module: fileutil.c (ASCII file utilities) - * Purpose: Find out things about ASCII files - * Subroutine: getfilelines (filename) - * Return number of lines in an ASCII file - * Subroutine: getfilebuff (filename) - * Return entire file contents in a character string - * Subroutine: getfilesize (filename) - * Return size of a binary or ASCII file - * Subroutine: isimlist (filename) - * Return 1 if file is list of FITS or IRAF image files, else 0 - * Subroutine: isimlistd (filename, rootdir) - * Return 1 if file is list of FITS or IRAF image files, else 0 - * Subroutine: isfilelist (filename, rootdir) - * Return 1 if file is list of readable files, else 0 - * Subroutine: isfile (filename) - * Return 1 if file is a readable file, else 0 - * Subroutine: first_token (diskfile, ncmax, token) - * Return the first token from the next line of an ASCII file - * Subroutine: next_line (diskfile, ncmax, line) - * Read the next line of an ASCII file and return its length - * Subroutine: stc2s (spchar, string) - * Replace character in string with space - * Subroutine: sts2c (spchar, string) - * Replace spaces in string with character - * Subroutine: istiff (filename) - * Return 1 if file is a readable TIFF graphics file, else 0 - * Subroutine: isjpeg (filename) - * Return 1 if file is a readable JPEG graphics file, else 0 - * int setoken (tokens, string, cwhite) - * Tokenize a string for easy decoding - * int nextoken (tokens, token, maxchars) - * Get next token from tokenized string - * int getoken (tokens, itok, token, maxchars) - * Get specified token from tokenized string - */ - -#include -#ifndef VMS -#include -#endif -#include -#include -#include -#include -#include -#include "fitsfile.h" -#include -#include - - -/* GETFILELINES -- return number of lines in one file */ - -int -getfilelines (filename) - -char *filename; /* Name of file for which to find number of lines */ -{ - - char *buffer, *bufline; - int nlines = 0; - char newline = 10; - - /* Read file */ - buffer = getfilebuff (filename); - - /* Count lines in file */ - if (buffer != NULL) { - bufline = buffer; - nlines = 0; - while ((bufline = strchr (bufline, newline)) != NULL) { - bufline = bufline + 1; - nlines++; - } - free (buffer); - return (nlines); - } - else { - return (0); - } -} - - -/* GETFILEBUFF -- return entire file contents in one character string */ - -char * -getfilebuff (filename) - -char *filename; /* Name of file for which to find number of lines */ -{ - - FILE *diskfile; - int lfile, nr, lbuff, ipt, ibuff; - char *buffer, *newbuff, *nextbuff; - - /* Treat stdin differently */ - if (!strcmp (filename, "stdin")) { - lbuff = 5000; - lfile = lbuff; - buffer = NULL; - ipt = 0; - for (ibuff = 0; ibuff < 10; ibuff++) { - if ((newbuff = realloc (buffer, lfile+1)) != NULL) { - buffer = newbuff; - nextbuff = buffer + ipt; - nr = fread (nextbuff, 1, lbuff, stdin); - if (nr == lbuff) - break; - else { - ipt = ipt + lbuff; - lfile = lfile + lbuff; - } - } - else { - fprintf (stderr,"GETFILEBUFF: No room for %d-byte buffer\n", - lfile); - break; - } - } - return (buffer); - } - - /* Open file */ - if ((diskfile = fopen (filename, "rb")) == NULL) - return (NULL); - - /* Find length of file */ - if (fseek (diskfile, 0, 2) == 0) - lfile = ftell (diskfile); - else - lfile = 0; - if (lfile < 1) { - fprintf (stderr,"GETFILEBUFF: File %s is empty\n", filename); - fclose (diskfile); - return (NULL); - } - - /* Allocate buffer to hold entire file and read it */ - if ((buffer = calloc (1, lfile+1)) != NULL) { - fseek (diskfile, 0, 0); - nr = fread (buffer, 1, lfile, diskfile); - if (nr < lfile) { - fprintf (stderr,"GETFILEBUFF: File %s: read %d / %d bytes\n", - filename, nr, lfile); - free (buffer); - fclose (diskfile); - return (NULL); - } - buffer[lfile] = (char) 0; - fclose (diskfile); - return (buffer); - } - else { - fprintf (stderr,"GETFILEBUFF: File %s: no room for %d-byte buffer\n", - filename, lfile); - fclose (diskfile); - return (NULL); - } -} - - -/* GETFILESIZE -- return size of one file in bytes */ - -int -getfilesize (filename) - -char *filename; /* Name of file for which to find size */ -{ - struct stat statbuff; - - if (stat (filename, &statbuff)) - return (0); - else - return ((int) statbuff.st_size); -} - -int -getfilesize0 (filename) - -char *filename; /* Name of file for which to find size */ -{ - FILE *diskfile; - long filesize; - - /* Open file */ - if ((diskfile = fopen (filename, "rb")) == NULL) - return (-1); - - /* Move to end of the file */ - if (fseek (diskfile, 0, 2) == 0) - - /* Position is the size of the file */ - filesize = ftell (diskfile); - - else - filesize = -1; - - fclose (diskfile); - - return ((int) filesize); -} - - -/* ISIMLIST -- Return 1 if list of FITS or IRAF files, else 0 */ -int -isimlist (filename) - -char *filename; /* Name of possible list file */ -{ - FILE *diskfile; - char token[256]; - int ncmax = 254; - - if ((diskfile = fopen (filename, "r")) == NULL) - return (0); - else { - first_token (diskfile, ncmax, token); - fclose (diskfile); - if (isfits (token) | isiraf (token)) - return (1); - else - return (0); - } -} - - -/* ISIMLISTD -- Return 1 if list of FITS or IRAF files, else 0 */ -int -isimlistd (filename, rootdir) - -char *filename; /* Name of possible list file */ -char *rootdir; /* Name of root directory for files in list */ -{ - FILE *diskfile; - char token[256]; - char filepath[256]; - int ncmax = 254; - - if ((diskfile = fopen (filename, "r")) == NULL) - return (0); - else { - first_token (diskfile, ncmax, token); - fclose (diskfile); - if (rootdir != NULL) { - strcpy (filepath, rootdir); - strcat (filepath, "/"); - strcat (filepath, token); - } - else - strcpy (filepath, token); - if (isfits (filepath) | isiraf (filepath)) - return (1); - else - return (0); - } -} - - -/* ISFILELIST -- Return 1 if list of readable files, else 0 */ -int -isfilelist (filename, rootdir) - -char *filename; /* Name of possible list file */ -char *rootdir; /* Name of root directory for files in list */ -{ - FILE *diskfile; - char token[256]; - char filepath[256]; - int ncmax = 254; - - if ((diskfile = fopen (filename, "r")) == NULL) - return (0); - else { - first_token (diskfile, ncmax, token); - fclose (diskfile); - if (rootdir != NULL) { - strcpy (filepath, rootdir); - strcat (filepath, "/"); - strcat (filepath, token); - } - else - strcpy (filepath, token); - if (isfile (filepath)) - return (1); - else - return (0); - } -} - - -/* ISFILE -- Return 1 if file is a readable file, else 0 */ - -int -isfile (filename) - -char *filename; /* Name of file to check */ -{ - struct stat statbuff; - - if (!strcasecmp (filename, "stdin")) - return (1); - else if (access (filename, R_OK)) - return (0); - else if (stat (filename, &statbuff)) - return (0); - else { - if (S_ISDIR(statbuff.st_mode) && S_IFDIR) - return (2); - else - return (1); - } -} - - -/* NEXT_LINE -- Read the next line of an ASCII file, returning length */ -/* Lines beginning with # are ignored*/ - -int -next_line (diskfile, ncmax, line) - -FILE *diskfile; /* File descriptor for ASCII file */ -int ncmax; /* Maximum number of characters returned */ -char *line; /* Next line (returned) */ -{ - char *lastchar; - - /* If line can be read, add null at the end of the first token */ - if (fgets (line, ncmax, diskfile) != NULL) { - while (line[0] == '#') { - (void) fgets (line, ncmax, diskfile); - } - - /* If only character is a control character, return a NULL string */ - if ((strlen(line)==1) && (line[0]<32)){ - line[0] = (char)0; - return (1); - } - lastchar = line + strlen (line) - 1; - - /* Remove trailing spaces or control characters */ - while (*lastchar <= 32) - *lastchar-- = 0; - - return (strlen (line)); - } - else - return (0); -} - - -/* FIRST_TOKEN -- Return first token from the next line of an ASCII file */ -/* Lines beginning with # are ignored */ - -int -first_token (diskfile, ncmax, token) - -FILE *diskfile; /* File descriptor for ASCII file */ -int ncmax; /* Maximum number of characters returned */ -char *token; /* First token on next line (returned) */ -{ - char *lastchar, *lspace; - - /* If line can be read, add null at the end of the first token */ - if (fgets (token, ncmax, diskfile) != NULL) { - while (token[0] == '#') { - (void) fgets (token, ncmax, diskfile); - } - - /* If only character is a control character, return a NULL */ - if ((strlen(token)==1) && (token[0]<32)){ - token[0]=0; - return (1); - } - lastchar = token + strlen (token) - 1; - - /* Remove trailing spaces or control characters */ - while (*lastchar <= 32) - *lastchar-- = 0; - - if ((lspace = strchr (token, ' ')) != NULL) { - *lspace = (char) 0; - } - return (1); - } - else - return (0); -} - - -/* Replace character in string with space */ - -int -stc2s (spchar, string) - -char *spchar; /* Character to replace with spaces */ -char *string; -{ - int i, lstr, n; - lstr = strlen (string); - n = 0; - for (i = 0; i < lstr; i++) { - if (string[i] == spchar[0]) { - n++; - string[i] = ' '; - } - } - return (n); -} - - -/* Replace spaces in string with character */ - -int -sts2c (spchar, string) - -char *spchar; /* Character with which to replace spaces */ -char *string; -{ - int i, lstr, n; - lstr = strlen (string); - n = 0; - for (i = 0; i < lstr; i++) { - if (string[i] == ' ') { - n++; - string[i] = spchar[0]; - } - } - return (n); -} - - -/* ISTIFF -- Return 1 if TIFF file, else 0 */ -int -istiff (filename) - -char *filename; /* Name of file to check */ -{ - int diskfile; - char keyword[16]; - int nbr; - - /* First check to see if this is an assignment */ - if (strchr (filename, '=')) - return (0); - - /* Check file extension */ - if (strsrch (filename, ".tif") || - strsrch (filename, ".tiff") || - strsrch (filename, ".TIFF") || - strsrch (filename, ".TIF")) - return (1); - - /* If no TIFF file suffix, try opening the file */ - else { - if ((diskfile = open (filename, O_RDONLY)) < 0) - return (0); - else { - nbr = read (diskfile, keyword, 4); - close (diskfile); - if (nbr < 4) - return (0); - else if (!strncmp (keyword, "II", 2)) - return (1); - else if (!strncmp (keyword, "MM", 2)) - return (1); - else - return (0); - } - } -} - - -/* ISJPEG -- Return 1 if JPEG file, else 0 */ -int -isjpeg (filename) - -char *filename; /* Name of file to check */ -{ - int diskfile; - char keyword[16]; - int nbr; - - /* First check to see if this is an assignment */ - if (strchr (filename, '=')) - return (0); - - /* Check file extension */ - if (strsrch (filename, ".jpg") || - strsrch (filename, ".jpeg") || - strsrch (filename, ".JPEG") || - strsrch (filename, ".jfif") || - strsrch (filename, ".jfi") || - strsrch (filename, ".JFIF") || - strsrch (filename, ".JFI") || - strsrch (filename, ".JPG")) - return (1); - - /* If no JPEG file suffix, try opening the file */ - else { - if ((diskfile = open (filename, O_RDONLY)) < 0) - return (0); - else { - nbr = read (diskfile, keyword, 2); - close (diskfile); - if (nbr < 4) - return (0); - else if (keyword[0] == (char) 0xFF && - keyword[1] == (char) 0xD8) - return (1); - else - return (0); - } - } -} - - -/* ISGIF -- Return 1 if GIF file, else 0 */ -int -isgif (filename) - -char *filename; /* Name of file to check */ -{ - int diskfile; - char keyword[16]; - int nbr; - - /* First check to see if this is an assignment */ - if (strchr (filename, '=')) - return (0); - - /* Check file extension */ - if (strsrch (filename, ".gif") || - strsrch (filename, ".GIF")) - return (1); - - /* If no GIF file suffix, try opening the file */ - else { - if ((diskfile = open (filename, O_RDONLY)) < 0) - return (0); - else { - nbr = read (diskfile, keyword, 6); - close (diskfile); - if (nbr < 4) - return (0); - else if (!strncmp (keyword, "GIF", 3)) - return (1); - else - return (0); - } - } -} - - -static int maxtokens = MAXTOKENS; /* Set maximum number of tokens from wcscat.h*/ - -/* -- SETOKEN -- tokenize a string for easy decoding */ - -int -setoken (tokens, string, cwhite) - -struct Tokens *tokens; /* Token structure returned */ -char *string; /* character string to tokenize */ -char *cwhite; /* additional whitespace characters - * if = tab, disallow spaces and commas */ -{ - char squote, dquote, jch, newline; - char *iq, *stri, *wtype, *str0, *inew; - int i,j,naddw, ltok; - - newline = (char) 10; - squote = (char) 39; - dquote = (char) 34; - if (string == NULL) - return (0); - - /* Line is terminated by newline or NULL */ - inew = strchr (string, newline); - if (inew != NULL) - tokens->lline = inew - string - 1; - else - tokens->lline = strlen (string); - - /* Save current line in structure */ - tokens->line = string; - - /* Add extra whitespace characters */ - if (cwhite == NULL) - naddw = 0; - else - naddw = strlen (cwhite); - - /* if character is tab, allow only tabs and nulls as separators */ - if (naddw > 0 && !strncmp (cwhite, "tab", 3)) { - tokens->white[0] = (char) 9; /* Tab */ - tokens->white[1] = (char) 0; /* NULL (end of string) */ - tokens->nwhite = 2; - } - - /* if character is bar, allow only bars and nulls as separators */ - else if (naddw > 0 && !strncmp (cwhite, "bar", 3)) { - tokens->white[0] = '|'; /* Bar */ - tokens->white[1] = (char) 0; /* NULL (end of string) */ - tokens->nwhite = 2; - } - - /* otherwise, allow spaces, tabs, commas, nulls, and cwhite */ - else { - tokens->nwhite = 4 + naddw;; - tokens->white[0] = ' '; /* Space */ - tokens->white[1] = (char) 9; /* Tab */ - tokens->white[2] = ','; /* Comma */ - tokens->white[3] = (char) 124; /* Vertical bar */ - tokens->white[4] = (char) 0; /* Null (end of string) */ - if (tokens->nwhite > 20) - tokens->nwhite = 20; - if (naddw > 0) { - i = 0; - for (j = 4; j < tokens->nwhite; j++) { - tokens->white[j] = cwhite[i]; - i++; - } - } - } - tokens->white[tokens->nwhite] = (char) 0; - - tokens->ntok = 0; - tokens->itok = 0; - iq = string - 1; - for (i = 0; i < maxtokens; i++) { - tokens->tok1[i] = NULL; - tokens->ltok[i] = 0; - } - - /* Process string one character at a time */ - stri = string; - str0 = string; - while (stri < string+tokens->lline) { - - /* Keep stuff between quotes in one token */ - if (stri <= iq) - continue; - jch = *stri; - - /* Handle quoted strings */ - if (jch == squote) - iq = strchr (stri+1, squote); - else if (jch == dquote) - iq = strchr (stri+1, dquote); - else - iq = stri; - if (iq > stri) { - tokens->ntok = tokens->ntok + 1; - if (tokens->ntok > maxtokens) return (maxtokens); - tokens->tok1[tokens->ntok] = stri + 1; - tokens->ltok[tokens->ntok] = (iq - stri) - 1; - stri = iq + 1; - str0 = iq + 1; - continue; - } - - /* Search for unquoted tokens */ - wtype = strchr (tokens->white, jch); - - /* If this is one of the additional whitespace characters, - * pass as a separate token */ - if (wtype > tokens->white + 3) { - - /* Terminate token before whitespace */ - if (stri > str0) { - tokens->ntok = tokens->ntok + 1; - if (tokens->ntok > maxtokens) return (maxtokens); - tokens->tok1[tokens->ntok] = str0; - tokens->ltok[tokens->ntok] = stri - str0; - } - - /* Make whitespace character next token; start new one */ - tokens->ntok = tokens->ntok + 1; - if (tokens->ntok > maxtokens) return (maxtokens); - tokens->tok1[tokens->ntok] = stri; - tokens->ltok[tokens->ntok] = 1; - stri++; - str0 = stri; - } - - /* Pass previous token if regular whitespace or NULL */ - else if (wtype != NULL || jch == (char) 0) { - - /* Ignore leading whitespace */ - if (stri == str0) { - stri++; - str0 = stri; - } - - /* terminate token before whitespace; start new one */ - else { - tokens->ntok = tokens->ntok + 1; - if (tokens->ntok > maxtokens) return (maxtokens); - tokens->tok1[tokens->ntok] = str0; - tokens->ltok[tokens->ntok] = stri - str0; - stri++; - str0 = stri; - } - } - - /* Keep going if not whitespace */ - else - stri++; - } - - /* Add token terminated by end of line */ - if (str0 < stri) { - tokens->ntok = tokens->ntok + 1; - if (tokens->ntok > maxtokens) - return (maxtokens); - tokens->tok1[tokens->ntok] = str0; - ltok = stri - str0 + 1; - tokens->ltok[tokens->ntok] = ltok; - - /* Deal with white space just before end of line */ - jch = str0[ltok-1]; - if (strchr (tokens->white, jch)) { - ltok = ltok - 1; - tokens->ltok[tokens->ntok] = ltok; - tokens->ntok = tokens->ntok + 1; - tokens->tok1[tokens->ntok] = str0 + ltok; - tokens->ltok[tokens->ntok] = 0; - } - } - - tokens->itok = 0; - - return (tokens->ntok); -} - - -/* NEXTOKEN -- get next token from tokenized string */ - -int -nextoken (tokens, token, maxchars) - -struct Tokens *tokens; /* Token structure returned */ -char *token; /* token (returned) */ -int maxchars; /* Maximum length of token */ -{ - int ltok; /* length of token string (returned) */ - int it, i; - int maxc = maxchars - 1; - - tokens->itok = tokens->itok + 1; - it = tokens->itok; - if (it > tokens->ntok) - it = tokens->ntok; - else if (it < 1) - it = 1; - ltok = tokens->ltok[it]; - if (ltok > maxc) - ltok = maxc; - strncpy (token, tokens->tok1[it], ltok); - for (i = ltok; i < maxc; i++) - token[i] = (char) 0; - return (ltok); -} - - -/* GETOKEN -- get specified token from tokenized string */ - -int -getoken (tokens, itok, token, maxchars) - -struct Tokens *tokens; /* Token structure returned */ -int itok; /* token sequence number of token - * if <0, get whole string after token -itok - * if =0, get whole string */ -char *token; /* token (returned) */ -int maxchars; /* Maximum length of token */ -{ - int ltok; /* length of token string (returned) */ - int it, i; - int maxc = maxchars - 1; - - it = itok; - if (it > 0 ) { - if (it > tokens->ntok) - it = tokens->ntok; - ltok = tokens->ltok[it]; - if (ltok > maxc) - ltok = maxc; - strncpy (token, tokens->tok1[it], ltok); - } - else if (it < 0) { - if (it < -tokens->ntok) - it = -tokens->ntok; - ltok = tokens->line + tokens->lline - tokens->tok1[-it]; - if (ltok > maxc) - ltok = maxc; - strncpy (token, tokens->tok1[-it], ltok); - } - else { - ltok = tokens->lline; - if (ltok > maxc) - ltok = maxc; - strncpy (token, tokens->tok1[1], ltok); - } - for (i = ltok; i < maxc; i++) - token[i] = (char) 0; - - return (ltok); -} - -/* - * Jul 14 1999 New subroutines - * Jul 15 1999 Add getfilebuff() - * Oct 15 1999 Fix format eror in error message - * Oct 21 1999 Fix declarations after lint - * Dec 9 1999 Add next_token(); set pointer to next token in first_token - * - * Sep 25 2001 Add isfilelist(); move isfile() from catutil.c - * - * Jan 4 2002 Allow getfilebuffer() to read from stdin - * Jan 8 2002 Add sts2c() and stc2s() for space-replaced strings - * Mar 22 2002 Clean up isfilelist() - * Aug 1 2002 Return 1 if file is stdin in isfile() - * - * Feb 4 2003 Open catalog file rb instead of r (Martin Ploner, Bern) - * Mar 5 2003 Add isimlistd() to check image lists with root directory - * May 27 2003 Use file stat call in getfilesize() instead of opening file - * Jul 17 2003 Add root directory argument to isfilelist() - * - * Sep 29 2004 Drop next_token() to avoid conflict with subroutine in catutil.c - * - * Sep 26 2005 In first_token, return NULL if token is only control character - * - * Feb 23 2006 Add istiff(), isjpeg(), isgif() to check TIFF, JPEG, GIF files - * Jun 20 2006 Cast call to fgets() void - * - * Jan 5 2007 Change stc2s() and sts2c() to pass single character as pointer - * Jan 11 2007 Move token access subroutines from catutil.c - * - * Aug 28 2014 Return length from next_line(): 0=unsuccessful - */ diff --git a/PyWCSTools/wcssubs-3.9.5/wcs.py b/PyWCSTools/wcssubs-3.9.5/wcs.py deleted file mode 100644 index 3cf9979..0000000 --- a/PyWCSTools/wcssubs-3.9.5/wcs.py +++ /dev/null @@ -1,255 +0,0 @@ -# This file was automatically generated by SWIG (http://www.swig.org). -# Version 4.0.2 -# -# Do not make changes to this file unless you know what you are doing--modify -# the SWIG interface file instead. - -from sys import version_info as _swig_python_version_info -if _swig_python_version_info < (2, 7, 0): - raise RuntimeError("Python 2.7 or later required") - -# Import the low-level C/C++ module -if __package__ or "." in __name__: - from . import _wcs -else: - import _wcs - -try: - import builtins as __builtin__ -except ImportError: - import __builtin__ - -def _swig_repr(self): - try: - strthis = "proxy of " + self.this.__repr__() - except __builtin__.Exception: - strthis = "" - return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,) - - -def _swig_setattr_nondynamic_instance_variable(set): - def set_instance_attr(self, name, value): - if name == "thisown": - self.this.own(value) - elif name == "this": - set(self, name, value) - elif hasattr(self, name) and isinstance(getattr(type(self), name), property): - set(self, name, value) - else: - raise AttributeError("You cannot add instance attributes to %s" % self) - return set_instance_attr - - -def _swig_setattr_nondynamic_class_variable(set): - def set_class_attr(cls, name, value): - if hasattr(cls, name) and not isinstance(getattr(cls, name), property): - set(cls, name, value) - else: - raise AttributeError("You cannot add class attributes to %s" % cls) - return set_class_attr - - -def _swig_add_metaclass(metaclass): - """Class decorator for adding a metaclass to a SWIG wrapped class - a slimmed down version of six.add_metaclass""" - def wrapper(cls): - return metaclass(cls.__name__, cls.__bases__, cls.__dict__.copy()) - return wrapper - - -class _SwigNonDynamicMeta(type): - """Meta class to enforce nondynamic attributes (no new attributes) for a class""" - __setattr__ = _swig_setattr_nondynamic_class_variable(type.__setattr__) - - - -def new_doubleArray(nelements): - r"""new_doubleArray(nelements) -> double *""" - return _wcs.new_doubleArray(nelements) - -def delete_doubleArray(ary): - r"""delete_doubleArray(ary)""" - return _wcs.delete_doubleArray(ary) - -def doubleArray_getitem(ary, index): - r"""doubleArray_getitem(ary, index) -> double""" - return _wcs.doubleArray_getitem(ary, index) - -def doubleArray_setitem(ary, index, value): - r"""doubleArray_setitem(ary, index, value)""" - return _wcs.doubleArray_setitem(ary, index, value) - -def wcsinit(hstring): - r"""wcsinit(hstring) -> WorldCoor""" - return _wcs.wcsinit(hstring) - -def wcsxinit(cra, cdec, secpix, xrpix, yrpix, nxpix, nypix, rotate, equinox, epoch, proj): - r"""wcsxinit(cra, cdec, secpix, xrpix, yrpix, nxpix, nypix, rotate, equinox, epoch, proj) -> WorldCoor""" - return _wcs.wcsxinit(cra, cdec, secpix, xrpix, yrpix, nxpix, nypix, rotate, equinox, epoch, proj) - -def wcskinit(nxpix, nypix, ctype1, ctype2, crpix1, crpix2, crval1, crval2, cd, cdelt1, cdelt2, crota, equinox, epoch): - r"""wcskinit(nxpix, nypix, ctype1, ctype2, crpix1, crpix2, crval1, crval2, cd, cdelt1, cdelt2, crota, equinox, epoch) -> WorldCoor""" - return _wcs.wcskinit(nxpix, nypix, ctype1, ctype2, crpix1, crpix2, crval1, crval2, cd, cdelt1, cdelt2, crota, equinox, epoch) - -def iswcs(wcs): - r"""iswcs(wcs) -> int""" - return _wcs.iswcs(wcs) - -def nowcs(wcs): - r"""nowcs(wcs) -> int""" - return _wcs.nowcs(wcs) - -def wcs2pix(wcs, xpos, ypos): - r"""wcs2pix(wcs, xpos, ypos)""" - return _wcs.wcs2pix(wcs, xpos, ypos) - -def pix2wcs(wcs, xpix, ypix): - r"""pix2wcs(wcs, xpix, ypix)""" - return _wcs.pix2wcs(wcs, xpix, ypix) - -def wcscent(wcs): - r"""wcscent(wcs)""" - return _wcs.wcscent(wcs) - -def getradecsys(wcs): - r"""getradecsys(wcs) -> char *""" - return _wcs.getradecsys(wcs) - -def wcsoutinit(wcs, coorsys): - r"""wcsoutinit(wcs, coorsys)""" - return _wcs.wcsoutinit(wcs, coorsys) - -def wcsininit(wcs, coorsys): - r"""wcsininit(wcs, coorsys)""" - return _wcs.wcsininit(wcs, coorsys) - -def getwcsout(wcs): - r"""getwcsout(wcs) -> char *""" - return _wcs.getwcsout(wcs) - -def getwcsin(wcs): - r"""getwcsin(wcs) -> char *""" - return _wcs.getwcsin(wcs) - -def wcssize(wcs): - r"""wcssize(wcs)""" - return _wcs.wcssize(wcs) - -def wcsfull(wcs): - r"""wcsfull(wcs)""" - return _wcs.wcsfull(wcs) -class WorldCoor(object): - r"""Proxy of C WorldCoor struct.""" - - thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag") - __repr__ = _swig_repr - xref = property(_wcs.WorldCoor_xref_get, _wcs.WorldCoor_xref_set, doc=r"""xref""") - yref = property(_wcs.WorldCoor_yref_get, _wcs.WorldCoor_yref_set, doc=r"""yref""") - xrefpix = property(_wcs.WorldCoor_xrefpix_get, _wcs.WorldCoor_xrefpix_set, doc=r"""xrefpix""") - yrefpix = property(_wcs.WorldCoor_yrefpix_get, _wcs.WorldCoor_yrefpix_set, doc=r"""yrefpix""") - xinc = property(_wcs.WorldCoor_xinc_get, _wcs.WorldCoor_xinc_set, doc=r"""xinc""") - yinc = property(_wcs.WorldCoor_yinc_get, _wcs.WorldCoor_yinc_set, doc=r"""yinc""") - rot = property(_wcs.WorldCoor_rot_get, _wcs.WorldCoor_rot_set, doc=r"""rot""") - cd = property(_wcs.WorldCoor_cd_get, _wcs.WorldCoor_cd_set, doc=r"""cd""") - dc = property(_wcs.WorldCoor_dc_get, _wcs.WorldCoor_dc_set, doc=r"""dc""") - equinox = property(_wcs.WorldCoor_equinox_get, _wcs.WorldCoor_equinox_set, doc=r"""equinox""") - epoch = property(_wcs.WorldCoor_epoch_get, _wcs.WorldCoor_epoch_set, doc=r"""epoch""") - nxpix = property(_wcs.WorldCoor_nxpix_get, _wcs.WorldCoor_nxpix_set, doc=r"""nxpix""") - nypix = property(_wcs.WorldCoor_nypix_get, _wcs.WorldCoor_nypix_set, doc=r"""nypix""") - plate_ra = property(_wcs.WorldCoor_plate_ra_get, _wcs.WorldCoor_plate_ra_set, doc=r"""plate_ra""") - plate_dec = property(_wcs.WorldCoor_plate_dec_get, _wcs.WorldCoor_plate_dec_set, doc=r"""plate_dec""") - plate_scale = property(_wcs.WorldCoor_plate_scale_get, _wcs.WorldCoor_plate_scale_set, doc=r"""plate_scale""") - x_pixel_offset = property(_wcs.WorldCoor_x_pixel_offset_get, _wcs.WorldCoor_x_pixel_offset_set, doc=r"""x_pixel_offset""") - y_pixel_offset = property(_wcs.WorldCoor_y_pixel_offset_get, _wcs.WorldCoor_y_pixel_offset_set, doc=r"""y_pixel_offset""") - x_pixel_size = property(_wcs.WorldCoor_x_pixel_size_get, _wcs.WorldCoor_x_pixel_size_set, doc=r"""x_pixel_size""") - y_pixel_size = property(_wcs.WorldCoor_y_pixel_size_get, _wcs.WorldCoor_y_pixel_size_set, doc=r"""y_pixel_size""") - ppo_coeff = property(_wcs.WorldCoor_ppo_coeff_get, _wcs.WorldCoor_ppo_coeff_set, doc=r"""ppo_coeff""") - x_coeff = property(_wcs.WorldCoor_x_coeff_get, _wcs.WorldCoor_x_coeff_set, doc=r"""x_coeff""") - y_coeff = property(_wcs.WorldCoor_y_coeff_get, _wcs.WorldCoor_y_coeff_set, doc=r"""y_coeff""") - xpix = property(_wcs.WorldCoor_xpix_get, _wcs.WorldCoor_xpix_set, doc=r"""xpix""") - ypix = property(_wcs.WorldCoor_ypix_get, _wcs.WorldCoor_ypix_set, doc=r"""ypix""") - zpix = property(_wcs.WorldCoor_zpix_get, _wcs.WorldCoor_zpix_set, doc=r"""zpix""") - xpos = property(_wcs.WorldCoor_xpos_get, _wcs.WorldCoor_xpos_set, doc=r"""xpos""") - ypos = property(_wcs.WorldCoor_ypos_get, _wcs.WorldCoor_ypos_set, doc=r"""ypos""") - crpix = property(_wcs.WorldCoor_crpix_get, _wcs.WorldCoor_crpix_set, doc=r"""crpix""") - crval = property(_wcs.WorldCoor_crval_get, _wcs.WorldCoor_crval_set, doc=r"""crval""") - cdelt = property(_wcs.WorldCoor_cdelt_get, _wcs.WorldCoor_cdelt_set, doc=r"""cdelt""") - pc = property(_wcs.WorldCoor_pc_get, _wcs.WorldCoor_pc_set, doc=r"""pc""") - projp = property(_wcs.WorldCoor_projp_get, _wcs.WorldCoor_projp_set, doc=r"""projp""") - pvfail = property(_wcs.WorldCoor_pvfail_get, _wcs.WorldCoor_pvfail_set, doc=r"""pvfail""") - projppv = property(_wcs.WorldCoor_projppv_get, _wcs.WorldCoor_projppv_set, doc=r"""projppv""") - inv_x = property(_wcs.WorldCoor_inv_x_get, _wcs.WorldCoor_inv_x_set, doc=r"""inv_x""") - inv_y = property(_wcs.WorldCoor_inv_y_get, _wcs.WorldCoor_inv_y_set, doc=r"""inv_y""") - longpole = property(_wcs.WorldCoor_longpole_get, _wcs.WorldCoor_longpole_set, doc=r"""longpole""") - latpole = property(_wcs.WorldCoor_latpole_get, _wcs.WorldCoor_latpole_set, doc=r"""latpole""") - rodeg = property(_wcs.WorldCoor_rodeg_get, _wcs.WorldCoor_rodeg_set, doc=r"""rodeg""") - imrot = property(_wcs.WorldCoor_imrot_get, _wcs.WorldCoor_imrot_set, doc=r"""imrot""") - pa_north = property(_wcs.WorldCoor_pa_north_get, _wcs.WorldCoor_pa_north_set, doc=r"""pa_north""") - pa_east = property(_wcs.WorldCoor_pa_east_get, _wcs.WorldCoor_pa_east_set, doc=r"""pa_east""") - radvel = property(_wcs.WorldCoor_radvel_get, _wcs.WorldCoor_radvel_set, doc=r"""radvel""") - zvel = property(_wcs.WorldCoor_zvel_get, _wcs.WorldCoor_zvel_set, doc=r"""zvel""") - zpzd = property(_wcs.WorldCoor_zpzd_get, _wcs.WorldCoor_zpzd_set, doc=r"""zpzd""") - zpr = property(_wcs.WorldCoor_zpr_get, _wcs.WorldCoor_zpr_set, doc=r"""zpr""") - imflip = property(_wcs.WorldCoor_imflip_get, _wcs.WorldCoor_imflip_set, doc=r"""imflip""") - prjcode = property(_wcs.WorldCoor_prjcode_get, _wcs.WorldCoor_prjcode_set, doc=r"""prjcode""") - latbase = property(_wcs.WorldCoor_latbase_get, _wcs.WorldCoor_latbase_set, doc=r"""latbase""") - ncoeff1 = property(_wcs.WorldCoor_ncoeff1_get, _wcs.WorldCoor_ncoeff1_set, doc=r"""ncoeff1""") - ncoeff2 = property(_wcs.WorldCoor_ncoeff2_get, _wcs.WorldCoor_ncoeff2_set, doc=r"""ncoeff2""") - zpnp = property(_wcs.WorldCoor_zpnp_get, _wcs.WorldCoor_zpnp_set, doc=r"""zpnp""") - changesys = property(_wcs.WorldCoor_changesys_get, _wcs.WorldCoor_changesys_set, doc=r"""changesys""") - printsys = property(_wcs.WorldCoor_printsys_get, _wcs.WorldCoor_printsys_set, doc=r"""printsys""") - ndec = property(_wcs.WorldCoor_ndec_get, _wcs.WorldCoor_ndec_set, doc=r"""ndec""") - degout = property(_wcs.WorldCoor_degout_get, _wcs.WorldCoor_degout_set, doc=r"""degout""") - tabsys = property(_wcs.WorldCoor_tabsys_get, _wcs.WorldCoor_tabsys_set, doc=r"""tabsys""") - rotmat = property(_wcs.WorldCoor_rotmat_get, _wcs.WorldCoor_rotmat_set, doc=r"""rotmat""") - coorflip = property(_wcs.WorldCoor_coorflip_get, _wcs.WorldCoor_coorflip_set, doc=r"""coorflip""") - offscl = property(_wcs.WorldCoor_offscl_get, _wcs.WorldCoor_offscl_set, doc=r"""offscl""") - wcson = property(_wcs.WorldCoor_wcson_get, _wcs.WorldCoor_wcson_set, doc=r"""wcson""") - naxis = property(_wcs.WorldCoor_naxis_get, _wcs.WorldCoor_naxis_set, doc=r"""naxis""") - naxes = property(_wcs.WorldCoor_naxes_get, _wcs.WorldCoor_naxes_set, doc=r"""naxes""") - wcsproj = property(_wcs.WorldCoor_wcsproj_get, _wcs.WorldCoor_wcsproj_set, doc=r"""wcsproj""") - linmode = property(_wcs.WorldCoor_linmode_get, _wcs.WorldCoor_linmode_set, doc=r"""linmode""") - detector = property(_wcs.WorldCoor_detector_get, _wcs.WorldCoor_detector_set, doc=r"""detector""") - instrument = property(_wcs.WorldCoor_instrument_get, _wcs.WorldCoor_instrument_set, doc=r"""instrument""") - ctype = property(_wcs.WorldCoor_ctype_get, _wcs.WorldCoor_ctype_set, doc=r"""ctype""") - c1type = property(_wcs.WorldCoor_c1type_get, _wcs.WorldCoor_c1type_set, doc=r"""c1type""") - c2type = property(_wcs.WorldCoor_c2type_get, _wcs.WorldCoor_c2type_set, doc=r"""c2type""") - ptype = property(_wcs.WorldCoor_ptype_get, _wcs.WorldCoor_ptype_set, doc=r"""ptype""") - units = property(_wcs.WorldCoor_units_get, _wcs.WorldCoor_units_set, doc=r"""units""") - radecsys = property(_wcs.WorldCoor_radecsys_get, _wcs.WorldCoor_radecsys_set, doc=r"""radecsys""") - radecout = property(_wcs.WorldCoor_radecout_get, _wcs.WorldCoor_radecout_set, doc=r"""radecout""") - radecin = property(_wcs.WorldCoor_radecin_get, _wcs.WorldCoor_radecin_set, doc=r"""radecin""") - eqin = property(_wcs.WorldCoor_eqin_get, _wcs.WorldCoor_eqin_set, doc=r"""eqin""") - eqout = property(_wcs.WorldCoor_eqout_get, _wcs.WorldCoor_eqout_set, doc=r"""eqout""") - sysin = property(_wcs.WorldCoor_sysin_get, _wcs.WorldCoor_sysin_set, doc=r"""sysin""") - syswcs = property(_wcs.WorldCoor_syswcs_get, _wcs.WorldCoor_syswcs_set, doc=r"""syswcs""") - sysout = property(_wcs.WorldCoor_sysout_get, _wcs.WorldCoor_sysout_set, doc=r"""sysout""") - center = property(_wcs.WorldCoor_center_get, _wcs.WorldCoor_center_set, doc=r"""center""") - wcsl = property(_wcs.WorldCoor_wcsl_get, _wcs.WorldCoor_wcsl_set, doc=r"""wcsl""") - lin = property(_wcs.WorldCoor_lin_get, _wcs.WorldCoor_lin_set, doc=r"""lin""") - cel = property(_wcs.WorldCoor_cel_get, _wcs.WorldCoor_cel_set, doc=r"""cel""") - prj = property(_wcs.WorldCoor_prj_get, _wcs.WorldCoor_prj_set, doc=r"""prj""") - lngcor = property(_wcs.WorldCoor_lngcor_get, _wcs.WorldCoor_lngcor_set, doc=r"""lngcor""") - latcor = property(_wcs.WorldCoor_latcor_get, _wcs.WorldCoor_latcor_set, doc=r"""latcor""") - distcode = property(_wcs.WorldCoor_distcode_get, _wcs.WorldCoor_distcode_set, doc=r"""distcode""") - distort = property(_wcs.WorldCoor_distort_get, _wcs.WorldCoor_distort_set, doc=r"""distort""") - command_format = property(_wcs.WorldCoor_command_format_get, _wcs.WorldCoor_command_format_set, doc=r"""command_format""") - ltm = property(_wcs.WorldCoor_ltm_get, _wcs.WorldCoor_ltm_set, doc=r"""ltm""") - ltv = property(_wcs.WorldCoor_ltv_get, _wcs.WorldCoor_ltv_set, doc=r"""ltv""") - idpix = property(_wcs.WorldCoor_idpix_get, _wcs.WorldCoor_idpix_set, doc=r"""idpix""") - ndpix = property(_wcs.WorldCoor_ndpix_get, _wcs.WorldCoor_ndpix_set, doc=r"""ndpix""") - wcs = property(_wcs.WorldCoor_wcs_get, _wcs.WorldCoor_wcs_set, doc=r"""wcs""") - wcsdep = property(_wcs.WorldCoor_wcsdep_get, _wcs.WorldCoor_wcsdep_set, doc=r"""wcsdep""") - wcsname = property(_wcs.WorldCoor_wcsname_get, _wcs.WorldCoor_wcsname_set, doc=r"""wcsname""") - wcschar = property(_wcs.WorldCoor_wcschar_get, _wcs.WorldCoor_wcschar_set, doc=r"""wcschar""") - logwcs = property(_wcs.WorldCoor_logwcs_get, _wcs.WorldCoor_logwcs_set, doc=r"""logwcs""") - - def __init__(self): - r"""__init__(self) -> WorldCoor""" - _wcs.WorldCoor_swiginit(self, _wcs.new_WorldCoor()) - __swig_destroy__ = _wcs.delete_WorldCoor - -# Register WorldCoor in _wcs: -_wcs.WorldCoor_swigregister(WorldCoor) - - - diff --git a/PyWCSTools/wcssubs-3.9.5/wcscon.py b/PyWCSTools/wcssubs-3.9.5/wcscon.py deleted file mode 100644 index 4cef537..0000000 --- a/PyWCSTools/wcssubs-3.9.5/wcscon.py +++ /dev/null @@ -1,73 +0,0 @@ -# This file was automatically generated by SWIG (http://www.swig.org). -# Version 4.0.2 -# -# Do not make changes to this file unless you know what you are doing--modify -# the SWIG interface file instead. - -from sys import version_info as _swig_python_version_info -if _swig_python_version_info < (2, 7, 0): - raise RuntimeError("Python 2.7 or later required") - -# Import the low-level C/C++ module -if __package__ or "." in __name__: - from . import _wcscon -else: - import _wcscon - -try: - import builtins as __builtin__ -except ImportError: - import __builtin__ - -def _swig_repr(self): - try: - strthis = "proxy of " + self.this.__repr__() - except __builtin__.Exception: - strthis = "" - return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,) - - -def _swig_setattr_nondynamic_instance_variable(set): - def set_instance_attr(self, name, value): - if name == "thisown": - self.this.own(value) - elif name == "this": - set(self, name, value) - elif hasattr(self, name) and isinstance(getattr(type(self), name), property): - set(self, name, value) - else: - raise AttributeError("You cannot add instance attributes to %s" % self) - return set_instance_attr - - -def _swig_setattr_nondynamic_class_variable(set): - def set_class_attr(cls, name, value): - if hasattr(cls, name) and not isinstance(getattr(cls, name), property): - set(cls, name, value) - else: - raise AttributeError("You cannot add class attributes to %s" % cls) - return set_class_attr - - -def _swig_add_metaclass(metaclass): - """Class decorator for adding a metaclass to a SWIG wrapped class - a slimmed down version of six.add_metaclass""" - def wrapper(cls): - return metaclass(cls.__name__, cls.__bases__, cls.__dict__.copy()) - return wrapper - - -class _SwigNonDynamicMeta(type): - """Meta class to enforce nondynamic attributes (no new attributes) for a class""" - __setattr__ = _swig_setattr_nondynamic_class_variable(type.__setattr__) - - - -def wcscon(sys1, sys2, eq1, eq2, arg5, arg6, epoch): - r"""wcscon(sys1, sys2, eq1, eq2, arg5, arg6, epoch)""" - return _wcscon.wcscon(sys1, sys2, eq1, eq2, arg5, arg6, epoch) - -def wcscsys(wcstring): - r"""wcscsys(wcstring) -> int""" - return _wcscon.wcscsys(wcstring) - - diff --git a/PyWCSTools/wcssubs-3.9.7/Files b/PyWCSTools/wcssubs-3.9.7/Files new file mode 100644 index 0000000..94d18da --- /dev/null +++ b/PyWCSTools/wcssubs-3.9.7/Files @@ -0,0 +1,179 @@ +WCSTools libwcs Subroutines (3.9.0, March 11, 2011) + +actread.c + Return stars from the USNO ACT Reference Catalog +binread.c + Return stars from catalog files in the TDC binary catalog format +catread.c + Return stars from catalog files in the TDC ASCII catalog format +catutil.c + Subroutines for catalog identification and number range decoding +cel.c + WCSLIB spherical coordinate transformation drivers +daoread.c + Read x, y, and magnitude from DAOFIND output file and return x, y, and + flux for use by IMSTAR or IMWCS. +dateutil.c + Subroutines for conversions between various date and time formats +distort.c + Subroutines for conversions between image pixel and focal plane coordinates +dsspos.c + dsspos() uses the WCS structure to compute sky coordinates given + image pixel X and Y for images with Digitized Sky Survey plate solutions + in their headers. dsspix() uses the WCS structure to compute image + pixel X and Y given sky coordinates for DSS images. Algorithms from + StSCI CASB. +fileutil.c + Subroutines for finding size and contents of ASCII files +findstar.c + findStars() gets the location and brightest pixel of stars in the given + image. Included are subroutines to find and reject bright pixels and + compute a star centroid. +fitsfile.c + FITS header and image reading and writing subroutines, including FITS + table support. +fitswcs.c + GetWCSFITS() returns a WCS structure used by wcs.c subroutines from a FITS + or IRAF .imh image, reading only the header. + GetFITShead() returns a FITS header from a FITS or IRAF .imh image. + DelWCS() delete the WCS keywords in a FITS header. +fortcat.c + Fortran wrapper subroutines for catalog reading subroutines ctgread() and ctgrnum() +fortwcs.c + Fortran wrapper subroutines for all useful subroutines in wcs.c and wcsinit.c +gscread.c + Return HST Guide Stars from standard CDROM format FITS table files for + a given RA, Dec, and magnitude range or list of star numbers. +gsc2read.c + Return GSC II Stars using an HTTP query over the web for + a given RA, Dec, and magnitude range or list of star numbers. +hget.c + Subroutines to extract values from FITS headers by keyword. + Subroutines for parsing RA and Dec strings are included. +hput.c + Subroutines to implant values into FITS headers by keyword (and to + delete headers). +iget.c + Subroutines to extract values from IRAF multi-keyword header parameters +imhfile.c + IRAF header and image reading and writing subroutines. IRAF headers + are converted to FITS headers for use by other programs and can be + derived from FITS headers for writing. +imio.c + Subroutines to get, put, and move pixels of various data types between images + im memory and a program. +imrotate.c + RotFITS() rotates an image by 90, 180, or 270 degrees, with an optional + left-right reflection before the rotation. +imgetwcs.c + GetWCSFITS() reads world coordinate system header information and returns + the image center coordinates and size as well as the wcs data structure. +imsetwcs.c + SetWCSFITS() uses findStars to find the stars in an image, gscread to + find the Guide Stars in the nominal image region, and findRegisration or + findCoords to fit plate-tangent WCS to the image. +lin.c + WCSLIB linear transformation subroutines +matchstar.c + StarMatch() takes a list of reference star positions and a list + of object coordinates from an image and finds the image pixels + which correspond to each of the reference stars. It then uses these + matches to get an image center, plate scale, and rotation. The actual + fit is based on the amoeba subroutine in Numerical Recipes, and all + necessary subroutines are included. +platepos.c + platepos() uses the WCS structure to compute sky coordinates given + image pixel X and Y for images with polynomial plate solutions + in their headers. platepix() uses the WCS structure to compute image + pixel X and Y given sky coordinates for such images. Algorithms are based + on those in dsspos.c, but go straight from pixels to angles without an + intermediate plate coordinate. +poly.c + Polynomial evaluation for SCAMP distortion correction +proj.c + WCSLIB spherical map projection subroutines +sdssread.c + Return Sloan Digital Sky Survey Photometry Catalog sources using an + HTTP query over the web for a given RA, Dec, and magnitude range. +sortstars.c + Subroutines to sort lists of stars by right ascension, magnitude, or flux +sph.c + WCSLIB spherical coordinate transformation subroutines +tabread.c + Return stars from a tab table format catalog file for a given RA, Dec, + and magnitude range or list of star numbers. Based on John Roll's + Starbase format. +tmcread.c + Return 2MASS Point Source Catalog stars from the catalog as ungzipped from + the DVD into (or linked from) a common root directory for a given RA, Dec, + and magnitude range or list of star numbers. Both IDR2 and All-Sky release + formats are supported. +tnxpos.c + tnxpos() uses the WCS keywords set up for IRAF's TNX projection to compute + sky coordinates given image pixel X and Y. tnxpix() uses the WCS structure + to compute image pixel X and Y given sky coordinates for such images. The + projection is a tangent plane with corrections between the rotation and + scaling and the actual projection. +uacread.c + Return USNO A and SA Catalog stars from their standard CDROM format + files for a given RA, Dec, and magnitude range or list of star numbers. +ubcread.c + Return USNO B Catalog stars from their standard format files for a + given RA, Dec, and magnitude range or list of star numbers. +ucacread.c + Return USNO UCAC1, UCAC2, or UCAC3 Catalog stars from their standard format + files for a given RA, Dec, and magnitude range or list of star numbers. +ujcread.c + Return USNO UJ Catalog stars from its standard CDROM format files for + a given RA, Dec, and magnitude range or list of star numbers. +wcs.c + Subroutines for using FITS or IRAF header spatial world coordinate + system information. +wcsinit.c + Subroutines to initialize WCS structure from a FITS header +wcscon.c + Subroutines for converting between B1950, J2000, and galactic + coordinates, mostly based on Starlink SLA_LIB subroutines. +webread.c + Open Starbase files across the Internet using HTTP queries +worldpos.c + worldpos() uses the WCS structure to compute sky coordinates given + image pixel X and Y for images with header information for any of 8 + standard world coordinate systems. worldpix() uses the WCS structure + to compute image pixel X and Y given sky coordinates for the same images. + Mostly from NRAO. +zpxpos.c + zpxpos() uses the WCS keywords set up for IRAF's ZPX projection to + compute sky coordinates given image pixel X and Y. zpxpix() uses + the WCS structure to compute image pixel X and Y given sky coordinates + for such images. The projection is a tangent plane with corrections + between the rotation and scaling and the actual projection. + +fitshead.h + Declarations of FITS header access subroutines +fitsfile.h + Declarations of image access subroutines and FITS table data structure. +imio.h + Declarations of subroutines to convert binary formats of numbers +lwcs.h + Constants used by star-finding and WCS-setting subroutines +wcscat.h + Declarations for star catalog data structures +wcs.h + Declaration of WCS data structure and useful conversions. +wcslib.h + Declarations for WCSLIB high level driver subroutines, trig and inverse + trig functions, spherical map projection subroutines, spherical coordinate + transformation drivers, and linear transformation subroutines + +* Notes: + WCSLIB subroutines were written by Mark Calabretta of CSIRO and have + been modified in several ways: + 1) His distributed wcs.h has been changed to wcslib.h, and + 2) wcstrig.c subroutine names have been changed from d() + to deg() to avoid name conflicts on some operating + systems. + 3) ifndef's at start of headers files have been named to reflect + the names of the header files, i.e. wcslib_h_ in wcslib.h. + 4) All header files have been combined into wcslib.h + 5) Emmanuel Bertin's SCAMP distortion has been added to proj.c:1 diff --git a/PyWCSTools/wcssubs-3.9.5/NEWS b/PyWCSTools/wcssubs-3.9.7/NEWS similarity index 94% rename from PyWCSTools/wcssubs-3.9.5/NEWS rename to PyWCSTools/wcssubs-3.9.7/NEWS index 3fba1b6..f74ff2a 100644 --- a/PyWCSTools/wcssubs-3.9.5/NEWS +++ b/PyWCSTools/wcssubs-3.9.7/NEWS @@ -1,7 +1,25 @@ WCSTools WCS subroutine library release history -Version 3.9.5 (May 2, 2017) -dateutil.c: Allocate new output string for fd2ofd() and fd2oft() +Version 3.9.7 (February 1, 2022) +fileutil.c: Move range, token, and ASCII file subroutines here from elsewhere +fileutil.c: Add agetw() to get first space-less word from keyword=value string +fileutil.c: Add agetl() to get a line from a multi-line ASCII file +fitsfile.h: Move declarations of range, token, and ASCII file subroutines here +fitsfile.h: Add lt2mfd() to convert local time to ISO format with month name(2022-02-21) +fitsfile.h: Add putfilebuff(), aget*(), polynomial routines from fileutil.c (2022-01-31) +fitsfile.h: Add range subroutine declarations (2022-02-02) + +Version 3.9.6 (August 31, 2020) +No changes to WCS subroutines + +Version 3.9.5 (October 29, 2019) +dateutil.c: In agets(), drop trailing commas, underscores, spaces (2019-10-29) +dateutil.c: Add ang2sec() and deg2sec() to convert to arcseconds (2019-09-24) +dateutil.c: Allocate new output string for fd2ofd() and fd2oft() (2017-05-02) +fitsfile.c: Increase header length default to 288000 = 100 blocks (2019-09-23) +hput.c: Allow arbitrary length keywords up to 64 characters (2018-08-28) +wcs.c: Change strcpy() to strncpy() where destination shorter than origin (2017-12-12) +wcsinit.c: Read up to 16 characters for ctype[2] and ctype[3] (2018-05-21) Version 3.9.4 (August 2, 2016) (after Ole Streicher) wcs.c: Clean up use of ptype so it is always 3 characters long diff --git a/PyWCSTools/wcssubs-3.9.5/cel.c b/PyWCSTools/wcssubs-3.9.7/cel.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/cel.c rename to PyWCSTools/wcssubs-3.9.7/cel.c diff --git a/PyWCSTools/wcssubs-3.9.5/dateutil.c b/PyWCSTools/wcssubs-3.9.7/dateutil.c similarity index 96% rename from PyWCSTools/wcssubs-3.9.5/dateutil.c rename to PyWCSTools/wcssubs-3.9.7/dateutil.c index f0ccc5d..0530d14 100644 --- a/PyWCSTools/wcssubs-3.9.5/dateutil.c +++ b/PyWCSTools/wcssubs-3.9.7/dateutil.c @@ -1,8 +1,8 @@ /*** File libwcs/dateutil.c - *** May 2, 2017 + *** July 27, 2021 *** By Jessica Mink, jmink@cfa.harvard.edu *** Harvard-Smithsonian Center for Astrophysics - *** Copyright (C) 1999-2017 + *** Copyright (C) 1999-2021 *** Smithsonian Astrophysical Observatory, Cambridge, MA, USA This library is free software; you can redistribute it and/or @@ -42,6 +42,9 @@ dd-mm-yy (nonstandard FITS use before 2000) yyyy-mm-dd (FITS standard after 1999) yyyy-mm-ddThh:mm:ss.ss (FITS standard after 1999) + mfd = New FITS date string with month as name not number + yyyy-mmm-dd or + yyyy-mmm-ddThh:mm:ss.ss hr = Sexigesimal hours as hh:mm:dd.ss jd = Julian Date lt = Local time @@ -61,6 +64,7 @@ lst = Local Sidereal Time (includes nutation) (longitude must be set) hjd = Heliocentric Julian Date mhjd = modified Heliocentric Julian Date = HJD - 2400000.5 + sec = seconds of angle * ang2hr (angle) * Convert angle in decimal floating point degrees to hours as hh:mm:ss.ss @@ -133,20 +137,22 @@ * ets2ts (tsec) * Convert from ET in seconds since 1950-01-01 to UT in same format * - * fd2ep, fd2epb, fd2epj (string) - * Convert FITS date string to fractional year - * Convert time alone to fraction of Besselian year * fd2doy (string, year, doy) * Convert FITS standard date string to year and day of year * fd2dt (string, date, time) * Convert FITS date string to date as yyyy.ddmm and time as hh.mmsss * Convert time alone to hh.mmssss with date set to 0.0 + * fd2ep, fd2epb, fd2epj (string) + * Convert FITS date string to fractional year + * Convert time alone to fraction of Besselian year * fd2i (string,iyr,imon,iday,ihr,imn,sec, ndsec) * Convert FITS standard date string to year month day hours min sec * Convert time alone to hours min sec, year month day are zero * fd2jd (string) * Convert FITS standard date string to Julian date * Convert time alone to fraction of day + * fd2mfd (string) + * Convert from FITS date to FITS date string with month name * fd2mjd (string) * Convert FITS standard date string to modified Julian date * fd2ts (string) @@ -178,6 +184,8 @@ * * lt2dt() * Return local time as yyyy.mmdd and time as hh.mmssss + * lt2mfd () + * Return local time as ISO date string with month name * lt2fd() * Return local time as FITS ISO date string * lt2tsi() @@ -231,7 +239,7 @@ * Convert seconds since start of day to hh.mmssss * * fd2gst (string) - * convert from FITS date Greenwich Sidereal Time + * convert from FITS date to Greenwich Sidereal Time * dt2gst (date, time) * convert from UT as yyyy.mmdd hh.mmssss to Greenwich Sidereal Time * ts2gst (tsec) @@ -250,6 +258,8 @@ * convert to current UT in FITS format given Greenwich Mean Sidereal Time * mst2jd (dj) * convert to current UT as Julian Date given Greenwich Mean Sidereal Time + * hjd2lst (dj) + * Calculate Local Sidereal Time from heliocentric Julian Date * jd2lst (dj) * Calculate Local Sidereal Time from Julian Date * ts2lst (tsec) @@ -390,6 +400,48 @@ char *angle; /* Angle in sexigesimal hours (hh:mm:ss.sss) */ } +/* HR2SEC -- Convert angle in hours as hh:mm:ss.ss to fractional arcseconds */ + +double +hr2sec (angle) + +char *angle; /* Angle as dd:mm:ss.ss */ +{ + double sec; + + sec = 15.0 * (str2dec (angle) * 3600.0); + return (sec); +} + + +/* DEG2SEC -- Convert angle in degrees as dd:mm:ss.ss to fractional arcseconds */ + +double +deg2sec (angle) + +char *angle; /* Angle as dd:mm:ss.ss */ +{ + double sec; + + sec = str2dec (angle) * 3600.0; + return (sec); +} + + +/* ANG2SEC -- Convert angle in fractional degrees to fractional arcseconds */ + +double +ang2sec (angle) + +double angle; /* Angle in degrees */ +{ + double sec; + + sec = angle * 3600.0; + return (sec); +} + + /* DT2FD-- convert vigesimal date and time to FITS date, yyyy-mm-ddThh:mm:ss.ss */ char * @@ -528,6 +580,50 @@ int sys; /* J2000, B1950, GALACTIC, ECLIPTIC */ return (dj - lt); } +/* HJD2LST-- convert Heliocentric Julian Date to local sidereal time in radians */ + +double +hjd2lst (dj) + +double dj; /* Julian Date */ + +{ +double dlong; /* Longitude in degrees */ +double dtpi, dj0, dst0, dut, dt; +double d1, d2, d3; +double dpi, df, dct0, dcjul; +double dst; /* Local sidereal time in radians (returned) */ + + dpi = 3.141592653589793; + dtpi = 2.0 * dpi; + df = 1.00273790934; + dct0 = 2415020.0; + dcjul = 36525.0; + +/* Convert longitude from degrees to radians */ + dlong = longitude * dpi / 180.0; + +/* Constants D1,D2,D3 for calculating Greenwich Mean Sidereal Time at 0 UT */ + d1 = 1.739935934667999; + d2 = 628.3319509909095; + d3 = 0.000006755878646261384; + + dj0 = floor (dj) + 0.5; + if (dj0 > dj) { + dj0 = dj0 - 1.0; + } + dut = (dj - dj0) * dtpi; + + dt = (dj0 - dct0) / dcjul; + dst0 = d1 + (d2 * dt) + (d3 * dt * dt); + dst0 = fmod (dst0, dtpi); + dst = (df * dut) + dst0 - dlong; + dst = fmod (dst + (2.0 * dtpi) , dtpi); + +return (dst); + + +} /* JD2HJD-- convert (geocentric) Julian date to Heliocentric Julian Date */ @@ -855,6 +951,20 @@ double *time; /* Time as hh.mmssxxxx (returned) */ } +/* LT2MFD-- Convert local time to ISO date with month name */ + +char * +lt2mfd () + +{ + char *datestring; + + datestring = lt2fd(); + + return (fd2mfd (datestring)); +} + + /* LT2FD-- Return current local time as FITS ISO date string */ char * @@ -1958,6 +2068,80 @@ char *string; /* FITS date string, which may be: } +/* FD2MFD-- convert any FITS standard date to ISO date with month name */ + +char * +fd2mfd (string) + +char *string; /* FITS date string, which may be: + fractional year + dd/mm/yy (FITS standard before 2000) + dd-mm-yy (nonstandard use before 2000) + yyyy-mm-dd (FITS standard after 1999) + yyyy-mm-ddThh:mm:ss.ss (FITS standard after 1999) */ +{ + int iyr,imon,iday,ihr,imn; + double sec, date, time; + int nf; + char tstring[32], dstring[32], *fstring; + char outform[64]; + char month[13][4]; + strcpy (month[1],"Jan"); + strcpy (month[2],"Feb"); + strcpy (month[3],"Mar"); + strcpy (month[4],"Apr"); + strcpy (month[5],"May"); + strcpy (month[6],"Jun"); + strcpy (month[7],"Jul"); + strcpy (month[8],"Aug"); + strcpy (month[9],"Sep"); + strcpy (month[10],"Oct"); + strcpy (month[11],"Nov"); + strcpy (month[12],"Dec"); + + fd2dt (string, &date, &time); + fd2i (string,&iyr,&imon,&iday,&ihr,&imn,&sec, 3); + + /* Convert to ISO date format */ + string = (char *) calloc (32, sizeof (char)); + + /* Make time string */ + if (time != 0.0 || ndec > 0) { + if (ndec == 0) + nf = 2; + else + nf = 3 + ndec; + if (ndec > 0) { + sprintf (outform, "%%02d:%%02d:%%0%d.%df", nf, ndec); + sprintf (tstring, outform, ihr, imn, sec); + } + else { + sprintf (outform, "%%02d:%%02d:%%0%dd", nf); + sprintf (tstring, outform, ihr, imn, (int)(sec+0.5)); + } + } + else + sprintf (tstring, ""); + + /* Make date string */ + if (date != 0.0) + sprintf (dstring, "%4d-%3s-%02d", iyr, month[imon], iday); + else + sprintf (dstring, ""); + + /* Make ISOish date string */ + fstring = (char *) calloc (32, sizeof (char)); + if (date == 0.0) + strcpy (fstring, tstring); + else if (time == 0.0 && ndec < 1) + strcpy (fstring, dstring); + else + sprintf (fstring, "%sT%s", dstring, tstring); + + return (fstring); +} + + /* FD2FD-- convert any FITS standard date to ISO FITS standard date */ char * @@ -4555,4 +4739,10 @@ double dnum, dm; * Oct 19 2012 Unused l0 dropped from jd2lst(); ts2ss from jd2mst() * * May 2 2017 Allocate new output string for fd2ofd() and fd2oft() + * + * Sep 24 2019 Add ang2sec() and deg2sec() to convert to arcseconds + * + * Jun 11 2021 Add fd2mfd() to replace month number with month name + * Jul 13 2021 Add hjd2lst() for rvtools. + * Jul 27 2021 Add lt2mfd() for logging time in RVTools */ diff --git a/PyWCSTools/wcssubs-3.9.5/distort.c b/PyWCSTools/wcssubs-3.9.7/distort.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/distort.c rename to PyWCSTools/wcssubs-3.9.7/distort.c diff --git a/PyWCSTools/wcssubs-3.9.5/dsspos.c b/PyWCSTools/wcssubs-3.9.7/dsspos.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/dsspos.c rename to PyWCSTools/wcssubs-3.9.7/dsspos.c diff --git a/PyWCSTools/wcssubs-3.9.7/fileutil.c b/PyWCSTools/wcssubs-3.9.7/fileutil.c new file mode 100644 index 0000000..adec63d --- /dev/null +++ b/PyWCSTools/wcssubs-3.9.7/fileutil.c @@ -0,0 +1,1755 @@ +/* File wcstools/libwcs/fileutil.c + * February 2, 2022 + * By Jessica Mink, SAO Telescope Data Center + + * Copyright (C) 1999-2022 + * Smithsonian Astrophysical Observatory, Cambridge, MA, USA + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with this library; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + Correspondence concerning WCSTools should be addressed as follows: + Internet email: jmink@cfa.harvard.edu + Postal address: Jessica Mink + Smithsonian Astrophysical Observatory + 60 Garden St. + Cambridge, MA 02138 USA + */ + +/** ASCII file utilities +/** Read, parse, and find out things about ASCII files + * + ** Read an entire file + * + * Subroutine: getfilebuff (filename) + * Return entire file contents in a character string + * Subroutine: putfilebuff (filename, string) + * Save a character string into a file + * + ** Find out features of a file + * + * Subroutine: getfilesize (filepath) + * Return size of a binary or ASCII file + * Subroutine: getfilelines (filepath) + * Return number of lines in an ASCII file + * Subroutine: getmaxlength (filepath) + * Return length of longest line in file + * Subroutine: isimlist (filepath) + * Return 1 if file is list of FITS or IRAF image files, else 0 + * Subroutine: isimlistd (filename, rootdir) + * Return 1 if file is list of FITS or IRAF image files, else 0 + * Subroutine: isfilelist (filepath, rootdir) + * Return 1 if file is list of readable files, else 0 + * Subroutine: isfile (filepath) + * Return 1 if file is a readable file, else 0 + * Subroutine: istiff (filepath) + * Return 1 if file is a readable TIFF graphics file, else 0 + * Subroutine: isjpeg (filepath) + * Return 1 if file is a readable JPEG graphics file, else 0 + * + ** Parsing strings + * + * Subroutine: first_token (diskfile, ncmax, token) + * Return the first token from the next line of an ASCII file + * Subroutine: next_line (diskfile, ncmax, line) + * Read the next line of an ASCII file and return its length + * Subroutine: stc2s (spchar, string) + * Replace character in string with space + * Subroutine: sts2c (spchar, string) + * Replace spaces in string with character + * Subroutine: setoken (tokens, string, cwhite) + * Tokenize a string for easy decoding + * Subroutine: nextoken (tokens, token, maxchars) + * Get next token from tokenized string + * Subroutine: getoken (tokens, itok, token, maxchars) + * Get specified token from tokenized string + * + ** Ranges + * + * Subroutine: RangeInit (string, ndef) + * Return structure containing ranges of numbers + * Subroutine: isrange (string) + * Return 1 if string is a range, else 0 + * Subroutine: rstart (range) + * Restart at beginning of range + * Subroutine: rgetn (range) + * Return number of values from range structure + * Subroutine: rgeti4 (range) + * Return next number from range structure as 4-byte integer + * Subroutine: rgetr8 (range) + * Return next number from range structure as 8-byte floating point number + * + ** Values from any ASCII keyword = value string in a file + * + * Subroutine: agetl (string, iline, line, lline) + Return one line from an ASCII string with LF, CR, EOS line termination + * Subroutine: ageti4 (string, keyword, ival) + * Read int value from a file where keyword=value, anywhere on a line + * Subroutine: agetr8 (string, keyword, dval) + * Read double value from a file where keyword=value, anywhere on a line + * Subroutine: agetw (string, keyword, word, maxlength) + * Read first word of string where keyword=word, anywhere on a line + * Subroutine: agets (string, keyword, lval, fillblank, value) + * Read value from a file where keyword=value, anywhere on a line + * + ** Polynomials + * + * Subroutine: polfit (x, y, x0, npts, nterms, a, stdev) + * Polynomial least squares fitting program + * Subroutine: determ (array, norder) + * Calculate the determinant of a square matrix (Bevington, page 294) + * Subroutine: polcomp (xi, x0, norder, a) + * Polynomial evaluation Y = A(1) + A(2)*X + A(3)*X^2 + A(3)*X^3 + ... + */ + +#include +#ifndef VMS +#include +#endif +#include +#include +#include +#include +#include +#include "fitsfile.h" +#include +#include +#define SZ_PATHNAME 128 + + +/* GETFILELINES -- Return number of lines in one file */ + +int +getfilelines (filepath) + +char *filepath; /* Pathname of file for which to find number of lines */ +{ + + char *buffer, *bufline; + int nlines = 0; + char newline = 10; + + /* Read file */ + buffer = getfilebuff (filepath); + + /* Count lines in file */ + if (buffer != NULL) { + bufline = buffer; + nlines = 0; + while ((bufline = strchr (bufline, newline)) != NULL) { + bufline = bufline + 1; + nlines++; + } + free (buffer); + return (nlines); + } + else { + return (0); + } +} + + +/* GETMAXLENGTH -- Return length of longest line in file */ + +int +getmaxlength (filepath) + +char *filepath; /* Pathname of file for which to find number of lines */ +{ + + char *buffer, *bufline, *buff0; + int thislength; + int nlines = 0; + int maxlength = 0; + char newline = 10; + + /* Read file */ + buffer = getfilebuff (filepath); + + /* Find longest line in file */ + if (buffer != NULL) { + bufline = buffer; + buff0 = buffer; + while ((bufline = strchr (bufline, newline)) != NULL) { + bufline = bufline + 1; + thislength = bufline - buff0; + if (thislength > maxlength) + maxlength = thislength; + buff0 = bufline; + } + free (buffer); + return (maxlength); + } + else { + return (0); + } +} + + +/* GETFILEBUFF -- return entire file contents in one character string */ + +char * +getfilebuff (filepath) + +char *filepath; /* Name of file from which to read */ +{ + + FILE *diskfile; + int lfile, nr, lbuff, ipt, ibuff; + char *buffer, *newbuff, *nextbuff; + + /* Treat stdin differently */ + if (!strcmp (filepath, "stdin")) { + lbuff = 5000; + lfile = lbuff; + buffer = NULL; + ipt = 0; + for (ibuff = 0; ibuff < 10; ibuff++) { + if ((newbuff = realloc (buffer, lfile+1)) != NULL) { + buffer = newbuff; + nextbuff = buffer + ipt; + nr = fread (nextbuff, 1, lbuff, stdin); + if (nr == lbuff) + break; + else { + ipt = ipt + lbuff; + lfile = lfile + lbuff; + } + } + else { + fprintf (stderr,"GETFILEBUFF: No room for %d-byte buffer\n", + lfile); + break; + } + } + return (buffer); + } + + /* Open file */ + if ((diskfile = fopen (filepath, "rb")) == NULL) + return (NULL); + + /* Find length of file */ + if (fseek (diskfile, 0, 2) == 0) + lfile = ftell (diskfile); + else + lfile = 0; + if (lfile < 1) { + fprintf (stderr,"GETFILEBUFF: File %s is empty\n", filepath); + fclose (diskfile); + return (NULL); + } + + /* Allocate buffer to hold entire file and read it */ + if ((buffer = calloc (1, lfile+1)) != NULL) { + fseek (diskfile, 0, 0); + nr = fread (buffer, 1, lfile, diskfile); + if (nr < lfile) { + fprintf (stderr,"GETFILEBUFF: File %s: read %d / %d bytes\n", + filepath, nr, lfile); + free (buffer); + fclose (diskfile); + return (NULL); + } + buffer[lfile] = (char) 0; + fclose (diskfile); + return (buffer); + } + else { + fprintf (stderr,"GETFILEBUFF: File %s: no room for %d-byte buffer\n", + filepath, lfile); + fclose (diskfile); + return (NULL); + } +} + + +/* PUTFILEBUFF -- Write a character string to a file */ + +int +putfilebuff (filepath, buffer) + +char *filepath; /* Pathname of file to which to write */ +char *buffer; /* Character string to write to the file */ +{ + + FILE *diskfile; + int nw, lbuff, nbytes; + + /* Open file */ + if ((diskfile = fopen (filepath, "w+b")) == NULL) { + fprintf (stderr,"PUTFILEBUFF: Could not open %s to write\n", filepath); + return (1); + } + + /* Find length of string */ + lbuff = strlen (buffer); + if (lbuff < 1) { + fprintf (stderr,"PUTFILEBUFF: String is empty; %s not written.\n", filepath); + fclose (diskfile); + return (1); + } + + /* Write entire string to file */ + nbytes = lbuff + 1; + nw = fwrite (buffer, 1, nbytes, diskfile); + if (nw < nbytes) { + fprintf (stderr,"PUTFILEBUFF: File %s: wrote %d / %d bytes\n", + filepath, nw, nbytes); + fclose (diskfile); + return (1); + } + fclose (diskfile); + return (0); +} + + +/* GETFILESIZE -- return size of one file in bytes */ + +int +getfilesize (filepath) + +char *filepath; /* Name of file for which to find size */ +{ + struct stat statbuff; + + if (stat (filepath, &statbuff)) + return (0); + else + return ((int) statbuff.st_size); +} + +int +getfilesize0 (filepath) + +char *filepath; /* Name of file for which to find size */ +{ + FILE *diskfile; + long filesize; + + /* Open file */ + if ((diskfile = fopen (filepath, "rb")) == NULL) + return (-1); + + /* Move to end of the file */ + if (fseek (diskfile, 0, 2) == 0) + + /* Position is the size of the file */ + filesize = ftell (diskfile); + + else + filesize = -1; + + fclose (diskfile); + + return ((int) filesize); +} + + +/* ISIMLIST -- Return 1 if list of FITS or IRAF files, else 0 */ +int +isimlist (filepath) + +char *filepath; /* Name of possible list file */ +{ + FILE *diskfile; + char token[SZ_PATHNAME]; + int ncmax = 127; + + if ((diskfile = fopen (filepath, "r")) == NULL) + return (0); + else { + first_token (diskfile, ncmax, token); + fclose (diskfile); + if (isfits (token) | isiraf (token)) + return (1); + else + return (0); + } +} + + +/* ISIMLISTD -- Return 1 if list of FITS or IRAF files, else 0 */ +int +isimlistd (filename, rootdir) + +char *filename; /* Name of possible list file */ +char *rootdir; /* Name of root directory for files in list */ +{ + FILE *diskfile; + char token[SZ_PATHNAME]; + char filepath[SZ_PATHNAME]; + int ncmax = 127; + + if ((diskfile = fopen (filename, "r")) == NULL) + return (0); + else { + first_token (diskfile, ncmax, token); + fclose (diskfile); + if (rootdir != NULL) { + strcpy (filepath, rootdir); + strcat (filepath, "/"); + strcat (filepath, token); + } + else + strcpy (filepath, token); + if (isfits (filepath) | isiraf (filepath)) + return (1); + else + return (0); + } +} + + +/* ISFILELIST -- Return 1 if list of readable files, else 0 */ +int +isfilelist (filename, rootdir) + +char *filename; /* Name of possible list file */ +char *rootdir; /* Name of root directory for files in list */ +{ + FILE *diskfile; + char token[SZ_PATHNAME]; + char filepath[SZ_PATHNAME]; + int ncmax = 127; + + if ((diskfile = fopen (filename, "r")) == NULL) + return (0); + else { + first_token (diskfile, ncmax, token); + fclose (diskfile); + if (rootdir != NULL) { + strcpy (filepath, rootdir); + strcat (filepath, "/"); + strcat (filepath, token); + } + else + strcpy (filepath, token); + if (isfile (filepath)) + return (1); + else + return (0); + } +} + + +/* ISFILE -- Return 1 if file is a readable file, else 0 */ + +int +isfile (filepath) + +char *filepath; /* Name of file to check */ +{ + struct stat statbuff; + + if (!strcasecmp (filepath, "stdin")) + return (1); + else if (access (filepath, R_OK)) + return (0); + else if (stat (filepath, &statbuff)) + return (0); + else { + if (S_ISDIR(statbuff.st_mode) && S_IFDIR) + return (2); + else + return (1); + } +} + + +/* NEXT_LINE -- Read the next line of an ASCII file, returning length */ +/* Lines beginning with # are ignored*/ + +int +next_line (diskfile, ncmax, line) + +FILE *diskfile; /* File descriptor for ASCII file */ +int ncmax; /* Maximum number of characters returned */ +char *line; /* Next line (returned) */ +{ + char *lastchar; + + /* If line can be read, add null at the end of the first token */ + if (fgets (line, ncmax, diskfile) != NULL) { + while (line[0] == '#') { + (void) fgets (line, ncmax, diskfile); + } + + /* If only character is a control character, return a NULL string */ + if ((strlen(line)==1) && (line[0]<32)){ + line[0] = (char)0; + return (1); + } + lastchar = line + strlen (line) - 1; + + /* Remove trailing spaces or control characters */ + while (*lastchar <= 32) + *lastchar-- = 0; + + return (strlen (line)); + } + else + return (0); +} + + +/* FIRST_TOKEN -- Return first token from the next line of an ASCII file */ +/* Lines beginning with # are ignored */ + +int +first_token (diskfile, ncmax, token) + +FILE *diskfile; /* File descriptor for ASCII file */ +int ncmax; /* Maximum number of characters returned */ +char *token; /* First token on next line (returned) */ +{ + char *lastchar, *lspace; + + /* If line can be read, add null at the end of the first token */ + if (fgets (token, ncmax, diskfile) != NULL) { + while (token[0] == '#') { + (void) fgets (token, ncmax, diskfile); + } + + /* If only character is a control character, return a NULL */ + if ((strlen(token)==1) && (token[0]<32)){ + token[0]=0; + return (1); + } + lastchar = token + strlen (token) - 1; + + /* Remove trailing spaces or control characters */ + while (*lastchar <= 32) + *lastchar-- = 0; + + if ((lspace = strchr (token, ' ')) != NULL) { + *lspace = (char) 0; + } + return (1); + } + else + return (0); +} + + +/* Replace character in string with space */ + +int +stc2s (spchar, string) + +char *spchar; /* Character to replace with spaces */ +char *string; +{ + int i, lstr, n; + lstr = strlen (string); + n = 0; + for (i = 0; i < lstr; i++) { + if (string[i] == spchar[0]) { + n++; + string[i] = ' '; + } + } + return (n); +} + + +/* Replace spaces in string with character */ + +int +sts2c (spchar, string) + +char *spchar; /* Character with which to replace spaces */ +char *string; +{ + int i, lstr, n; + lstr = strlen (string); + n = 0; + for (i = 0; i < lstr; i++) { + if (string[i] == ' ') { + n++; + string[i] = spchar[0]; + } + } + return (n); +} + + +/* ISTIFF -- Return 1 if TIFF file, else 0 */ +int +istiff (filepath) + +char *filepath; /* Name of file to check */ +{ + int diskfile; + char keyword[16]; + int nbr; + + /* First check to see if this is an assignment */ + if (strchr (filepath, '=')) + return (0); + + /* Check file extension */ + if (strsrch (filepath, ".tif") || + strsrch (filepath, ".tiff") || + strsrch (filepath, ".TIFF") || + strsrch (filepath, ".TIF")) + return (1); + + /* If no TIFF file suffix, try opening the file */ + else { + if ((diskfile = open (filepath, O_RDONLY)) < 0) + return (0); + else { + nbr = read (diskfile, keyword, 4); + close (diskfile); + if (nbr < 4) + return (0); + else if (!strncmp (keyword, "II", 2)) + return (1); + else if (!strncmp (keyword, "MM", 2)) + return (1); + else + return (0); + } + } +} + + +/* ISJPEG -- Return 1 if JPEG file, else 0 */ +int +isjpeg (filepath) + +char *filepath; /* Name of file to check */ +{ + int diskfile; + char keyword[16]; + int nbr; + + /* First check to see if this is an assignment */ + if (strchr (filepath, '=')) + return (0); + + /* Check file extension */ + if (strsrch (filepath, ".jpg") || + strsrch (filepath, ".jpeg") || + strsrch (filepath, ".JPEG") || + strsrch (filepath, ".jfif") || + strsrch (filepath, ".jfi") || + strsrch (filepath, ".JFIF") || + strsrch (filepath, ".JFI") || + strsrch (filepath, ".JPG")) + return (1); + + /* If no JPEG file suffix, try opening the file */ + else { + if ((diskfile = open (filepath, O_RDONLY)) < 0) + return (0); + else { + nbr = read (diskfile, keyword, 2); + close (diskfile); + if (nbr < 4) + return (0); + else if (keyword[0] == (char) 0xFF && + keyword[1] == (char) 0xD8) + return (1); + else + return (0); + } + } +} + + +/* ISGIF -- Return 1 if GIF file, else 0 */ +int +isgif (filepath) + +char *filepath; /* Name of file to check */ +{ + int diskfile; + char keyword[16]; + int nbr; + + /* First check to see if this is an assignment */ + if (strchr (filepath, '=')) + return (0); + + /* Check file extension */ + if (strsrch (filepath, ".gif") || + strsrch (filepath, ".GIF")) + return (1); + + /* If no GIF file suffix, try opening the file */ + else { + if ((diskfile = open (filepath, O_RDONLY)) < 0) + return (0); + else { + nbr = read (diskfile, keyword, 6); + close (diskfile); + if (nbr < 4) + return (0); + else if (!strncmp (keyword, "GIF", 3)) + return (1); + else + return (0); + } + } +} + + +static int maxtokens = MAXTOKENS; /* Set maximum number of tokens from wcscat.h*/ + +/* -- SETOKEN -- tokenize a string for easy decoding */ + +int +setoken (tokens, string, cwhite) + +struct Tokens *tokens; /* Token structure returned */ +char *string; /* character string to tokenize */ +char *cwhite; /* additional whitespace characters + * if = tab, disallow spaces and commas */ +{ + char squote, dquote, jch, newline; + char *iq, *stri, *wtype, *str0, *inew; + int i,j,naddw, ltok; + + newline = (char) 10; + squote = (char) 39; + dquote = (char) 34; + if (string == NULL) + return (0); + + /* Line is terminated by newline or NULL */ + inew = strchr (string, newline); + if (inew != NULL) + tokens->lline = inew - string - 1; + else + tokens->lline = strlen (string); + + /* Save current line in structure */ + tokens->line = string; + + /* Add extra whitespace characters */ + if (cwhite == NULL) + naddw = 0; + else + naddw = strlen (cwhite); + + /* if character is tab, allow only tabs and nulls as separators */ + if (naddw > 0 && !strncmp (cwhite, "tab", 3)) { + tokens->white[0] = (char) 9; /* Tab */ + tokens->white[1] = (char) 0; /* NULL (end of string) */ + tokens->nwhite = 2; + } + + /* if character is bar, allow only bars and nulls as separators */ + else if (naddw > 0 && !strncmp (cwhite, "bar", 3)) { + tokens->white[0] = '|'; /* Bar */ + tokens->white[1] = (char) 0; /* NULL (end of string) */ + tokens->nwhite = 2; + } + + /* otherwise, allow spaces, tabs, commas, nulls, and cwhite */ + else { + tokens->nwhite = 4 + naddw;; + tokens->white[0] = ' '; /* Space */ + tokens->white[1] = (char) 9; /* Tab */ + tokens->white[2] = ','; /* Comma */ + tokens->white[3] = (char) 124; /* Vertical bar */ + tokens->white[4] = (char) 0; /* Null (end of string) */ + if (tokens->nwhite > 20) + tokens->nwhite = 20; + if (naddw > 0) { + i = 0; + for (j = 4; j < tokens->nwhite; j++) { + tokens->white[j] = cwhite[i]; + i++; + } + } + } + tokens->white[tokens->nwhite] = (char) 0; + + tokens->ntok = 0; + tokens->itok = 0; + iq = string - 1; + for (i = 0; i < maxtokens; i++) { + tokens->tok1[i] = NULL; + tokens->ltok[i] = 0; + } + + /* Process string one character at a time */ + stri = string; + str0 = string; + while (stri < string+tokens->lline) { + + /* Keep stuff between quotes in one token */ + if (stri <= iq) + continue; + jch = *stri; + + /* Handle quoted strings */ + if (jch == squote) + iq = strchr (stri+1, squote); + else if (jch == dquote) + iq = strchr (stri+1, dquote); + else + iq = stri; + if (iq > stri) { + tokens->ntok = tokens->ntok + 1; + if (tokens->ntok > maxtokens) return (maxtokens); + tokens->tok1[tokens->ntok] = stri + 1; + tokens->ltok[tokens->ntok] = (iq - stri) - 1; + stri = iq + 1; + str0 = iq + 1; + continue; + } + + /* Search for unquoted tokens */ + wtype = strchr (tokens->white, jch); + + /* If this is one of the additional whitespace characters, + * pass as a separate token */ + if (wtype > tokens->white + 3) { + + /* Terminate token before whitespace */ + if (stri > str0) { + tokens->ntok = tokens->ntok + 1; + if (tokens->ntok > maxtokens) return (maxtokens); + tokens->tok1[tokens->ntok] = str0; + tokens->ltok[tokens->ntok] = stri - str0; + } + + /* Make whitespace character next token; start new one */ + tokens->ntok = tokens->ntok + 1; + if (tokens->ntok > maxtokens) return (maxtokens); + tokens->tok1[tokens->ntok] = stri; + tokens->ltok[tokens->ntok] = 1; + stri++; + str0 = stri; + } + + /* Pass previous token if regular whitespace or NULL */ + else if (wtype != NULL || jch == (char) 0) { + + /* Ignore leading whitespace */ + if (stri == str0) { + stri++; + str0 = stri; + } + + /* terminate token before whitespace; start new one */ + else { + tokens->ntok = tokens->ntok + 1; + if (tokens->ntok > maxtokens) return (maxtokens); + tokens->tok1[tokens->ntok] = str0; + tokens->ltok[tokens->ntok] = stri - str0; + stri++; + str0 = stri; + } + } + + /* Keep going if not whitespace */ + else + stri++; + } + + /* Add token terminated by end of line */ + if (str0 < stri) { + tokens->ntok = tokens->ntok + 1; + if (tokens->ntok > maxtokens) + return (maxtokens); + tokens->tok1[tokens->ntok] = str0; + ltok = stri - str0 + 1; + tokens->ltok[tokens->ntok] = ltok; + + /* Deal with white space just before end of line */ + jch = str0[ltok-1]; + if (strchr (tokens->white, jch)) { + ltok = ltok - 1; + tokens->ltok[tokens->ntok] = ltok; + tokens->ntok = tokens->ntok + 1; + tokens->tok1[tokens->ntok] = str0 + ltok; + tokens->ltok[tokens->ntok] = 0; + } + } + + tokens->itok = 0; + + return (tokens->ntok); +} + + +/* NEXTOKEN -- get next token from tokenized string */ + +int +nextoken (tokens, token, maxchars) + +struct Tokens *tokens; /* Token structure returned */ +char *token; /* token (returned) */ +int maxchars; /* Maximum length of token */ +{ + int ltok; /* length of token string (returned) */ + int it, i; + int maxc = maxchars - 1; + + tokens->itok = tokens->itok + 1; + it = tokens->itok; + if (it > tokens->ntok) + it = tokens->ntok; + else if (it < 1) + it = 1; + ltok = tokens->ltok[it]; + if (ltok > maxc) + ltok = maxc; + strncpy (token, tokens->tok1[it], ltok); + for (i = ltok; i < maxc; i++) + token[i] = (char) 0; + return (ltok); +} + + +/* GETOKEN -- get specified token from tokenized string */ + +int +getoken (tokens, itok, token, maxchars) + +struct Tokens *tokens; /* Token structure returned */ +int itok; /* token sequence number of token + * if <0, get whole string after token -itok + * if =0, get whole string */ +char *token; /* token (returned) */ +int maxchars; /* Maximum length of token */ +{ + int ltok; /* length of token string (returned) */ + int it, i; + int maxc = maxchars - 1; + + it = itok; + if (it > 0 ) { + if (it > tokens->ntok) + it = tokens->ntok; + ltok = tokens->ltok[it]; + if (ltok > maxc) + ltok = maxc; + strncpy (token, tokens->tok1[it], ltok); + } + else if (it < 0) { + if (it < -tokens->ntok) + it = -tokens->ntok; + ltok = tokens->line + tokens->lline - tokens->tok1[-it]; + if (ltok > maxc) + ltok = maxc; + strncpy (token, tokens->tok1[-it], ltok); + } + else { + ltok = tokens->lline; + if (ltok > maxc) + ltok = maxc; + strncpy (token, tokens->tok1[1], ltok); + } + for (i = ltok; i < maxc; i++) + token[i] = (char) 0; + + return (ltok); +} + +#include +#include +#include +#include +#include +#include "wcs.h" +#include "fitsfile.h" +//#include "wcscat.h" + +/* RANGEINIT -- Initialize range structure from string */ + +struct Range * +RangeInit (string, ndef) + +char *string; /* String containing numbers separated by , and - */ +int ndef; /* Maximum allowable range value */ + +{ + struct Range *range; + int ip, irange; + char *slast; + double first, last, step; + + if (!isrange (string) && !isnum (string)) + return (NULL); + ip = 0; + range = (struct Range *)calloc (1, sizeof (struct Range)); + range->irange = -1; + range->nvalues = 0; + range->nranges = 0; + range->valmax = -1000000000000.0; + range->valmin = 1000000000000.0; + + for (irange = 0; irange < MAXRANGE; irange++) { + + /* Default to entire list */ + first = 1.0; + last = ndef; + step = 1.0; + + /* Skip delimiters to start of range */ + while (string[ip] == ' ' || string[ip] == ' ' || + string[ip] == ',') + ip++; + + /* Get first limit + * Must be a number, '-', 'x', or EOS. If not return ERR */ + if (string[ip] == (char)0) { /* end of list */ + if (irange == 0) { + + /* Null string defaults */ + range->ranges[0] = first; + if (first < 1) + range->ranges[1] = first; + else + range->ranges[1] = last; + range->ranges[2] = step; + range->nvalues = range->nvalues + 1 + + ((range->ranges[1]-range->ranges[0])/step); + range->nranges++; + return (range); + } + else + return (range); + } + else if (string[ip] > (char)47 && string[ip] < 58) { + first = strtod (string+ip, &slast); + ip = slast - string; + } + else if (strchr ("-:x", string[ip]) == NULL) { + free (range); + return (NULL); + } + + /* Skip delimiters */ + while (string[ip] == ' ' || string[ip] == ' ' || + string[ip] == ',') + ip++; + + /* Get last limit + * Must be '-', or 'x' otherwise last = first */ + if (string[ip] == '-' || string[ip] == ':') { + ip++; + while (string[ip] == ' ' || string[ip] == ' ' || + string[ip] == ',') + ip++; + if (string[ip] == (char)0) + last = first + ndef; + else if (string[ip] > (char)47 && string[ip] < 58) { + last = strtod (string+ip, &slast); + ip = slast - string; + } + else if (string[ip] != 'x') + last = first + ndef; + } + else if (string[ip] != 'x') + last = first; + + /* Skip delimiters */ + while (string[ip] == ' ' || string[ip] == ' ' || + string[ip] == ',') + ip++; + + /* Get step + * Must be 'x' or assume default step. */ + if (string[ip] == 'x') { + ip++; + while (string[ip] == ' ' || string[ip] == ' ' || + string[ip] == ',') + ip++; + if (string[ip] == (char)0) + step = 1.0; + else if (string[ip] > (char)47 && string[ip] < 58) { + step = strtod (string+ip, &slast); + ip = slast - string; + } + else if (string[ip] != '-' && string[ip] != ':') + step = 1.0; + } + + /* Output the range triple */ + range->ranges[irange*3] = first; + range->ranges[irange*3 + 1] = last; + range->ranges[irange*3 + 2] = step; + range->nvalues = range->nvalues + ((last-first+(0.1*step)) / step + 1); + range->nranges++; + if (step > 0.0) { + if (first < range->valmin) + range->valmin = first; + if (last > range->valmax) + range->valmax = last; + } + else { + if (first > range->valmax) + range->valmax = first; + if (last < range->valmin) + range->valmin = last; + } + } + + return (range); +} + + +/* ISRANGE -- Return 1 if string is a range, else 0 */ + +int +isrange (string) + +char *string; /* String which might be a range of numbers */ + +{ + int i, lstr; + + /* If string is NULL or empty, return 0 */ + if (string == NULL || strlen (string) == 0) + return (0); + + /* If range separators present, check to make sure string is range */ + else if (strchr (string+1, '-') || strchr (string+1, ',')) { + lstr = strlen (string); + for (i = 0; i < lstr; i++) { + if (strchr ("0123456789-,.x", (int)string[i]) == NULL) + return (0); + } + return (1); + } + else + return (0); +} + + +/* RSTART -- Restart at beginning of range */ + +void +rstart (range) + +struct Range *range; /* Range structure */ + +{ + range->irange = -1; + return; +} + + +/* RGETN -- Return number of values from range structure */ + +int +rgetn (range) + +struct Range *range; /* Range structure */ + +{ + return (range->nvalues); +} + + +/* RGETR8 -- Return next number from range structure as 8-byte f.p. number */ + +double +rgetr8 (range) + +struct Range *range; /* Range structure */ + +{ + int i; + + if (range == NULL) + return (0.0); + else if (range->irange < 0) { + range->irange = 0; + range->first = range->ranges[0]; + range->last = range->ranges[1]; + range->step = range->ranges[2]; + range->value = range->first; + } + else { + range->value = range->value + range->step; + if (range->value > (range->last + (range->step * 0.5))) { + range->irange++; + if (range->irange < range->nranges) { + i = range->irange * 3; + range->first = range->ranges[i]; + range->last = range->ranges[i+1]; + range->step = range->ranges[i+2]; + range->value = range->first; + } + else + range->value = 0.0; + } + } + return (range->value); +} + + +/* RGETI4 -- Return next number from range structure as 4-byte integer */ + +int +rgeti4 (range) + +struct Range *range; /* Range structure */ + +{ + double value; + + value = rgetr8 (range); + return ((int) (value + 0.000000001)); +} + + +/* AGETL -- Get one LF- or CR-terminated line from an ASCII string */ + +int +agetl (string, iline, line, lline) + +char *string; /* Character string containing = info */ +int iline; /* Sequential line to return with 0=first line */ +char *line; /* Line (returned) */ +int lline; /* Maximum length for line */ +{ + char *line1, *cchar1, *llf, *lcr; + char *cchar2, *lastchar; + int ichar, jline, lstring; + int ilf = 10; + int icr = 13; + char clf = (char) 10; + char ccr = (char) 13; + int ieos = 0; + char ceos = (char) 0; + +/* If first line is desired, simply start at beginning of string */ + line1 = string; + +/* Otherwise, determine line termination and find start of desired line */ + if (iline > 0) { + llf = strchr (string, ilf); + lcr = strchr (string, icr); + lstring = strlen (string); + jline = 0; + if (llf) { + while (llf && jline < iline) { + line1 = llf + 1; + if (*line1 == ccr) + line1 = line1 + 1; + llf = strchr (line1, ilf); + jline++; + } + } + else if (lcr) { + while (lcr && jline < iline) { + line1 = lcr + 1; + if (*line1 == clf) + line1 = line1 + 1; + llf = strchr (line1, icr); + jline++; + } + } + +/* Pad out returned line with zeroes */ + else { + lastchar = line + lline; + cchar2 = line + strlen (line); + while (cchar2 < lastchar) { + *cchar2 = ceos; + cchar2++; + } + return (0); + } + } + +/* Copy line to output string */ + cchar1 = line1; + cchar2 = line; + lastchar = line + lline - 1; /* Leave space for terminating 0 */ + while (*cchar1 != clf && *cchar1 != ccr && + *cchar1 != ceos && cchar2 < lastchar) { + *cchar2 = *cchar1; + cchar1++; + cchar2++; + } + +/* Pad out returned line with zeroes */ + lastchar = line + lline; + do { + *cchar2 = ceos; + cchar2++; + } while (cchar2 < lastchar); + return (1); +} + + +/* AGETI4 -- Get integer value from ASCII string where keyword=value anywhere */ +int +ageti4 (string, keyword, ival) + +char *string; /* character string containing = */ +char *keyword; /* character string containing the name of the keyword + the value of which is returned. hget searches for a + line beginning with this string. if "[n]" or ",n" is + present, the n'th token in the value is returned. */ +int *ival; /* Integer value, returned */ +{ + char value[32]; + char kw[32]; + + strcpy (kw,keyword); + strcat (kw,"[1]"); + if (agets (string, kw, 31, 0, value)) { + *ival = atoi (value); + return (1); + } + else + return (0); +} + + +/* AGETR8 -- Get double value from ASCII string where keyword=value anywhere */ +int +agetr8 (string, keyword, dval) + +char *string; /* character string containing = */ +char *keyword; /* character string containing the name of the keyword + the value of which is returned. hget searches for a + line beginning with this string. if "[n]" or ",n" is + present, the n'th token in the value is returned. */ +double *dval; /* Double value, returned */ +{ + char value[32]; + char kw[32]; + + strcpy (kw,keyword); + strcat (kw,"[1]"); + if (agets (string, kw, 31, 0, value)) { + *dval = atof (value); + return (1); + } + else + return (0); +} + + +/* AGETW -- Get first word of ASCII string where keyword=value anywhere */ +int +agetw (string, keyword, word, maxlength) + +char *string; /* character string containing = */ +char *keyword; /* character string containing the name of the keyword + the value of which is returned. hget searches for a + line beginning with this string. if "[n]" or ",n" is + present, the n'th token in the value is returned. */ +char *word; /* First word of string value */ +int maxlength; /* Maximum number of characters in word */ +{ + char *value; + char kw[32]; + + strcpy (kw,keyword); + strcat (kw,"[1]"); + if (agets (string, kw, maxlength, 0, word)) { + return (1); + } + else + return (0); +} + + +/* AGETS -- Get keyword value from ASCII string with keyword=value anywhere */ + +int +agets (string, keyword0, lval, fillblank, value) + +char *string; /* character string containing = info */ +char *keyword0; /* character string containing the name of the keyword + the value of which is returned. hget searches for a + line beginning with this string. if "[n]" or ",n" is + present, the n'th token in the value is returned. */ +int lval; /* Size of value in characters + If negative, value ends at end of line */ +int fillblank; /* If 0, leave blanks, strip trailing blanks + if non-zero, replace blanks with underscores */ +char *value; /* String (returned) */ +{ + char keyword[81]; + char *pval, *str, *pkey, *pv; + char cquot, squot[2], dquot[2], lbracket[2], rbracket[2], comma[2]; + char *lastval, *rval, *brack1, *brack2, *lastring, *iquot, *ival; + char cend, *lineend; + int ipar, i, lkey, fkey; + int ntok, ltok; + struct Tokens valtok; + + char ceos = (char) 0; + char clf = (char) 10; + char ccr = (char) 13; + + squot[0] = (char) 39; + squot[1] = (char) 0; + dquot[0] = (char) 34; + dquot[1] = (char) 0; + lbracket[0] = (char) 91; + lbracket[1] = (char) 0; + comma[0] = (char) 44; + comma[1] = (char) 0; + cquot = ' '; + rbracket[0] = (char) 93; + rbracket[1] = (char) 0; + lastring = string + strlen (string); + +/* Find length of variable name, eliminating token choice */ + strncpy (keyword,keyword0, sizeof(keyword)-1); + brack1 = strsrch (keyword,lbracket); + if (brack1 == keyword) { + brack1 = NULL; + } + brack2 = NULL; + if (brack1 == NULL) + brack1 = strsrch (keyword,comma); + else { + brack2 = strsrch (brack1,rbracket); + if (brack2 != NULL) + *brack2 = '\0'; + } + + if (brack1 != NULL) { + *brack1 = '\0'; + brack1++; + } + lkey = strlen (keyword); + +/* If keyword has brackets, figure out which token to extract */ + if (brack1 != NULL) { + ipar = atoi (brack1); + } + else { + ipar = 1; + } + +/* First check for the existence of the keyword in the string */ + pval = NULL; + str = string; + while (pval == NULL) { + pkey = strcsrch (str, keyword); + +/* If keyword has not been found, return 0 */ + if (pkey == NULL) { + return (0); + } + +/* If it has been found, check for = or : and preceding characters */ + +/* Must be at start of file or after control character or space */ + if (pkey != string && *(pkey-1) > 32) { + str = pkey; + pval = NULL; + } + +/* Must have "=" or ":" as next nonspace and nonbracket character */ + else { + pv = pkey + lkey; + while (*pv == ' ' || *pv == ']' || *pv == 'o') { + pv++; + } + if (*pv != '=' && *pv != ':' && *pv != 10 && *pv != 'f') { + str = pkey; + pval = NULL; + } + +/* If found, bump pointer past keyword, operator, and spaces */ + else { + pval = pv + 1; + while (*pval == '=' || *pval == ' ') { + pval++; + } + break; + } + } + str = str + lkey; + if (str > lastring) { + break; + } + } + +/* If no value, return */ + if (pval == NULL) { + return (0); + } + +/* Parse value */ + +/* Drop leading spaces */ + while (*pval == ' ') pval++; + +/* Change end of line to EOS */ + cend = ceos; + if ((lineend = strchr (pval, clf))) { + cend = *lineend; + *lineend = ceos; + } + else if ((lineend = strchr (pval, ccr))) { + cend = *lineend; + *lineend = ceos; + } + else if ((lineend = strchr (pval, ceos))) { + cend = *lineend; + } + +/* Parse string */ + ntok = setoken (&valtok, pval, ""); + +/* Exit if requested token of value is beyond actual number */ + if (ipar > ntok) { + return (0); + } + +/* Extract appropriate token */ + ltok = getoken (&valtok, ipar, value, lval); + +/* Change blanks to underscores if requested */ + if (fillblank) { + for (ival = pval; ival < value+ltok; ival++) { + if (*ival == ' ') { + *ival = '_'; + } + } + } + +/* Fix input string */ + if (lineend) { + *lineend = cend; + } + +/* Fix keyword */ + if (brack1 != NULL) { + *brack1 = lbracket[0]; + } + if (brack2 != NULL) { + *brack2 = rbracket[0]; + } + + return (1); +} + + +/* Polynomial least squares fitting program, almost identical to the + * one in Bevington, "Data Reduction and Error Analysis for the + * Physical Sciences," page 141. The argument list was changed and + * the weighting removed. + * y = a(1) + a(2)*(x-x0) + a(3)*(x-x0)**2 + a(3)*(x-x0)**3 + . . . + */ + +void +polfit (x, y, x0, npts, nterms, a, stdev) + +double *x; /* Array of independent variable points */ +double *y; /* Array of dependent variable points */ +double x0; /* Offset to independent variable */ +int npts; /* Number of data points to fit */ +int nterms; /* Number of parameters to fit */ +double *a; /* Vector containing current fit values */ +double *stdev; /* Standard deviation of fit (returned) */ +{ + double sigma2sum; + double xterm,yterm,xi,yi; + double *sumx, *sumy; + double *array; + int i,j,k,l,n,nmax; + double delta; + + /* accumulate weighted sums */ + nmax = 2 * nterms - 1; + sumx = (double *) calloc (nmax, sizeof(double)); + sumy = (double *) calloc (nterms, sizeof(double)); + for (n = 0; n < nmax; n++) + sumx[n] = 0.0; + for (j = 0; j < nterms; j++) + sumy[j] = 0.0; + for (i = 0; i < npts; i++) { + xi = x[i] - x0; + yi = y[i]; + xterm = 1.0; + for (n = 0; n < nmax; n++) { + sumx[n] = sumx[n] + xterm; + xterm = xterm * xi; + } + yterm = yi; + for (n = 0; n < nterms; n++) { + sumy[n] = sumy[n] + yterm; + yterm = yterm * xi; + } + } + + /* Construct matrices and calculate coeffients */ + array = (double *) calloc (nterms*nterms, sizeof(double)); + for (j = 0; j < nterms; j++) { + for (k = 0; k < nterms; k++) { + n = j + k; + array[j+k*nterms] = sumx[n]; + } + } + delta = determ (array, nterms); + if (delta == 0.0) { + *stdev = 0.; + for (j = 0; j < nterms; j++) + a[j] = 0. ; + free (array); + free (sumx); + free (sumy); + return; + } + + for (l = 0; l < nterms; l++) { + for (j = 0; j < nterms; j++) { + for (k = 0; k < nterms; k++) { + n = j + k; + array[j+k*nterms] = sumx[n]; + } + array[j+l*nterms] = sumy[j]; + } + a[l] = determ (array, nterms) / delta; + } + + /* Calculate sigma */ + sigma2sum = 0.0; + for (i = 0; i < npts; i++) { + yi = polcomp (x[i], x0, nterms, a); + sigma2sum = sigma2sum + ((y[i] - yi) * (y[i] - yi)); + } + *stdev = sqrt (sigma2sum / (double) (npts - 1)); + + free (array); + free (sumx); + free (sumy); + return; +} + + +/*--- Calculate the determinant of a square matrix + * This subprogram destroys the input matrix array + * From Bevington, page 294. + */ + +double +determ (array, norder) + +double *array; /* Input matrix array */ +int norder; /* Order of determinant (degree of matrix) */ + +{ + double save, det; + int i,j,k,k1, zero; + + det = 1.0; + for (k = 0; k < norder; k++) { + + /* Interchange columns if diagonal element is zero */ + if (array[k+k*norder] == 0) { + zero = 1; + for (j = k; j < norder; j++) { + if (array[k+j*norder] != 0.0) + zero = 0; + } + if (zero) + return (0.0); + + for (i = k; i < norder; i++) { + save = array[i+j*norder]; + array[i+j*norder] = array[i+k*norder]; + array[i+k*norder] = save ; + } + det = -det; + } + + /* Subtract row k from lower rows to get diagonal matrix */ + det = det * array[k+k*norder]; + if (k < norder - 1) { + k1 = k + 1; + for (i = k1; i < norder; i++) { + for (j = k1; j < norder; j++) { + array[i+j*norder] = array[i+j*norder] - + (array[i+k*norder] * array[k+j*norder] / + array[k+k*norder]); + } + } + } + } + return (det); +} + +/* POLCOMP -- Polynomial evaluation + * Y = a(0) + a(1)*X + a(2)*X**2 + a(3)*X**3 + . . . */ + +double +polcomp (xi, x0, norder, a) + +double xi; /* Independent variable */ +double x0; /* Offset to independent variable */ +int norder; /* Number of coefficients */ +double *a; /* Vector containing coeffiecients */ +{ + double xterm, x, y; + int iterm; + + /* Accumulate polynomial value */ + x = xi - x0; + y = 0.0; + xterm = 1.0; + for (iterm = 0; iterm < norder; iterm++) { + y = y + a[iterm] * xterm; + xterm = xterm * x; + } + return (y); +} + +/* + * Jul 14 1999 New subroutines + * Jul 15 1999 Add getfilebuff() + * Oct 15 1999 Fix format eror in error message + * Oct 21 1999 Fix declarations after lint + * Dec 9 1999 Add next_token(); set pointer to next token in first_token + * + * Sep 25 2001 Add isfilelist(); move isfile() from catutil.c + * + * Jan 4 2002 Allow getfilebuff() to read from stdin + * Jan 8 2002 Add sts2c() and stc2s() for space-replaced strings + * Mar 22 2002 Clean up isfilelist() + * Aug 1 2002 Return 1 if file is stdin in isfile() + * + * Feb 4 2003 Open catalog file rb instead of r (Martin Ploner, Bern) + * Mar 5 2003 Add isimlistd() to check image lists with root directory + * May 27 2003 Use file stat call in getfilesize() instead of opening file + * Jul 17 2003 Add root directory argument to isfilelist() + * + * Sep 29 2004 Drop next_token() to avoid conflict with subroutine in catutil.c + * + * Sep 26 2005 In first_token, return NULL if token is only control character + * + * Feb 23 2006 Add istiff(), isjpeg(), isgif() to check TIFF, JPEG, GIF files + * Jun 20 2006 Cast call to fgets() void + * + * Jan 5 2007 Change stc2s() and sts2c() to pass single character as pointer + * Jan 11 2007 Move token access subroutines from catutil.c + * + * Aug 28 2014 Return length from next_line(): 0=unsuccessful + * + * Aug 31 2021 Add range, aget*, and polynomial subroutines from catutil.c + * + * Jan 20 2022 Add agetw() to read arbitrarily-sized space-less string + * Jan 20 2022 Separate subroutine list by topic at top of file + * Feb 1 2022 Add putfilebuff() and agetl() + * Feb 2 2022 Use token subroutines to parse value strings in agets() + */ diff --git a/PyWCSTools/wcssubs-3.9.5/fitsfile.c b/PyWCSTools/wcssubs-3.9.7/fitsfile.c similarity index 99% rename from PyWCSTools/wcssubs-3.9.5/fitsfile.c rename to PyWCSTools/wcssubs-3.9.7/fitsfile.c index 2c3e709..41a3797 100644 --- a/PyWCSTools/wcssubs-3.9.5/fitsfile.c +++ b/PyWCSTools/wcssubs-3.9.7/fitsfile.c @@ -1,8 +1,8 @@ /*** File libwcs/fitsfile.c - *** June 24, 2016 + *** September 23, 2019 *** By Jessica Mink, jmink@cfa.harvard.edu *** Harvard-Smithsonian Center for Astrophysics - *** Copyright (C) 1996-2016 + *** Copyright (C) 1996-2019 *** Smithsonian Astrophysical Observatory, Cambridge, MA, USA This library is free software; you can redistribute it and/or @@ -200,7 +200,7 @@ int *nbhead; /* Number of bytes before start of data (returned) */ nbytes = FITSBLOCK; *nbhead = 0; headend = NULL; - nbh = FITSBLOCK * 20 + 4; + nbh = FITSBLOCK * 100 + 4; header = (char *) calloc ((unsigned int) nbh, 1); (void) hlength (header, nbh); headnext = header; @@ -2325,4 +2325,6 @@ char *from, *last, *to; * * Jun 9 2016 Fix isnum() tests for added coloned times and dashed dates * Jun 24 2016 Add 1 to allocation of pheader for trailing null, fix by Ole Streicher + * + * Sep 23 2019 Increase header length default to 288000 = 100 blocks */ diff --git a/PyWCSTools/wcssubs-3.9.5/fitsfile.h b/PyWCSTools/wcssubs-3.9.7/fitsfile.h similarity index 89% rename from PyWCSTools/wcssubs-3.9.5/fitsfile.h rename to PyWCSTools/wcssubs-3.9.7/fitsfile.h index cd67f37..28f4817 100644 --- a/PyWCSTools/wcssubs-3.9.5/fitsfile.h +++ b/PyWCSTools/wcssubs-3.9.7/fitsfile.h @@ -1,8 +1,8 @@ /*** File fitsfile.h FITS and IRAF file access subroutines - *** June 20, 2014 + *** February 2, 2022 *** By Jessica Mink, jmink@cfa.harvard.edu *** Harvard-Smithsonian Center for Astrophysics - *** Copyright (C) 1996-2014 + *** Copyright (C) 1996-2022 *** Smithsonian Astrophysical Observatory, Cambridge, MA, USA This library is free software; you can redistribute it and/or @@ -60,6 +60,22 @@ struct Tokens { int itok; /* Current token number */ }; +/* Structure for dealing with ranges */ +#define MAXRANGE 20 +struct Range { + double first; /* Current minimum value */ + double last; /* Current maximum value */ + double step; /* Current step in value */ + double value; /* Current value */ + double valmin; /* Minimum value in all ranges */ + double valmax; /* Maximum value in all ranges */ + double ranges[MAXRANGE*3]; /* nranges sets of first, last, step */ + int nvalues; /* Total number of values in all ranges */ + int nranges; /* Number of ranges */ + int irange; /* Index of current range */ +}; + + #ifdef __cplusplus /* C++ prototypes */ extern "C" { #endif @@ -130,7 +146,6 @@ extern "C" { char *header); /* FITS image header */ /* FITS table file access subroutines in fitsfile.c */ - int fitsrtopen( /* Open FITS table file and fill structure with * pointers to selected keywords * Return file descriptor (-1 if unsuccessful) */ @@ -188,7 +203,6 @@ float ftgetr4( /* Extract column for keyword from FITS table line /* IRAF file access subroutines in imhfile.c */ - char *irafrhead( /* Read IRAF .imh header file and translate to FITS header */ char *filename, /* Name of IRAF header file */ int *lihead); /* Length of IRAF image header in bytes (returned) */ @@ -222,7 +236,6 @@ float ftgetr4( /* Extract column for keyword from FITS table line int *nbiraf); /* Length of returned IRAF header */ /* Image pixel access subroutines in imio.c */ - double getpix( /* Read one pixel from any data type 2-D array (0,0)*/ char *image, /* Image array as 1-D vector */ int bitpix, /* FITS bits per pixel @@ -321,7 +334,6 @@ float ftgetr4( /* Extract column for keyword from FITS table line int y2); /* One-based column for output pixel */ /* Image vector processing subroutines in imio.c */ - void addvec( /* Add constant to vector from 2-D array */ char *image, /* Image array as 1-D vector */ int bitpix, /* FITS bits per pixel */ @@ -372,7 +384,6 @@ float ftgetr4( /* Extract column for keyword from FITS table line double dpix); /* Value to which to set pixels */ /* Image pixel byte-swapping subroutines in imio.c */ - void imswap( /* Swap alternating bytes in a vector */ int bitpix, /* Number of bits per pixel */ char *string, /* Address of starting point of bytes to swap */ @@ -389,11 +400,15 @@ float ftgetr4( /* Extract column for keyword from FITS table line int imswapped(void); /* Return 1 if machine byte order is not FITS order */ /* File utilities from fileutil.c */ - int getfilelines( /* Return number of lines in an ASCII file */ char *filename); /* Name of file to check */ + int getmaxlength ( /* Return length of longest line in an ASCII file */ + char *filename); /* Name of file for which to find number of lines */ char *getfilebuff( /* Return entire file contents in a character string */ char *filename); /* Name of file to read */ + int putfilebuff( /* Return entire file contents in a character string */ + char *filename, /* Name of file to read */ + char *string); /* Character string to write */ int getfilesize( /* Return size of a binary or ASCII file */ char *filename); /* Name of file to check */ int isimlist( /* Return 1 if file is list of FITS or IRAF image files, else 0 */ @@ -427,6 +442,21 @@ float ftgetr4( /* Extract column for keyword from FITS table line char *spchar, /* Character with which to replace spaces */ char *string); /* Character string to process */ +/* Subroutines for dealing with ranges from fileutil.c */ + struct Range *RangeInit( /* Initialize range structure from string */ + char *string, /* String containing numbers separated by , and - */ + int ndef); /* Maximum allowable range value */ + int isrange( /* Return 1 if string is a range of numbers, else 0 */ + char *string); /* String which might be a range of numbers */ + void rstart( /* Restart range */ + struct Range *range); /* Range structure */ + int rgetn( /* Return number of values in all ranges */ + struct Range *range); /* Range structure */ + int rgeti4( /* Return next number in range as integer */ + struct Range *range); /* Range structure */ + double rgetr8( /* Return next number in range as double */ + struct Range *range); /* Range structure */ + /* Subroutines for access to tokens within a string from fileutil.c */ int setoken( /* Tokenize a string for easy decoding */ struct Tokens *tokens, /* Token structure returned */ @@ -445,10 +475,62 @@ float ftgetr4( /* Extract column for keyword from FITS table line char *token, /* token (returned) */ int maxchars); /* Maximum length of token */ +/* Subroutines to read values from keyword=value in blocks of text from fileutil.c */ + int agetl( /* Get nth LF- or CR-terminated line from an ASCII string */ + char *string, /* Character string containing = info */ + int iline, /* Sequential line to return with 0=first line */ + char *line, /* Line (returned) */ + int lline); /* Maximum length for line */ + int ageti4( /* Extract int value from keyword= value in string */ + char *string, /* character string containing = */ + char *keyword, /* character string containing the name of the keyword + * the value of which is returned. hget searches for a + * line beginning with this string. if "[n]" or ",n" is + * present, the n'th token in the value is returned. */ + int *ival); /* Integer value, returned */ + int agetr8( /* Extract double value from keyword= value in string */ + char *string, /* character string containing = */ + char *keyword, /* character string containing the name of the keyword */ + double *dval); /* Double value, returned */ + int agetw( /* Get first word of ASCII value from keyword=value */ + char *string, /* character string containing = */ + char *keyword, /* character string containing the name of the keyword + and the first word of the value is returned */ + char *word, /* First word of string value */ + int maxlength); /* Maximum number of characters in word */ + int agets( /* Extract value from keyword= value in string */ + char *string, /* character string containing = */ + char *keyword, /* character string containing the name of the keyword */ + int lval, /* Size of value in characters + * If negative, value ends at end of line */ + int fillblank, /* If 0, leave blanks, strip trailing blanks + if non-zero, replace blanks with underscores */ + char *value); /* String (returned) */ + +/* Subroutines for fitting and evaluating polynomials from fileutil.c */ + void polfit( /* Fit polynomial coefficients */ + double *x, /* Array of independent variable points */ + double *y, /* Array of dependent variable points */ + double x0, /* Offset to independent variable */ + int npts, /* Number of data points to fit */ + int nterms, /* Number of parameters to fit */ + double *a, /* Vector containing current fit values */ + double *stdev); /* Standard deviation of fit (returned) */ + double polcomp( /* Evaluate polynomial from polfit coefficients */ + double xi, /* Independent variable */ + double x0, /* Offset to independent variable */ + int norder, /* Number of coefficients */ + double *a); /* Vector containing coeffiecients */ + double determ ( /* Calculate the determinant of a square matrix + * This subprogram destroys the input matrix array + * From Bevington, page 294. */ + double *array, /* Input matrix array */ + int norder); /* Order of determinant (degree of matrix) */ + + /* Subroutines for translating dates and times in dateutil.c */ /* Subroutines to convert between floating point and vigesimal angles */ - void ang2hr ( /* Fractional degrees to hours as hh:mm:ss.ss */ double angle, /* Angle in fractional degrees */ int lstr, /* Maximum number of characters in string */ @@ -461,9 +543,14 @@ float ftgetr4( /* Extract column for keyword from FITS table line char *angle); /* Angle as dd:mm:ss.ss */ double hr2ang ( /* Hours as hh:mm:ss.ss to fractional degrees */ char *angle); /* Angle in sexigesimal hours (hh:mm:ss.sss) */ + double ang2sec ( /* Angle in fractional arcseconds */ + double angle); /* Angle in fractional degrees */ + double hr2sec ( /* Angle in fractional arcseconds */ + char *angle); /* Angle in sexigesimal hours (hh:mm:ss.sss) */ + double deg2sec ( /* Angle in fractional arcseconds */ + char *angle); /* Angle in sexigesimal degrees (dd:mm:ss.sss) */ /* Subroutines to convert from year and day of year */ - void doy2dt( /* Year and day of year to yyyy.mmdd hh.mmss */ int year, /* Year */ double doy, /* Day of year with fraction */ @@ -498,7 +585,6 @@ float ftgetr4( /* Extract column for keyword from FITS table line double doy); /* Day of year with fraction */ /* Subroutines to convert from date and time */ - void dt2doy( /* yyyy.mmdd hh.mmss to year and day of year */ double date, /* Date as yyyy.mmdd * yyyy = calendar year (e.g. 1973) @@ -551,7 +637,6 @@ float ftgetr4( /* Extract column for keyword from FITS table line double time); /* Time as hh.mmssxxxx */ /* Subroutines to convert from epoch (various types of fractional year) */ - void ep2dt( /* Fractional year to yyyy.mmdd hh.mmssss */ double epoch, /* Date as fractional year */ double *date, /* Date as yyyy.mmdd (returned) */ @@ -629,7 +714,6 @@ float ftgetr4( /* Extract column for keyword from FITS table line double epoch); /* Julian epoch (fractional 365.25-day years) */ /* Convert from FITS standard date string */ - void fd2dt( /* FITS standard date string to date and time */ char *string, /* FITS date string, which may be: * fractional year @@ -651,6 +735,8 @@ float ftgetr4( /* Extract column for keyword from FITS table line char *string); /* FITS date string */ char *fd2fd( /* Any FITS standard date string to ISO FITS date string */ char *string); /* FITS date string */ + char *fd2mfd( /* Any FITS standard date string to date string with month name*/ + char *string); /* FITS date string */ char *fd2of( /* Any FITS standard date string to old FITS date and time */ char *string); /* FITS date string */ char *fd2ofd( /* Any FITS standard date string to old FITS date string */ @@ -678,7 +764,6 @@ float ftgetr4( /* Extract column for keyword from FITS table line char *string); /* FITS date string */ /* Convert from Julian Day */ - void jd2doy( /* Julian Day to year and day of year */ double dj, /* Julian Day */ int *year, /* Year (returned) */ @@ -714,17 +799,16 @@ float ftgetr4( /* Extract column for keyword from FITS table line double dj); /* Julian Day */ /* Convert current local time to various formats */ - void lt2dt( /* Current local time to date (yyyy.mmdd), time (hh.mmsss) */ double *date, /* Date as yyyy.mmdd (returned) */ double *time); /* Time as hh.mmssxxxx (returned) */ char *lt2fd(void); /* Current local time to FITS ISO date string */ + char *lt2mfd(void); /* Current local time to FITS ISO date string with month name*/ int lt2tsi(void); /* Current local time to IRAF seconds since 1980-01-01T00:00 */ time_t lt2tsu(void); /* Current local time to Unix seconds since 1970-01-01T00:00 */ double lt2ts(void); /* Current local time to IRAF seconds since 1950-01-01T00:00 */ /* Convert from Modified Julian Day (JD - 2400000.5) */ - void mjd2doy( /* Modified Julian Day to year and day of year */ double dj, /* Modified Julian Day */ int *year, /* Year (returned) */ @@ -756,7 +840,6 @@ float ftgetr4( /* Extract column for keyword from FITS table line double dj); /* Modified Julian Date */ /* Convert from seconds since 1950-01-01 0:00 (JPL Ephemeris time) */ - void ts2dt( /* Seconds since 1950.0 to yyyy.mmdd hh.mmssss */ double tsec, /* seconds since 1950.0 */ double *date, /* Date as yyyy.mmdd (returned)*/ @@ -784,7 +867,6 @@ float ftgetr4( /* Extract column for keyword from FITS table line double tsec); /* seconds since 1950.0 */ /* Convert from IRAF time (seconds since 1980-01-01 0:00 UT) */ - char *tsi2fd( /* Seconds since 1980-01-01 to FITS standard date string */ int isec); /* Seconds past 1980-01-01 */ double tsi2ts( /* Seconds since 1980-01-01 to seconds since 1950-01-01 */ @@ -795,7 +877,6 @@ float ftgetr4( /* Extract column for keyword from FITS table line double *time); /* Time as hh.mmssxxxx (returned) */ /* Convert from Unix time (seconds since 1970-01-01 0:00 UT) */ - void tsu2dt( /* Seconds since 1970-01-01 to date yyyy.ddmm, time hh.mmsss */ time_t isec, /* Seconds past 1970-01-01 */ double *date, /* Date as yyyy.mmdd (returned) */ @@ -808,14 +889,12 @@ float ftgetr4( /* Extract column for keyword from FITS table line time_t isec); /* Seconds past 1970-01-01 */ /* Convert times within a day */ - char *tsd2fd( /* Seconds since start of day to FITS standard time string */ double tsec); /* Seconds since start of day */ double tsd2dt( /* Seconds since start of day to hh.mmsssss */ double tsec); /* Seconds since start of day */ /* Convert from current Universal Time */ - void ut2dt( /* Current Universal Time to date (yyyy.mmdd), time (hh.mmsss) */ double *date, /* Date as yyyy.mmdd (returned) */ double *time); /* Time as hh.mmssxxxx (returned) */ @@ -840,7 +919,6 @@ float ftgetr4( /* Extract column for keyword from FITS table line * yyyy-mm-ddThh:mm:ss.ss (FITS standard after 1999) */ /* Ephemeris time conversions (ET, TT, and TDT) */ - char *et2fd( /* ET (or TDT or TT) in FITS format to UT in FITS format */ char *string); /* Ephemeris Time as FITS date string (E not T) */ char *fd2et( /* UT in FITS format to ET (or TDT or TT) in FITS format */ @@ -1021,9 +1099,11 @@ extern void imswap4(); /* Reverse bytes in a vector of 4-byte numbers */ extern void imswap8(); /* Reverse bytes in a vector of 8-byte numbers */ extern int imswapped(); /* Return 1 if machine byte order is not FITS order */ + /* File utilities from fileutil.c */ extern int getfilelines(); extern char *getfilebuff(); +extern int putfilebuff(); extern int getfilesize(); extern int isimlist(); extern int isimlistd(); @@ -1035,19 +1115,40 @@ extern int isgif(); extern int next_line(); extern int first_token(); +/* Subroutines for dealing with ranges from fileutil.c */ +struct Range *RangeInit(); /* Initialize range structure from string */ +int isrange(); /* Return 1 if string is a range of numbers, else 0 */ +void rstart(); /* Restart range */ +int rgetn(); /* Return number of values in all ranges */ +int rgeti4(); /* Return next number in range as integer */ +double rgetr8(); /* Return next number in range as double */ + /* Subroutines for access to tokens within a string from fileutil.c */ -int setoken(); /* Tokenize a string for easy decoding */ -int nextoken(); /* Get next token from tokenized string */ -int getoken(); /* Get specified token from tokenized string */ +extern int setoken(); /* Tokenize a string for easy decoding */ +extern int nextoken(); /* Get next token from tokenized string */ +extern int getoken(); /* Get specified token from tokenized string */ -/* Subroutines for translating dates and times in dateutil.c */ +/* Subroutines to read values from keyword=value in blocks of text from fileutil.c */ +int agetl(); /* Get nth LF- or CR-terminated line from an ASCII string */ +int ageti4(); /* Extract int value from keyword= value in string */ +int agetr8(); /* Extract double value from keyword= value in string */ +int agetw(); /* Get first word of ASCII value from keyword=value */ +int agets(); /* Extract value from keyword= value in string */ + +/* Subroutines for fitting and evaluating polynomials from fileutil.c */ +void polfit(); /* Fit polynomial coefficients */ +double polcomp(); /* Evaluate polynomial from polfit coefficients */ +double determ(); /* Calculate the determinant of a square matrix */ + +/* Subroutines for translating dates and times in dateutil.c */ void ang2hr(); /* Fractional degrees to hours as hh:mm:ss.ss */ void ang2deg(); /* Fractional degrees to degrees as dd:mm:ss.ss */ double deg2ang(); /* Degrees as dd:mm:ss.ss to fractional degrees */ double hr2ang(); /* Hours as hh:mm:ss.ss to fractional degrees */ - -void doy2dt(); /* year and day of year to yyyy.mmdd hh.mmss */ +double ang2sec(); /* Angle as fractional degrees to fractional arcsec */ +double deg2sec(); /* Angle as dd:mm:ss.ss to fractional arcsec */ +double hr2sec(); /* Angle as hh:mm:ss.ss to fractional arcsec */ double doy2ep(); /* year and day of year to fractional year (epoch) */ double doy2epb(); /* year and day of year to Besselian epoch */ double doy2epj(); /* year and day of year to Julian epoch */ @@ -1290,4 +1391,13 @@ void compnut(); /* Compute nutation in longitude and obliquity and mean obliquit * Sep 25 2009 Add moveb() * * Jun 20 2014 Add next_line() + * + * Sep 24 2019 Add hr2sec(), deg2sec(), ang2sec() to convert to arcseconds + * + * Jun 11 2021 Add fd2mfd() to convert FITS date to ISO format with month name + * Aug 30 2021 Add getmaxlength() to return length of longest line in file + * + * Jan 21 2022 Add lt2mfd() to convert local time to ISO format with month name + * Jan 31 2022 Add putfilebuff(), aget*(), polynomial routines from fileutil.c + * Feb 2 2022 Add range subroutine declarations */ diff --git a/PyWCSTools/wcssubs-3.9.5/fitshead.h b/PyWCSTools/wcssubs-3.9.7/fitshead.h similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/fitshead.h rename to PyWCSTools/wcssubs-3.9.7/fitshead.h diff --git a/PyWCSTools/wcssubs-3.9.5/hget.c b/PyWCSTools/wcssubs-3.9.7/hget.c similarity index 99% rename from PyWCSTools/wcssubs-3.9.5/hget.c rename to PyWCSTools/wcssubs-3.9.7/hget.c index 22d834e..98b3d76 100644 --- a/PyWCSTools/wcssubs-3.9.5/hget.c +++ b/PyWCSTools/wcssubs-3.9.7/hget.c @@ -1,8 +1,8 @@ /*** File libwcs/hget.c - *** November 6, 2015 + *** September 23, 2019 *** By Jessica Mink, jmink@cfa.harvard.edu *** Harvard-Smithsonian Center for Astrophysics - *** Copyright (C) 1994-2015 + *** Copyright (C) 1994-2019 *** Smithsonian Astrophysical Observatory, Cambridge, MA, USA This library is free software; you can redistribute it and/or @@ -58,7 +58,7 @@ * Subroutine: strfix (string,blankfill,zerodrop) removes extraneous characters */ -#include /* NULL, strlen, strstr, strcpy */ +#include /* NULL, strlen, strstr, strcpy */ #include #include "fitshead.h" /* FITS header extraction subroutines */ #include @@ -69,6 +69,7 @@ #define SHRT_MAX 32767 #endif #define VLENGTH 81 +#define LHEAD0 288000 /* Maximum number of characters to search in header */ #ifdef USE_SAOLIB static int use_saolib=0; @@ -90,11 +91,15 @@ int lhead; /* Maximum length of FITS header */ char *hend; if (lhead > 0) lhead0 = lhead; - else { + + else if (lhead == 0) { lhead0 = 0; hend = ksearch (header,"END"); lhead0 = hend + 80 - header; } + else { + lhead0 = 0; + } return (lhead0); } @@ -1096,7 +1101,7 @@ const char *keyword; /* character string containing the name of the variable lhstr = lhead0; else { lhstr = 0; - while (lhstr < 256000 && hstring[lhstr] != 0) + while (lhstr < LHEAD0 && hstring[lhstr] != 0) lhstr++; } headlast = hstring + lhstr; @@ -1195,10 +1200,10 @@ const char *keyword; /* character string containing the name of the variable pval = 0; /* Find current length of header string */ - if (lhead0) + if (lhead0 > 0) lmax = lhead0; else - lmax = 256000; + lmax = LHEAD0; for (lhead = 0; lhead < lmax; lhead++) { if (hstring[lhead] <= (char) 0) break; @@ -1920,4 +1925,6 @@ int dropzero; /* If nonzero, drop trailing zeroes */ * Nov 6 2015 In isnum(), add return of 4 for yyyy-mm-dd dates * * Jun 9 2016 Fix isnum() tests for added coloned times and dashed dates + * + * Sep 23 2019 Add -1 argument to hlen() */ diff --git a/PyWCSTools/wcssubs-3.9.5/hput.c b/PyWCSTools/wcssubs-3.9.7/hput.c similarity index 99% rename from PyWCSTools/wcssubs-3.9.5/hput.c rename to PyWCSTools/wcssubs-3.9.7/hput.c index 7ec81ab..7412a42 100644 --- a/PyWCSTools/wcssubs-3.9.5/hput.c +++ b/PyWCSTools/wcssubs-3.9.7/hput.c @@ -1,8 +1,8 @@ /*** File libwcs/hput.c - *** September 9, 2011 + *** August 28, 2018 *** By Jessica Mink, jmink@cfa.harvard.edu *** Harvard-Smithsonian Center for Astrophysics - *** Copyright (C) 1995-2011 + *** Copyright (C) 1995-2018 *** Smithsonian Astrophysical Observatory, Cambridge, MA, USA This library is free software; you can redistribute it and/or @@ -544,9 +544,14 @@ const char *value; /* character string containing the value for variable strncpy (v1, keyword, lkeyword); /* Add parameter value in the appropriate place */ - vp = v1 + 8; + if (lkeyword < 9) + vp = v1 + 8; + else if (lkeyword < 28) + vp = v1 + 28; + else + vp = v1 + lkeyword; *vp = '='; - vp = v1 + 9; + vp = vp + 1; *vp = ' '; vp = vp + 1; if (*value == squot) { @@ -1313,4 +1318,6 @@ int ndec; /* Number of decimal places in degree string */ * Aug 22 2007 If closing quote not found, make one up * * Sep 9 2011 Always initialize q2 and lroot - */ + * + * Aug 28 2018 Allow arbitrary length keywords up to 64 characters +*/ diff --git a/PyWCSTools/wcssubs-3.9.5/iget.c b/PyWCSTools/wcssubs-3.9.7/iget.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/iget.c rename to PyWCSTools/wcssubs-3.9.7/iget.c diff --git a/PyWCSTools/wcssubs-3.9.5/imhfile.c b/PyWCSTools/wcssubs-3.9.7/imhfile.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/imhfile.c rename to PyWCSTools/wcssubs-3.9.7/imhfile.c diff --git a/PyWCSTools/wcssubs-3.9.5/imio.c b/PyWCSTools/wcssubs-3.9.7/imio.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/imio.c rename to PyWCSTools/wcssubs-3.9.7/imio.c diff --git a/PyWCSTools/wcssubs-3.9.5/imio.h b/PyWCSTools/wcssubs-3.9.7/imio.h similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/imio.h rename to PyWCSTools/wcssubs-3.9.7/imio.h diff --git a/PyWCSTools/wcssubs-3.9.5/lin.c b/PyWCSTools/wcssubs-3.9.7/lin.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/lin.c rename to PyWCSTools/wcssubs-3.9.7/lin.c diff --git a/PyWCSTools/wcssubs-3.9.5/platepos.c b/PyWCSTools/wcssubs-3.9.7/platepos.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/platepos.c rename to PyWCSTools/wcssubs-3.9.7/platepos.c diff --git a/PyWCSTools/wcssubs-3.9.5/poly.c b/PyWCSTools/wcssubs-3.9.7/poly.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/poly.c rename to PyWCSTools/wcssubs-3.9.7/poly.c diff --git a/PyWCSTools/wcssubs-3.9.5/proj.c b/PyWCSTools/wcssubs-3.9.7/proj.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/proj.c rename to PyWCSTools/wcssubs-3.9.7/proj.c diff --git a/PyWCSTools/wcssubs-3.9.5/sph.c b/PyWCSTools/wcssubs-3.9.7/sph.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/sph.c rename to PyWCSTools/wcssubs-3.9.7/sph.c diff --git a/PyWCSTools/wcssubs-3.9.5/tnxpos.c b/PyWCSTools/wcssubs-3.9.7/tnxpos.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/tnxpos.c rename to PyWCSTools/wcssubs-3.9.7/tnxpos.c diff --git a/PyWCSTools/wcssubs-3.9.5/wcs.c b/PyWCSTools/wcssubs-3.9.7/wcs.c similarity index 99% rename from PyWCSTools/wcssubs-3.9.5/wcs.c rename to PyWCSTools/wcssubs-3.9.7/wcs.c index 84cfb16..213de07 100644 --- a/PyWCSTools/wcssubs-3.9.5/wcs.c +++ b/PyWCSTools/wcssubs-3.9.7/wcs.c @@ -1,8 +1,8 @@ /*** File libwcs/wcs.c - *** June 24, 2016 + *** December 12, 2017 *** By Jessica Mink, jmink@cfa.harvard.edu *** Harvard-Smithsonian Center for Astrophysics - *** Copyright (C) 1994-2016 + *** Copyright (C) 1994-2017 *** Smithsonian Astrophysical Observatory, Cambridge, MA, USA This library is free software; you can redistribute it and/or @@ -150,6 +150,7 @@ char *proj; /* Projection */ { struct WorldCoor *wcs; double cdelt1, cdelt2; + int lproj; wcs = (struct WorldCoor *) calloc (1, sizeof(struct WorldCoor)); @@ -191,8 +192,11 @@ char *proj; /* Projection */ wcs->ptype[3] = (char) 0; strcpy (wcs->ctype[0],"RA---"); strcpy (wcs->ctype[1],"DEC--"); - strcat (wcs->ctype[0],proj); - strcat (wcs->ctype[1],proj); + lproj = strlen (proj); + if (lproj > 15) + lproj = 15; + strncat (wcs->ctype[0],proj, lproj); + strncat (wcs->ctype[1],proj, lproj); if (wcstype (wcs, wcs->ctype[0], wcs->ctype[1])) { wcsfree (wcs); @@ -346,6 +350,7 @@ char *ctype2; /* FITS WCS projection for axis 2 */ int nctype = NWCSTYPE; char ctypes[NWCSTYPE][4]; char dtypes[10][4]; + int lctype1; /* Initialize projection types */ strcpy (ctypes[0], "LIN"); @@ -389,7 +394,8 @@ char *ctype2; /* FITS WCS projection for axis 2 */ if (!strncmp (ctype1, "LONG",4)) strncpy (ctype1, "XLON",4); - strcpy (wcs->ctype[0], ctype1); + lctype1 = strlen (ctype1) + 1; + strncpy (wcs->ctype[0], ctype1, lctype1); /* This is only to catch special non-standard projections */ strncpy (wcs->ptype, ctype1, 3); @@ -2468,10 +2474,14 @@ struct WorldCoor *wcs; /* WCS parameter structure */ void setwcsfile (filename) char *filename; /* FITS or IRAF file with WCS */ -{ if (strlen (filename) < 256) - strcpy (wcsfile, filename); - else +{ + int lfn = strlen (filename) + 1; + if (lfn < 257) + strncpy (wcsfile, filename, lfn); + else { strncpy (wcsfile, filename, 255); + wcsfile[255] = (char) 0; + } return; } /* Set error message */ @@ -3015,4 +3025,6 @@ char *cwcs; /* Keyword suffix character for output WCS */ * Jun 8 2016 Increase ctype, ctype1, and ctype2 to 16 characters for distortion * Jun 23 2016 Set initial allocation of keyword arrays to MAXNKWD instead of 100 in cpwcs() * Jun 24 2016 wcs->ptype contains only 3-letter projection code + * + * Dec 12 2017 Change strcpy() to strncpy() where destination variable shorter than origin */ diff --git a/PyWCSTools/wcssubs-3.9.5/wcs.h b/PyWCSTools/wcssubs-3.9.7/wcs.h similarity index 99% rename from PyWCSTools/wcssubs-3.9.5/wcs.h rename to PyWCSTools/wcssubs-3.9.7/wcs.h index 0d69049..1005c3e 100644 --- a/PyWCSTools/wcssubs-3.9.5/wcs.h +++ b/PyWCSTools/wcssubs-3.9.7/wcs.h @@ -1,9 +1,7 @@ /*** File libwcs/wcs.h - *** June 23, 2016 - *** By Jessica Mink, jmink@cfa.harvard.edu - *** Harvard-Smithsonian Center for Astrophysics - *** Copyright (C) 1994-2016 - *** Smithsonian Astrophysical Observatory, Cambridge, MA, USA + *** February 1, 2022 + *** By Jessica Mink, SAO Telescope Data Center + *** Copyright (C) 1994-2022 This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public @@ -32,6 +30,7 @@ #include "wcslib.h" #include "fitshead.h" +#include "fitsfile.h" #define MAXNKWD 500 @@ -971,4 +970,8 @@ extern int zpxpix(); /* Inverse transform (world to physical) gnomonic projectio * * Jun 8 2016 Increase projection code from 9 to 16 characters for SIP distortion * Jun 23 2016 Set MAXNKWD here; used for copying keywords in cpwcs() + * + * Aug 2 2021 Add range, string-parsing, and polynomial-fitting subroutines from wcscat.h + * + * Feb 1 2022 Move range, string parsing, and polynomial-fitting subroutines to fitsfile.h */ diff --git a/PyWCSTools/wcssubs-3.9.5/wcs.i b/PyWCSTools/wcssubs-3.9.7/wcs.i similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/wcs.i rename to PyWCSTools/wcssubs-3.9.7/wcs.i diff --git a/PyWCSTools/wcssubs-3.9.5/wcs_wrap.c b/PyWCSTools/wcssubs-3.9.7/wcs_wrap.c similarity index 87% rename from PyWCSTools/wcssubs-3.9.5/wcs_wrap.c rename to PyWCSTools/wcssubs-3.9.7/wcs_wrap.c index 5741ef6..f17140a 100644 --- a/PyWCSTools/wcssubs-3.9.5/wcs_wrap.c +++ b/PyWCSTools/wcssubs-3.9.7/wcs_wrap.c @@ -1,18 +1,14 @@ /* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 4.0.2 + * This file was automatically generated by SWIG (https://www.swig.org). + * Version 4.2.1 * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. + * Do not make changes to this file unless you know what you are doing - modify + * the SWIG interface file instead. * ----------------------------------------------------------------------------- */ -#ifndef SWIGPYTHON +#define SWIG_VERSION 0x040201 #define SWIGPYTHON -#endif - #define SWIG_PYTHON_DIRECTOR_NO_VTABLE /* ----------------------------------------------------------------------------- @@ -139,14 +135,62 @@ # pragma warning disable 592 #endif +#if defined(__cplusplus) && __cplusplus >=201103L +# define SWIG_NULLPTR nullptr +#else +# define SWIG_NULLPTR NULL +#endif + +/* ----------------------------------------------------------------------------- + * swigcompat.swg + * + * Macros to provide support compatibility with older C and C++ standards. + * ----------------------------------------------------------------------------- */ + +/* C99 and C++11 should provide snprintf, but define SWIG_NO_SNPRINTF + * if you're missing it. + */ +#if ((defined __STDC_VERSION__ && __STDC_VERSION__ >= 199901L) || \ + (defined __cplusplus && __cplusplus >= 201103L) || \ + defined SWIG_HAVE_SNPRINTF) && \ + !defined SWIG_NO_SNPRINTF +# define SWIG_snprintf(O,S,F,A) snprintf(O,S,F,A) +# define SWIG_snprintf2(O,S,F,A,B) snprintf(O,S,F,A,B) +#else +/* Fallback versions ignore the buffer size, but most of our uses either have a + * fixed maximum possible size or dynamically allocate a buffer that's large + * enough. + */ +# define SWIG_snprintf(O,S,F,A) sprintf(O,F,A) +# define SWIG_snprintf2(O,S,F,A,B) sprintf(O,F,A,B) +#endif + #if defined(__GNUC__) && defined(_WIN32) && !defined(SWIG_PYTHON_NO_HYPOT_WORKAROUND) /* Workaround for '::hypot' has not been declared', see https://bugs.python.org/issue11566 */ # include #endif +#if !defined(PY_SSIZE_T_CLEAN) && !defined(SWIG_NO_PY_SSIZE_T_CLEAN) +#define PY_SSIZE_T_CLEAN +#endif + +#if __GNUC__ >= 7 +#pragma GCC diagnostic push +#if defined(__cplusplus) && __cplusplus >=201703L +#pragma GCC diagnostic ignored "-Wregister" /* For python-2.7 headers that use register */ +#endif +#endif + #if defined(_DEBUG) && defined(SWIG_PYTHON_INTERPRETER_NO_DEBUG) /* Use debug wrappers with the Python release dll */ + +#if defined(_MSC_VER) && _MSC_VER >= 1929 +/* Workaround compilation errors when redefining _DEBUG in MSVC 2019 version 16.10 and later + * See https://github.com/swig/swig/issues/2090 */ +# include +#endif + # undef _DEBUG # include # define _DEBUG 1 @@ -154,6 +198,12 @@ # include #endif +#if __GNUC__ >= 7 +#pragma GCC diagnostic pop +#endif + +#include + /* ----------------------------------------------------------------------------- * swigrun.swg * @@ -200,6 +250,8 @@ #define SWIG_POINTER_DISOWN 0x1 #define SWIG_CAST_NEW_MEMORY 0x2 #define SWIG_POINTER_NO_NULL 0x4 +#define SWIG_POINTER_CLEAR 0x8 +#define SWIG_POINTER_RELEASE (SWIG_POINTER_CLEAR | SWIG_POINTER_DISOWN) /* Flags for new pointer objects */ #define SWIG_POINTER_OWN 0x1 @@ -271,7 +323,7 @@ SWIG errors code. Finally, if the SWIG_CASTRANK_MODE is enabled, the result code - allows to return the 'cast rank', for example, if you have this + allows returning the 'cast rank', for example, if you have this int food(double) int fooi(int); @@ -285,7 +337,13 @@ */ #define SWIG_OK (0) +/* Runtime errors are < 0 */ #define SWIG_ERROR (-1) +/* Errors in range -1 to -99 are in swigerrors.swg (errors for all languages including those not using the runtime) */ +/* Errors in range -100 to -199 are language specific errors defined in *errors.swg */ +/* Errors < -200 are generic runtime specific errors */ +#define SWIG_ERROR_RELEASE_NOT_OWNED (-200) + #define SWIG_IsOK(r) (r >= 0) #define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError) @@ -293,14 +351,14 @@ #define SWIG_CASTRANKLIMIT (1 << 8) /* The NewMask denotes the object was created (using new/malloc) */ #define SWIG_NEWOBJMASK (SWIG_CASTRANKLIMIT << 1) -/* The TmpMask is for in/out typemaps that use temporal objects */ +/* The TmpMask is for in/out typemaps that use temporary objects */ #define SWIG_TMPOBJMASK (SWIG_NEWOBJMASK << 1) /* Simple returning values */ #define SWIG_BADOBJ (SWIG_ERROR) #define SWIG_OLDOBJ (SWIG_OK) #define SWIG_NEWOBJ (SWIG_OK | SWIG_NEWOBJMASK) #define SWIG_TMPOBJ (SWIG_OK | SWIG_TMPOBJMASK) -/* Check, add and del mask methods */ +/* Check, add and del object mask methods */ #define SWIG_AddNewMask(r) (SWIG_IsOK(r) ? (r | SWIG_NEWOBJMASK) : r) #define SWIG_DelNewMask(r) (SWIG_IsOK(r) ? (r & ~SWIG_NEWOBJMASK) : r) #define SWIG_IsNewObj(r) (SWIG_IsOK(r) && (r & SWIG_NEWOBJMASK)) @@ -446,7 +504,7 @@ SWIG_TypeCheck(const char *c, swig_type_info *ty) { Identical to SWIG_TypeCheck, except strcmp is replaced with a pointer comparison */ SWIGRUNTIME swig_cast_info * -SWIG_TypeCheckStruct(swig_type_info *from, swig_type_info *ty) { +SWIG_TypeCheckStruct(const swig_type_info *from, swig_type_info *ty) { if (ty) { swig_cast_info *iter = ty->cast; while (iter) { @@ -506,9 +564,9 @@ SWIG_TypeName(const swig_type_info *ty) { SWIGRUNTIME const char * SWIG_TypePrettyName(const swig_type_info *type) { /* The "str" field contains the equivalent pretty names of the - type, separated by vertical-bar characters. We choose - to print the last name, as it is often (?) the most - specific. */ + type, separated by vertical-bar characters. Choose the last + name. It should be the most specific; a fully resolved name + but not necessarily with default template parameters expanded. */ if (!type) return NULL; if (type->str != NULL) { const char *last_name = type->str; @@ -728,7 +786,7 @@ SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) { } #endif -/* Errors in SWIG */ +/* SWIG Errors applicable to all language modules, values are reserved from -1 to -99 */ #define SWIG_UnknownError -1 #define SWIG_IOError -2 #define SWIG_RuntimeError -3 @@ -744,7 +802,6 @@ SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) { #define SWIG_NullReferenceError -13 - /* Compatibility macros for Python 3 */ #if PY_VERSION_HEX >= 0x03000000 @@ -760,7 +817,6 @@ SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) { #define PyString_Size(str) PyBytes_Size(str) #define PyString_InternFromString(key) PyUnicode_InternFromString(key) #define Py_TPFLAGS_HAVE_CLASS Py_TPFLAGS_BASETYPE -#define PyString_AS_STRING(x) PyUnicode_AS_STRING(x) #define _PyLong_FromSsize_t(x) PyLong_FromSsize_t(x) #endif @@ -778,40 +834,29 @@ SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) { #endif -/* Warning: This function will allocate a new string in Python 3, - * so please call SWIG_Python_str_DelForPy3(x) to free the space. - */ -SWIGINTERN char* -SWIG_Python_str_AsChar(PyObject *str) +/* Wrapper around PyUnicode_AsUTF8AndSize - call Py_XDECREF on the returned pbytes when finished with the returned string */ +SWIGINTERN const char * +SWIG_PyUnicode_AsUTF8AndSize(PyObject *str, Py_ssize_t *psize, PyObject **pbytes) { #if PY_VERSION_HEX >= 0x03030000 - return (char *)PyUnicode_AsUTF8(str); -#elif PY_VERSION_HEX >= 0x03000000 - char *newstr = 0; - str = PyUnicode_AsUTF8String(str); - if (str) { - char *cstr; - Py_ssize_t len; - if (PyBytes_AsStringAndSize(str, &cstr, &len) != -1) { - newstr = (char *) malloc(len+1); - if (newstr) - memcpy(newstr, cstr, len+1); - } - Py_XDECREF(str); - } - return newstr; +# if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x030A0000 + *pbytes = NULL; + return PyUnicode_AsUTF8AndSize(str, psize); +# else + *pbytes = PyUnicode_AsUTF8String(str); + const char *chars = *pbytes ? PyBytes_AsString(*pbytes) : NULL; + if (chars && psize) + *psize = PyBytes_Size(*pbytes); + return chars; +# endif #else - return PyString_AsString(str); + char *chars = NULL; + *pbytes = NULL; + PyString_AsStringAndSize(str, &chars, psize); + return chars; #endif } -#if PY_VERSION_HEX >= 0x03030000 || PY_VERSION_HEX < 0x03000000 -# define SWIG_Python_str_DelForPy3(x) -#else -# define SWIG_Python_str_DelForPy3(x) free( (void*) (x) ) -#endif - - SWIGINTERN PyObject* SWIG_Python_str_FromChar(const char *c) { @@ -826,10 +871,14 @@ SWIG_Python_str_FromChar(const char *c) # define PyObject_DEL PyObject_Del #endif -// SWIGPY_USE_CAPSULE is no longer used within SWIG itself, but some user -// interface files check for it. +/* SWIGPY_USE_CAPSULE is no longer used within SWIG itself, but some user interface files check for it. */ # define SWIGPY_USE_CAPSULE -# define SWIGPY_CAPSULE_NAME ("swig_runtime_data" SWIG_RUNTIME_VERSION ".type_pointer_capsule" SWIG_TYPE_TABLE_NAME) +#ifdef SWIGPYTHON_BUILTIN +# define SWIGPY_CAPSULE_ATTR_NAME "type_pointer_capsule_builtin" SWIG_TYPE_TABLE_NAME +#else +# define SWIGPY_CAPSULE_ATTR_NAME "type_pointer_capsule" SWIG_TYPE_TABLE_NAME +#endif +# define SWIGPY_CAPSULE_NAME ("swig_runtime_data" SWIG_RUNTIME_VERSION "." SWIGPY_CAPSULE_ATTR_NAME) #if PY_VERSION_HEX < 0x03020000 #define PyDescr_TYPE(x) (((PyDescrObject *)(x))->d_type) @@ -837,6 +886,20 @@ SWIG_Python_str_FromChar(const char *c) #define Py_hash_t long #endif +#ifdef Py_LIMITED_API +# define PyTuple_GET_ITEM PyTuple_GetItem +/* Note that PyTuple_SetItem() has different semantics from PyTuple_SET_ITEM as it decref's the original tuple item, so in general they cannot be used + interchangeably. However in SWIG-generated code PyTuple_SET_ITEM is only used with newly initialized tuples without any items and for them this does work. */ +# define PyTuple_SET_ITEM PyTuple_SetItem +# define PyTuple_GET_SIZE PyTuple_Size +# define PyCFunction_GET_FLAGS PyCFunction_GetFlags +# define PyCFunction_GET_FUNCTION PyCFunction_GetFunction +# define PyCFunction_GET_SELF PyCFunction_GetSelf +# define PyList_GET_ITEM PyList_GetItem +# define PyList_SET_ITEM PyList_SetItem +# define PySliceObject PyObject +#endif + /* ----------------------------------------------------------------------------- * error manipulation * ----------------------------------------------------------------------------- */ @@ -896,14 +959,15 @@ SWIG_Python_AddErrorMsg(const char* mesg) PyErr_Fetch(&type, &value, &traceback); if (value) { PyObject *old_str = PyObject_Str(value); - const char *tmp = SWIG_Python_str_AsChar(old_str); + PyObject *bytes = NULL; + const char *tmp = SWIG_PyUnicode_AsUTF8AndSize(old_str, NULL, &bytes); PyErr_Clear(); Py_XINCREF(type); if (tmp) PyErr_Format(type, "%s %s", tmp, mesg); else PyErr_Format(type, "%s", mesg); - SWIG_Python_str_DelForPy3(tmp); + Py_XDECREF(bytes); Py_DECREF(old_str); Py_DECREF(value); } else { @@ -934,8 +998,12 @@ SWIG_Python_RaiseOrModifyTypeError(const char *message) #else newvalue = PyString_FromFormat("%s\nAdditional information:\n%s", PyString_AsString(value), message); #endif - Py_XDECREF(value); - PyErr_Restore(type, newvalue, traceback); + if (newvalue) { + Py_XDECREF(value); + PyErr_Restore(type, newvalue, traceback); + } else { + PyErr_Restore(type, value, traceback); + } } else { /* Raise TypeError using given message */ PyErr_SetString(PyExc_TypeError, message); @@ -952,8 +1020,12 @@ SWIG_Python_RaiseOrModifyTypeError(const char *message) # define SWIG_PYTHON_USE_GIL # endif # if defined(SWIG_PYTHON_USE_GIL) /* Use PyGILState threads calls */ -# ifndef SWIG_PYTHON_INITIALIZE_THREADS -# define SWIG_PYTHON_INITIALIZE_THREADS PyEval_InitThreads() +# if !defined(SWIG_PYTHON_INITIALIZE_THREADS) +# if PY_VERSION_HEX < 0x03070000 +# define SWIG_PYTHON_INITIALIZE_THREADS PyEval_InitThreads() +# else +# define SWIG_PYTHON_INITIALIZE_THREADS +# endif # endif # ifdef __cplusplus /* C++ code */ class SWIG_Python_Thread_Block { @@ -968,7 +1040,7 @@ SWIG_Python_RaiseOrModifyTypeError(const char *message) bool status; PyThreadState *save; public: - void end() { if (status) { PyEval_RestoreThread(save); status = false; }} + void end() { if (status) { status = false; PyEval_RestoreThread(save); }} SWIG_Python_Thread_Allow() : status(true), save(PyEval_SaveThread()) {} ~SWIG_Python_Thread_Allow() { end(); } }; @@ -1051,8 +1123,8 @@ typedef struct swig_const_info { # error "This version of SWIG only supports Python >= 2.7" #endif -#if PY_VERSION_HEX >= 0x03000000 && PY_VERSION_HEX < 0x03020000 -# error "This version of SWIG only supports Python 3 >= 3.2" +#if PY_VERSION_HEX >= 0x03000000 && PY_VERSION_HEX < 0x03030000 +# error "This version of SWIG only supports Python 3 >= 3.3" #endif /* Common SWIG API */ @@ -1167,7 +1239,12 @@ SWIG_Python_AppendOutput(PyObject* result, PyObject* obj) { if (!PyList_Check(result)) { PyObject *o2 = result; result = PyList_New(1); - PyList_SetItem(result, 0, o2); + if (result) { + PyList_SET_ITEM(result, 0, o2); + } else { + Py_DECREF(obj); + return o2; + } } PyList_Append(result,obj); Py_DECREF(obj); @@ -1249,6 +1326,261 @@ SWIG_Python_CheckNoKeywords(PyObject *kwargs, const char *name) { #define SWIG_STATIC_POINTER(var) var = 0; if (!var) var #endif +#ifdef __cplusplus +extern "C" { +#endif + +/* Python-specific SWIG API */ +#define SWIG_newvarlink() SWIG_Python_newvarlink() +#define SWIG_addvarlink(p, name, get_attr, set_attr) SWIG_Python_addvarlink(p, name, get_attr, set_attr) +#define SWIG_InstallConstants(d, constants) SWIG_Python_InstallConstants(d, constants) + +/* ----------------------------------------------------------------------------- + * global variable support code. + * ----------------------------------------------------------------------------- */ + +typedef struct swig_globalvar { + char *name; /* Name of global variable */ + PyObject *(*get_attr)(void); /* Return the current value */ + int (*set_attr)(PyObject *); /* Set the value */ + struct swig_globalvar *next; +} swig_globalvar; + +typedef struct swig_varlinkobject { + PyObject_HEAD + swig_globalvar *vars; +} swig_varlinkobject; + +SWIGINTERN PyObject * +swig_varlink_repr(PyObject *SWIGUNUSEDPARM(v)) { +#if PY_VERSION_HEX >= 0x03000000 + return PyUnicode_InternFromString(""); +#else + return PyString_FromString(""); +#endif +} + +SWIGINTERN PyObject * +swig_varlink_str(PyObject *o) { + swig_varlinkobject *v = (swig_varlinkobject *) o; +#if PY_VERSION_HEX >= 0x03000000 + PyObject *str = PyUnicode_InternFromString("("); + PyObject *tail; + PyObject *joined; + swig_globalvar *var; + for (var = v->vars; var; var=var->next) { + tail = PyUnicode_FromString(var->name); + joined = PyUnicode_Concat(str, tail); + Py_DecRef(str); + Py_DecRef(tail); + str = joined; + if (var->next) { + tail = PyUnicode_InternFromString(", "); + joined = PyUnicode_Concat(str, tail); + Py_DecRef(str); + Py_DecRef(tail); + str = joined; + } + } + tail = PyUnicode_InternFromString(")"); + joined = PyUnicode_Concat(str, tail); + Py_DecRef(str); + Py_DecRef(tail); + str = joined; +#else + PyObject *str = PyString_FromString("("); + swig_globalvar *var; + for (var = v->vars; var; var=var->next) { + PyString_ConcatAndDel(&str,PyString_FromString(var->name)); + if (var->next) PyString_ConcatAndDel(&str,PyString_FromString(", ")); + } + PyString_ConcatAndDel(&str,PyString_FromString(")")); +#endif + return str; +} + +SWIGINTERN void +swig_varlink_dealloc(PyObject *o) { + swig_varlinkobject *v = (swig_varlinkobject *) o; + swig_globalvar *var = v->vars; + while (var) { + swig_globalvar *n = var->next; + free(var->name); + free(var); + var = n; + } +} + +SWIGINTERN PyObject * +swig_varlink_getattr(PyObject *o, char *n) { + swig_varlinkobject *v = (swig_varlinkobject *) o; + PyObject *res = NULL; + swig_globalvar *var = v->vars; + while (var) { + if (strcmp(var->name,n) == 0) { + res = (*var->get_attr)(); + break; + } + var = var->next; + } + if (res == NULL && !PyErr_Occurred()) { + PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n); + } + return res; +} + +SWIGINTERN int +swig_varlink_setattr(PyObject *o, char *n, PyObject *p) { + swig_varlinkobject *v = (swig_varlinkobject *) o; + int res = 1; + swig_globalvar *var = v->vars; + while (var) { + if (strcmp(var->name,n) == 0) { + res = (*var->set_attr)(p); + break; + } + var = var->next; + } + if (res == 1 && !PyErr_Occurred()) { + PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n); + } + return res; +} + +SWIGINTERN PyTypeObject* +swig_varlink_type(void) { + static char varlink__doc__[] = "Swig var link object"; +#ifndef Py_LIMITED_API + static PyTypeObject varlink_type; + static int type_init = 0; + if (!type_init) { + const PyTypeObject tmp = { +#if PY_VERSION_HEX >= 0x03000000 + PyVarObject_HEAD_INIT(NULL, 0) +#else + PyObject_HEAD_INIT(NULL) + 0, /* ob_size */ +#endif + "swigvarlink", /* tp_name */ + sizeof(swig_varlinkobject), /* tp_basicsize */ + 0, /* tp_itemsize */ + (destructor) swig_varlink_dealloc, /* tp_dealloc */ +#if PY_VERSION_HEX < 0x030800b4 + (printfunc)0, /*tp_print*/ +#else + (Py_ssize_t)0, /*tp_vectorcall_offset*/ +#endif + (getattrfunc) swig_varlink_getattr, /* tp_getattr */ + (setattrfunc) swig_varlink_setattr, /* tp_setattr */ + 0, /* tp_compare */ + (reprfunc) swig_varlink_repr, /* tp_repr */ + 0, /* tp_as_number */ + 0, /* tp_as_sequence */ + 0, /* tp_as_mapping */ + 0, /* tp_hash */ + 0, /* tp_call */ + (reprfunc) swig_varlink_str, /* tp_str */ + 0, /* tp_getattro */ + 0, /* tp_setattro */ + 0, /* tp_as_buffer */ + 0, /* tp_flags */ + varlink__doc__, /* tp_doc */ + 0, /* tp_traverse */ + 0, /* tp_clear */ + 0, /* tp_richcompare */ + 0, /* tp_weaklistoffset */ + 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* tp_iter -> tp_weaklist */ + 0, /* tp_del */ + 0, /* tp_version_tag */ +#if PY_VERSION_HEX >= 0x03040000 + 0, /* tp_finalize */ +#endif +#if PY_VERSION_HEX >= 0x03080000 + 0, /* tp_vectorcall */ +#endif +#if (PY_VERSION_HEX >= 0x03080000) && (PY_VERSION_HEX < 0x03090000) + 0, /* tp_print */ +#endif +#if PY_VERSION_HEX >= 0x030C0000 + 0, /* tp_watched */ +#endif +#ifdef COUNT_ALLOCS + 0, /* tp_allocs */ + 0, /* tp_frees */ + 0, /* tp_maxalloc */ + 0, /* tp_prev */ + 0 /* tp_next */ +#endif + }; + varlink_type = tmp; + type_init = 1; + if (PyType_Ready(&varlink_type) < 0) + return NULL; + } + return &varlink_type; +#else + PyType_Slot slots[] = { + { Py_tp_dealloc, (void *)swig_varlink_dealloc }, + { Py_tp_repr, (void *)swig_varlink_repr }, + { Py_tp_getattr, (void *)swig_varlink_getattr }, + { Py_tp_setattr, (void *)swig_varlink_setattr }, + { Py_tp_str, (void *)swig_varlink_str }, + { Py_tp_doc, (void *)varlink__doc__ }, + { 0, NULL } + }; + PyType_Spec spec = { + "swigvarlink", + sizeof(swig_varlinkobject), + 0, + Py_TPFLAGS_DEFAULT, + slots + }; + return (PyTypeObject *)PyType_FromSpec(&spec); +#endif +} + +/* Create a variable linking object for use later */ +SWIGINTERN PyObject * +SWIG_Python_newvarlink(void) { + swig_varlinkobject *result = PyObject_New(swig_varlinkobject, swig_varlink_type()); + if (result) { + result->vars = 0; + } + return ((PyObject*) result); +} + +SWIGINTERN void +SWIG_Python_addvarlink(PyObject *p, const char *name, PyObject *(*get_attr)(void), int (*set_attr)(PyObject *p)) { + swig_varlinkobject *v = (swig_varlinkobject *) p; + swig_globalvar *gv = (swig_globalvar *) malloc(sizeof(swig_globalvar)); + if (gv) { + size_t size = strlen(name)+1; + gv->name = (char *)malloc(size); + if (gv->name) { + memcpy(gv->name, name, size); + gv->get_attr = get_attr; + gv->set_attr = set_attr; + gv->next = v->vars; + } + } + v->vars = gv; +} + + +static PyObject *Swig_Globals_global = NULL; + +SWIGINTERN PyObject * +SWIG_globals(void) { + if (Swig_Globals_global == NULL) { + Swig_Globals_global = SWIG_newvarlink(); + } + return Swig_Globals_global; +} + +#ifdef __cplusplus +} +#endif + /* ----------------------------------------------------------------------------- * Pointer declarations * ----------------------------------------------------------------------------- */ @@ -1319,18 +1651,25 @@ SwigPyClientData_New(PyObject* obj) /* the newraw method and newargs arguments used to create a new raw instance */ if (PyClass_Check(obj)) { data->newraw = 0; - data->newargs = obj; Py_INCREF(obj); + data->newargs = obj; } else { data->newraw = PyObject_GetAttrString(data->klass, "__new__"); if (data->newraw) { - Py_INCREF(data->newraw); - data->newargs = PyTuple_New(1); - PyTuple_SetItem(data->newargs, 0, obj); + data->newargs = PyTuple_New(1); + if (data->newargs) { + Py_INCREF(obj); + PyTuple_SET_ITEM(data->newargs, 0, obj); + } else { + Py_DECREF(data->newraw); + Py_DECREF(data->klass); + free(data); + return 0; + } } else { - data->newargs = obj; + Py_INCREF(obj); + data->newargs = obj; } - Py_INCREF(data->newargs); } /* the destroy method, aka as the C++ delete method */ data->destroy = PyObject_GetAttrString(data->klass, "__swig_destroy__"); @@ -1339,10 +1678,7 @@ SwigPyClientData_New(PyObject* obj) data->destroy = 0; } if (data->destroy) { - int flags; - Py_INCREF(data->destroy); - flags = PyCFunction_GET_FLAGS(data->destroy); - data->delargs = !(flags & (METH_O)); + data->delargs = !(PyCFunction_GET_FLAGS(data->destroy) & METH_O); } else { data->delargs = 0; } @@ -1353,10 +1689,13 @@ SwigPyClientData_New(PyObject* obj) } SWIGRUNTIME void -SwigPyClientData_Del(SwigPyClientData *data) { +SwigPyClientData_Del(SwigPyClientData *data) +{ + Py_XDECREF(data->klass); Py_XDECREF(data->newraw); Py_XDECREF(data->newargs); Py_XDECREF(data->destroy); + free(data); } /* =============== SwigPyObject =====================*/ @@ -1383,7 +1722,7 @@ SwigPyObject_get___dict__(PyObject *v, PyObject *SWIGUNUSEDPARM(args)) if (!sobj->dict) sobj->dict = PyDict_New(); - Py_INCREF(sobj->dict); + Py_XINCREF(sobj->dict); return sobj->dict; } @@ -1401,18 +1740,21 @@ SwigPyObject_format(const char* fmt, SwigPyObject *v) PyObject *res = NULL; PyObject *args = PyTuple_New(1); if (args) { - if (PyTuple_SetItem(args, 0, SwigPyObject_long(v)) == 0) { - PyObject *ofmt = SWIG_Python_str_FromChar(fmt); + PyObject *val = SwigPyObject_long(v); + if (val) { + PyObject *ofmt; + PyTuple_SET_ITEM(args, 0, val); + ofmt = SWIG_Python_str_FromChar(fmt); if (ofmt) { #if PY_VERSION_HEX >= 0x03000000 - res = PyUnicode_Format(ofmt,args); + res = PyUnicode_Format(ofmt,args); #else - res = PyString_Format(ofmt,args); + res = PyString_Format(ofmt,args); #endif - Py_DECREF(ofmt); + Py_DECREF(ofmt); } - Py_DECREF(args); } + Py_DECREF(args); } return res; } @@ -1434,18 +1776,23 @@ SwigPyObject_repr(SwigPyObject *v) { const char *name = SWIG_TypePrettyName(v->ty); PyObject *repr = SWIG_Python_str_FromFormat("", (name ? name : "unknown"), (void *)v); - if (v->next) { + if (repr && v->next) { PyObject *nrep = SwigPyObject_repr((SwigPyObject *)v->next); + if (nrep) { # if PY_VERSION_HEX >= 0x03000000 - PyObject *joined = PyUnicode_Concat(repr, nrep); - Py_DecRef(repr); - Py_DecRef(nrep); - repr = joined; + PyObject *joined = PyUnicode_Concat(repr, nrep); + Py_DecRef(repr); + Py_DecRef(nrep); + repr = joined; # else - PyString_ConcatAndDel(&repr,nrep); + PyString_ConcatAndDel(&repr,nrep); # endif + } else { + Py_DecRef(repr); + repr = NULL; + } } - return repr; + return repr; } /* We need a version taking two PyObject* parameters so it's a valid @@ -1468,12 +1815,14 @@ SwigPyObject_compare(SwigPyObject *v, SwigPyObject *w) SWIGRUNTIME PyObject* SwigPyObject_richcompare(SwigPyObject *v, SwigPyObject *w, int op) { - PyObject* res; - if( op != Py_EQ && op != Py_NE ) { - Py_INCREF(Py_NotImplemented); - return Py_NotImplemented; + PyObject* res = NULL; + if (!PyErr_Occurred()) { + if (op != Py_EQ && op != Py_NE) { + Py_INCREF(Py_NotImplemented); + return Py_NotImplemented; + } + res = PyBool_FromLong( (SwigPyObject_compare(v, w)==0) == (op == Py_EQ) ? 1 : 0); } - res = PyBool_FromLong( (SwigPyObject_compare(v, w)==0) == (op == Py_EQ) ? 1 : 0); return res; } @@ -1501,20 +1850,34 @@ SwigPyObject_type(void) { SWIGRUNTIMEINLINE int SwigPyObject_Check(PyObject *op) { -#ifdef SWIGPYTHON_BUILTIN PyTypeObject *target_tp = SwigPyObject_type(); - if (PyType_IsSubtype(op->ob_type, target_tp)) + PyTypeObject *op_type = Py_TYPE(op); +#ifdef SWIGPYTHON_BUILTIN + if (PyType_IsSubtype(op_type, target_tp)) return 1; - return (strcmp(op->ob_type->tp_name, "SwigPyObject") == 0); + return (strcmp(op_type->tp_name, "SwigPyObject") == 0); #else - return (Py_TYPE(op) == SwigPyObject_type()) - || (strcmp(Py_TYPE(op)->tp_name,"SwigPyObject") == 0); + if (op_type == target_tp) + return 1; +# ifdef Py_LIMITED_API + int cmp; + PyObject *tp_name = PyObject_GetAttrString((PyObject *)op_type, "__name__"); + if (!tp_name) + return 0; + cmp = PyUnicode_CompareWithASCIIString(tp_name, "SwigPyObject"); + Py_DECREF(tp_name); + return cmp == 0; +# else + return (strcmp(op_type->tp_name, "SwigPyObject") == 0); +# endif #endif } SWIGRUNTIME PyObject * SwigPyObject_New(void *ptr, swig_type_info *ty, int own); +static PyObject* Swig_Capsule_global = NULL; + SWIGRUNTIME void SwigPyObject_dealloc(PyObject *v) { @@ -1541,8 +1904,12 @@ SwigPyObject_dealloc(PyObject *v) if (data->delargs) { /* we need to create a temporary object to carry the destroy operation */ PyObject *tmp = SwigPyObject_New(sobj->ptr, ty, 0); - res = SWIG_Python_CallFunctor(destroy, tmp); - Py_DECREF(tmp); + if (tmp) { + res = SWIG_Python_CallFunctor(destroy, tmp); + } else { + res = 0; + } + Py_XDECREF(tmp); } else { PyCFunction meth = PyCFunction_GET_FUNCTION(destroy); PyObject *mself = PyCFunction_GET_SELF(destroy); @@ -1561,8 +1928,12 @@ SwigPyObject_dealloc(PyObject *v) printf("swig/python detected a memory leak of type '%s', no destructor found.\n", (name ? name : "unknown")); } #endif - } + Py_XDECREF(Swig_Capsule_global); + } Py_XDECREF(next); +#ifdef SWIGPYTHON_BUILTIN + Py_XDECREF(sobj->dict); +#endif PyObject_DEL(v); } @@ -1574,6 +1945,7 @@ SwigPyObject_append(PyObject* v, PyObject* next) PyErr_SetString(PyExc_TypeError, "Attempt to append a non SwigPyObject"); return NULL; } + ((SwigPyObject *)next)->next = sobj->next; sobj->next = next; Py_INCREF(next); return SWIG_Py_Void(); @@ -1618,9 +1990,9 @@ SwigPyObject_own(PyObject *v, PyObject *args) PyObject *obj = PyBool_FromLong(sobj->own); if (val) { if (PyObject_IsTrue(val)) { - SwigPyObject_acquire(v,args); + Py_DECREF(SwigPyObject_acquire(v,args)); } else { - SwigPyObject_disown(v,args); + Py_DECREF(SwigPyObject_disown(v,args)); } } return obj; @@ -1641,7 +2013,7 @@ swigobject_methods[] = { SWIGRUNTIME PyTypeObject* SwigPyObject_TypeOnce(void) { static char swigobject_doc[] = "Swig object carries a C/C++ instance pointer"; - +#ifndef Py_LIMITED_API static PyNumberMethods SwigPyObject_as_number = { (binaryfunc)0, /*nb_add*/ (binaryfunc)0, /*nb_subtract*/ @@ -1700,7 +2072,11 @@ SwigPyObject_TypeOnce(void) { sizeof(SwigPyObject), /* tp_basicsize */ 0, /* tp_itemsize */ (destructor)SwigPyObject_dealloc, /* tp_dealloc */ - 0, /* tp_print */ +#if PY_VERSION_HEX < 0x030800b4 + (printfunc)0, /*tp_print*/ +#else + (Py_ssize_t)0, /*tp_vectorcall_offset*/ +#endif (getattrfunc)0, /* tp_getattr */ (setattrfunc)0, /* tp_setattr */ #if PY_VERSION_HEX >= 0x03000000 @@ -1755,6 +2131,9 @@ SwigPyObject_TypeOnce(void) { #if (PY_VERSION_HEX >= 0x03080000) && (PY_VERSION_HEX < 0x03090000) 0, /* tp_print */ #endif +#if PY_VERSION_HEX >= 0x030C0000 + 0, /* tp_watched */ +#endif #ifdef COUNT_ALLOCS 0, /* tp_allocs */ 0, /* tp_frees */ @@ -1765,21 +2144,50 @@ SwigPyObject_TypeOnce(void) { }; swigpyobject_type = tmp; type_init = 1; - if (PyType_Ready(&swigpyobject_type) < 0) + if (PyType_Ready(&swigpyobject_type) != 0) return NULL; } return &swigpyobject_type; +#else + PyType_Slot slots[] = { + { Py_tp_dealloc, (void *)SwigPyObject_dealloc }, + { Py_tp_repr, (void *)SwigPyObject_repr }, + { Py_tp_getattro, (void *)PyObject_GenericGetAttr }, + { Py_tp_doc, (void *)swigobject_doc }, + { Py_tp_richcompare, (void *)SwigPyObject_richcompare }, + { Py_tp_methods, (void *)swigobject_methods }, + { Py_nb_int, (void *)SwigPyObject_long }, + { 0, NULL } + }; + PyType_Spec spec = { + "SwigPyObject", + sizeof(SwigPyObject), + 0, + Py_TPFLAGS_DEFAULT, + slots + }; + return (PyTypeObject *)PyType_FromSpec(&spec); +#endif } SWIGRUNTIME PyObject * SwigPyObject_New(void *ptr, swig_type_info *ty, int own) { - SwigPyObject *sobj = PyObject_NEW(SwigPyObject, SwigPyObject_type()); + SwigPyObject *sobj = PyObject_New(SwigPyObject, SwigPyObject_type()); if (sobj) { sobj->ptr = ptr; sobj->ty = ty; sobj->own = own; sobj->next = 0; +#ifdef SWIGPYTHON_BUILTIN + sobj->dict = 0; +#endif + if (own == SWIG_POINTER_OWN) { + /* Obtain a reference to the Python capsule wrapping the module information, so that the + * module information is correctly destroyed after all SWIG python objects have been freed + * by the GC (and corresponding destructors invoked) */ + Py_XINCREF(Swig_Capsule_global); + } } return (PyObject *)sobj; } @@ -1836,8 +2244,20 @@ SwigPyPacked_type(void) { SWIGRUNTIMEINLINE int SwigPyPacked_Check(PyObject *op) { - return ((op)->ob_type == SwigPyPacked_TypeOnce()) - || (strcmp((op)->ob_type->tp_name,"SwigPyPacked") == 0); + PyTypeObject* op_type = Py_TYPE(op); + if (op_type == SwigPyPacked_TypeOnce()) + return 1; +#ifdef Py_LIMITED_API + int cmp; + PyObject *tp_name = PyObject_GetAttrString((PyObject *)op_type, "__name__"); + if (!tp_name) + return 0; + cmp = PyUnicode_CompareWithASCIIString(tp_name, "SwigPyPacked"); + Py_DECREF(tp_name); + return cmp == 0; +#else + return (strcmp(op_type->tp_name, "SwigPyPacked") == 0); +#endif } SWIGRUNTIME void @@ -1853,6 +2273,7 @@ SwigPyPacked_dealloc(PyObject *v) SWIGRUNTIME PyTypeObject* SwigPyPacked_TypeOnce(void) { static char swigpacked_doc[] = "Swig object carries a C/C++ instance pointer"; +#ifndef Py_LIMITED_API static PyTypeObject swigpypacked_type; static int type_init = 0; if (!type_init) { @@ -1867,7 +2288,11 @@ SwigPyPacked_TypeOnce(void) { sizeof(SwigPyPacked), /* tp_basicsize */ 0, /* tp_itemsize */ (destructor)SwigPyPacked_dealloc, /* tp_dealloc */ - 0, /* tp_print */ +#if PY_VERSION_HEX < 0x030800b4 + (printfunc)0, /*tp_print*/ +#else + (Py_ssize_t)0, /*tp_vectorcall_offset*/ +#endif (getattrfunc)0, /* tp_getattr */ (setattrfunc)0, /* tp_setattr */ #if PY_VERSION_HEX>=0x03000000 @@ -1922,6 +2347,9 @@ SwigPyPacked_TypeOnce(void) { #if (PY_VERSION_HEX >= 0x03080000) && (PY_VERSION_HEX < 0x03090000) 0, /* tp_print */ #endif +#if PY_VERSION_HEX >= 0x030C0000 + 0, /* tp_watched */ +#endif #ifdef COUNT_ALLOCS 0, /* tp_allocs */ 0, /* tp_frees */ @@ -1932,16 +2360,34 @@ SwigPyPacked_TypeOnce(void) { }; swigpypacked_type = tmp; type_init = 1; - if (PyType_Ready(&swigpypacked_type) < 0) + if (PyType_Ready(&swigpypacked_type) != 0) return NULL; } return &swigpypacked_type; +#else + PyType_Slot slots[] = { + { Py_tp_dealloc, (void *)SwigPyPacked_dealloc }, + { Py_tp_repr, (void *)SwigPyPacked_repr }, + { Py_tp_str, (void *)SwigPyPacked_str }, + { Py_tp_getattro, (void *)PyObject_GenericGetAttr }, + { Py_tp_doc, (void *)swigpacked_doc }, + { 0, NULL } + }; + PyType_Spec spec = { + "SwigPyPacked", + sizeof(SwigPyPacked), + 0, + Py_TPFLAGS_DEFAULT, + slots + }; + return (PyTypeObject *)PyType_FromSpec(&spec); +#endif } SWIGRUNTIME PyObject * SwigPyPacked_New(void *ptr, size_t size, swig_type_info *ty) { - SwigPyPacked *sobj = PyObject_NEW(SwigPyPacked, SwigPyPacked_type()); + SwigPyPacked *sobj = PyObject_New(SwigPyPacked, SwigPyPacked_type()); if (sobj) { void *pack = malloc(size); if (pack) { @@ -2122,12 +2568,19 @@ SWIG_Python_ConvertPtrAndOwn(PyObject *obj, void **ptr, swig_type_info *ty, int } } if (sobj) { - if (own) - *own = *own | sobj->own; - if (flags & SWIG_POINTER_DISOWN) { - sobj->own = 0; + if (((flags & SWIG_POINTER_RELEASE) == SWIG_POINTER_RELEASE) && !sobj->own) { + res = SWIG_ERROR_RELEASE_NOT_OWNED; + } else { + if (own) + *own = *own | sobj->own; + if (flags & SWIG_POINTER_DISOWN) { + sobj->own = 0; + } + if (flags & SWIG_POINTER_CLEAR) { + sobj->ptr = 0; + } + res = SWIG_OK; } - res = SWIG_OK; } else { if (implicit_conv) { SwigPyClientData *data = ty ? (SwigPyClientData *) ty->clientdata : 0; @@ -2186,10 +2639,20 @@ SWIG_Python_ConvertFunctionPtr(PyObject *obj, void **ptr, swig_type_info *ty) { swig_cast_info *tc; /* here we get the method pointer for callbacks */ +#ifndef Py_LIMITED_API const char *doc = (((PyCFunctionObject *)obj) -> m_ml -> ml_doc); +#else + PyObject* pystr_doc = PyObject_GetAttrString(obj, "__doc__"); + PyObject *bytes = NULL; + const char *doc = pystr_doc ? SWIG_PyUnicode_AsUTF8AndSize(pystr_doc, NULL, &bytes) : 0; +#endif const char *desc = doc ? strstr(doc, "swig_ptr: ") : 0; if (desc) desc = ty ? SWIG_UnpackVoidPtr(desc + 10, &vptr, ty->name) : 0; +#ifdef Py_LIMITED_API + Py_XDECREF(bytes); + Py_XDECREF(pystr_doc); +#endif if (!desc) return SWIG_ERROR; tc = SWIG_TypeCheck(desc,ty); @@ -2240,12 +2703,17 @@ SWIG_Python_NewShadowInstance(SwigPyClientData *data, PyObject *swig_this) #if !defined(SWIG_PYTHON_SLOW_GETSET_THIS) PyObject **dictptr = _PyObject_GetDictPtr(inst); if (dictptr != NULL) { - PyObject *dict = *dictptr; - if (dict == NULL) { - dict = PyDict_New(); - *dictptr = dict; - PyDict_SetItem(dict, SWIG_This(), swig_this); - } + PyObject *dict = *dictptr; + if (dict == NULL) { + dict = PyDict_New(); + *dictptr = dict; + } + if (dict) { + PyDict_SetItem(dict, SWIG_This(), swig_this); + } else{ + Py_DECREF(inst); + inst = 0; + } } #else if (PyObject_SetAttr(inst, SWIG_This(), swig_this) == -1) { @@ -2260,14 +2728,19 @@ SWIG_Python_NewShadowInstance(SwigPyClientData *data, PyObject *swig_this) if (empty_args) { PyObject *empty_kwargs = PyDict_New(); if (empty_kwargs) { - inst = ((PyTypeObject *)data->newargs)->tp_new((PyTypeObject *)data->newargs, empty_args, empty_kwargs); +#ifndef Py_LIMITED_API + newfunc newfn = ((PyTypeObject *)data->newargs)->tp_new; +#else + newfunc newfn = (newfunc)PyType_GetSlot((PyTypeObject *)data->newargs, Py_tp_new); +#endif + inst = newfn((PyTypeObject *)data->newargs, empty_args, empty_kwargs); Py_DECREF(empty_kwargs); if (inst) { if (PyObject_SetAttr(inst, SWIG_This(), swig_this) == -1) { Py_DECREF(inst); inst = 0; } else { - Py_TYPE(inst)->tp_flags &= ~Py_TPFLAGS_VALID_VERSION_TAG; + PyType_Modified(Py_TYPE(inst)); } } } @@ -2296,7 +2769,11 @@ SWIG_Python_SetSwigThis(PyObject *inst, PyObject *swig_this) dict = PyDict_New(); *dictptr = dict; } - return PyDict_SetItem(dict, SWIG_This(), swig_this); + if (dict) { + return PyDict_SetItem(dict, SWIG_This(), swig_this); + } else{ + return -1; + } } #endif return PyObject_SetAttr(inst, SWIG_This(), swig_this); @@ -2311,7 +2788,7 @@ SWIG_Python_InitShadowInstance(PyObject *args) { } else { SwigPyObject *sthis = SWIG_Python_GetSwigThis(obj[0]); if (sthis) { - SwigPyObject_append((PyObject*) sthis, obj[1]); + Py_DECREF(SwigPyObject_append((PyObject*) sthis, obj[1])); } else { if (SWIG_Python_SetSwigThis(obj[0], obj[1]) != 0) return NULL; @@ -2338,7 +2815,12 @@ SWIG_Python_NewPointerObj(PyObject *self, void *ptr, swig_type_info *type, int f if (flags & SWIG_BUILTIN_TP_INIT) { newobj = (SwigPyObject*) self; if (newobj->ptr) { - PyObject *next_self = clientdata->pytype->tp_alloc(clientdata->pytype, 0); +#ifndef Py_LIMITED_API + allocfunc alloc = clientdata->pytype->tp_alloc; +#else + allocfunc alloc = (allocfunc)PyType_GetSlot(clientdata->pytype, Py_tp_alloc); +#endif + PyObject *next_self = alloc(clientdata->pytype, 0); while (newobj->next) newobj = (SwigPyObject *) newobj->next; newobj->next = next_self; @@ -2350,7 +2832,9 @@ SWIG_Python_NewPointerObj(PyObject *self, void *ptr, swig_type_info *type, int f } else { newobj = PyObject_New(SwigPyObject, clientdata->pytype); #ifdef SWIGPYTHON_BUILTIN - newobj->dict = 0; + if (newobj) { + newobj->dict = 0; + } #endif } if (newobj) { @@ -2389,39 +2873,61 @@ SWIG_Python_NewPackedObj(void *ptr, size_t sz, swig_type_info *type) { void *SWIG_ReturnGlobalTypeList(void *); #endif +static PyObject *Swig_TypeCache_global = NULL; + +/* The python cached type query */ +SWIGRUNTIME PyObject * +SWIG_Python_TypeCache(void) { + if (Swig_TypeCache_global == NULL) { + Swig_TypeCache_global = PyDict_New(); + } + return Swig_TypeCache_global; +} + SWIGRUNTIME swig_module_info * SWIG_Python_GetModule(void *SWIGUNUSEDPARM(clientdata)) { +#ifdef SWIG_LINK_RUNTIME static void *type_pointer = (void *)0; /* first check if module already created */ if (!type_pointer) { -#ifdef SWIG_LINK_RUNTIME type_pointer = SWIG_ReturnGlobalTypeList((void *)0); + } #else - type_pointer = PyCapsule_Import(SWIGPY_CAPSULE_NAME, 0); - if (PyErr_Occurred()) { - PyErr_Clear(); - type_pointer = (void *)0; - } -#endif + void *type_pointer = PyCapsule_Import(SWIGPY_CAPSULE_NAME, 0); + if (PyErr_Occurred()) { + PyErr_Clear(); + type_pointer = (void *)0; } +#endif return (swig_module_info *) type_pointer; } + +static int interpreter_counter = 0; /* how many (sub-)interpreters are using swig_module's types */ + SWIGRUNTIME void SWIG_Python_DestroyModule(PyObject *obj) { swig_module_info *swig_module = (swig_module_info *) PyCapsule_GetPointer(obj, SWIGPY_CAPSULE_NAME); swig_type_info **types = swig_module->types; size_t i; + if (--interpreter_counter != 0) /* another sub-interpreter may still be using the swig_module's types */ + return; for (i =0; i < swig_module->size; ++i) { swig_type_info *ty = types[i]; if (ty->owndata) { SwigPyClientData *data = (SwigPyClientData *) ty->clientdata; + ty->clientdata = 0; if (data) SwigPyClientData_Del(data); } } Py_DECREF(SWIG_This()); Swig_This_global = NULL; + Py_DECREF(SWIG_globals()); + Swig_Globals_global = NULL; + Py_DECREF(SWIG_Python_TypeCache()); + Swig_TypeCache_global = NULL; + Swig_Capsule_global = NULL; } SWIGRUNTIME void @@ -2435,19 +2941,17 @@ SWIG_Python_SetModule(swig_module_info *swig_module) { #endif PyObject *pointer = PyCapsule_New((void *) swig_module, SWIGPY_CAPSULE_NAME, SWIG_Python_DestroyModule); if (pointer && module) { - PyModule_AddObject(module, "type_pointer_capsule" SWIG_TYPE_TABLE_NAME, pointer); + if (PyModule_AddObject(module, SWIGPY_CAPSULE_ATTR_NAME, pointer) == 0) { + ++interpreter_counter; + Swig_Capsule_global = pointer; + } else { + Py_DECREF(pointer); + } } else { Py_XDECREF(pointer); } } -/* The python cached type query */ -SWIGRUNTIME PyObject * -SWIG_Python_TypeCache(void) { - static PyObject *SWIG_STATIC_POINTER(cache) = PyDict_New(); - return cache; -} - SWIGRUNTIME swig_type_info * SWIG_Python_TypeQuery(const char *type) { @@ -2462,8 +2966,10 @@ SWIG_Python_TypeQuery(const char *type) descriptor = SWIG_TypeQueryModule(swig_module, swig_module, type); if (descriptor) { obj = PyCapsule_New((void*) descriptor, NULL, NULL); - PyDict_SetItem(cache, key, obj); - Py_DECREF(obj); + if (obj) { + PyDict_SetItem(cache, key, obj); + Py_DECREF(obj); + } } } Py_DECREF(key); @@ -2487,7 +2993,8 @@ SWIG_Python_AddErrMesg(const char* mesg, int infront) PyErr_Fetch(&type, &value, &traceback); if (value) { PyObject *old_str = PyObject_Str(value); - const char *tmp = SWIG_Python_str_AsChar(old_str); + PyObject *bytes = NULL; + const char *tmp = SWIG_PyUnicode_AsUTF8AndSize(old_str, NULL, &bytes); const char *errmesg = tmp ? tmp : "Invalid error message"; Py_XINCREF(type); PyErr_Clear(); @@ -2496,7 +3003,7 @@ SWIG_Python_AddErrMesg(const char* mesg, int infront) } else { PyErr_Format(type, "%s %s", errmesg, mesg); } - SWIG_Python_str_DelForPy3(tmp); + Py_XDECREF(bytes); Py_DECREF(old_str); } return 1; @@ -2541,21 +3048,25 @@ SWIG_Python_TypeError(const char *type, PyObject *obj) } else #endif { +#ifndef Py_LIMITED_API + /* tp_name is not accessible */ const char *otype = (obj ? obj->ob_type->tp_name : 0); if (otype) { PyObject *str = PyObject_Str(obj); - const char *cstr = str ? SWIG_Python_str_AsChar(str) : 0; + PyObject *bytes = NULL; + const char *cstr = str ? SWIG_PyUnicode_AsUTF8AndSize(str, NULL, &bytes) : 0; if (cstr) { PyErr_Format(PyExc_TypeError, "a '%s' is expected, '%s(%s)' is received", type, otype, cstr); - SWIG_Python_str_DelForPy3(cstr); } else { PyErr_Format(PyExc_TypeError, "a '%s' is expected, '%s' is received", type, otype); } + Py_XDECREF(bytes); Py_XDECREF(str); return; } +#endif } PyErr_Format(PyExc_TypeError, "a '%s' is expected", type); } else { @@ -2570,12 +3081,6 @@ SWIG_Python_MustGetPtr(PyObject *obj, swig_type_info *ty, int SWIGUNUSEDPARM(arg void *result; if (SWIG_Python_ConvertPtr(obj, &result, ty, flags) == -1) { PyErr_Clear(); -#if SWIG_POINTER_EXCEPTION - if (flags) { - SWIG_Python_TypeError(SWIG_TypePrettyName(ty), obj); - SWIG_Python_ArgFail(argnum); - } -#endif } return result; } @@ -2606,7 +3111,7 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) { } if (!tp->tp_dict) { - if (PyType_Ready(tp) < 0) + if (PyType_Ready(tp) != 0) goto done; } @@ -2621,7 +3126,7 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) { } else { encoded_name = PyUnicode_AsUTF8String(name); if (!encoded_name) - return -1; + goto done; } PyErr_Format(PyExc_AttributeError, "'%.100s' object has no attribute '%.200s'", tp->tp_name, PyString_AsString(encoded_name)); Py_DECREF(encoded_name); @@ -2644,25 +3149,10 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) { #define SWIG_exception_fail(code, msg) do { SWIG_Error(code, msg); SWIG_fail; } while(0) -#define SWIG_contract_assert(expr, msg) if (!(expr)) { SWIG_Error(SWIG_RuntimeError, msg); SWIG_fail; } else +#define SWIG_contract_assert(expr, msg) do { if (!(expr)) { SWIG_Error(SWIG_RuntimeError, msg); SWIG_fail; } } while (0) -#ifdef __cplusplus -extern "C" { -#endif - -/* Method creation and docstring support functions */ - -SWIGINTERN PyMethodDef *SWIG_PythonGetProxyDoc(const char *name); -SWIGINTERN PyObject *SWIG_PyInstanceMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func); -SWIGINTERN PyObject *SWIG_PyStaticMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func); - -#ifdef __cplusplus -} -#endif - - /* -------- TYPES TABLE (BEGIN) -------- */ #define SWIGTYPE_p_Distort swig_types[0] @@ -2703,10 +3193,6 @@ static swig_module_info swig_module = {swig_types, 14, 0, 0, 0, 0}; #endif #define SWIG_name "_wcs" -#define SWIGVERSION 0x040002 -#define SWIG_VERSION SWIGVERSION - - #define SWIG_as_voidptr(a) (void *)((const void *)(a)) #define SWIG_as_voidptrptr(a) ((void)SWIG_as_voidptr(*a),(void**)(a)) @@ -2783,9 +3269,11 @@ SWIGINTERNINLINE int SWIG_CanCastAsInteger(double *d, double min, double max) { double x = *d; if ((min <= x && x <= max)) { - double fx = floor(x); - double cx = ceil(x); - double rd = ((x - fx) < 0.5) ? fx : cx; /* simple rint */ + double fx, cx, rd; + errno = 0; + fx = floor(x); + cx = ceil(x); + rd = ((x - fx) < 0.5) ? fx : cx; /* simple rint */ if ((errno == EDOM) || (errno == ERANGE)) { errno = 0; } else { @@ -2846,7 +3334,11 @@ SWIG_AsVal_unsigned_SS_long (PyObject *obj, unsigned long *val) if (!dispatch) { double d; int res = SWIG_AddCast(SWIG_AsVal_double (obj,&d)); - if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, 0, ULONG_MAX)) { + // Largest double not larger than ULONG_MAX (not portably calculated easily) + // Note that double(ULONG_MAX) is stored in a double rounded up by one (for 64-bit unsigned long) + // 0xfffffffffffff800ULL == (uint64_t)std::nextafter(double(__uint128_t(ULONG_MAX)+1), double(0)) + const double ulong_max = sizeof(unsigned long) == 8 ? 0xfffffffffffff800ULL : ULONG_MAX; + if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, 0, ulong_max)) { if (val) *val = (unsigned long)(d); return res; } @@ -2953,8 +3445,10 @@ SWIG_pchar_descriptor(void) } +/* Return string from Python obj. NOTE: obj must remain in scope in order + to use the returned cptr (but only when alloc is set to SWIG_OLDOBJ) */ SWIGINTERN int -SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc) +SWIG_AsCharPtrAndSize(PyObject *obj, char **cptr, size_t *psize, int *alloc) { #if PY_VERSION_HEX>=0x03000000 #if defined(SWIG_PYTHON_STRICT_BYTE_CHAR) @@ -2967,55 +3461,31 @@ SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc) #endif { char *cstr; Py_ssize_t len; + PyObject *bytes = NULL; int ret = SWIG_OK; -#if PY_VERSION_HEX>=0x03000000 -#if !defined(SWIG_PYTHON_STRICT_BYTE_CHAR) - if (!alloc && cptr) { - /* We can't allow converting without allocation, since the internal - representation of string in Python 3 is UCS-2/UCS-4 but we require - a UTF-8 representation. - TODO(bhy) More detailed explanation */ - return SWIG_RuntimeError; - } - obj = PyUnicode_AsUTF8String(obj); - if (!obj) - return SWIG_TypeError; if (alloc) - *alloc = SWIG_NEWOBJ; -#endif + *alloc = SWIG_OLDOBJ; +#if PY_VERSION_HEX>=0x03000000 && defined(SWIG_PYTHON_STRICT_BYTE_CHAR) if (PyBytes_AsStringAndSize(obj, &cstr, &len) == -1) return SWIG_TypeError; #else - if (PyString_AsStringAndSize(obj, &cstr, &len) == -1) + cstr = (char *)SWIG_PyUnicode_AsUTF8AndSize(obj, &len, &bytes); + if (!cstr) return SWIG_TypeError; -#endif - if (cptr) { + /* The returned string is only duplicated if the char * returned is not owned and memory managed by obj */ + if (bytes && cptr) { if (alloc) { - if (*alloc == SWIG_NEWOBJ) { - *cptr = (char *)memcpy(malloc((len + 1)*sizeof(char)), cstr, sizeof(char)*(len + 1)); - *alloc = SWIG_NEWOBJ; - } else { - *cptr = cstr; - *alloc = SWIG_OLDOBJ; - } + cstr = (char *)memcpy(malloc((len + 1)*sizeof(char)), cstr, sizeof(char)*(len + 1)); + *alloc = SWIG_NEWOBJ; } else { -#if PY_VERSION_HEX>=0x03000000 -#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR) - *cptr = PyBytes_AsString(obj); -#else - assert(0); /* Should never reach here with Unicode strings in Python 3 */ -#endif -#else - *cptr = SWIG_Python_str_AsChar(obj); - if (!*cptr) - ret = SWIG_TypeError; -#endif + /* alloc must be set in order to clean up allocated memory */ + return SWIG_RuntimeError; } } - if (psize) *psize = len + 1; -#if PY_VERSION_HEX>=0x03000000 && !defined(SWIG_PYTHON_STRICT_BYTE_CHAR) - Py_XDECREF(obj); #endif + if (cptr) *cptr = cstr; + if (psize) *psize = len + 1; + Py_XDECREF(bytes); return ret; } else { #if defined(SWIG_PYTHON_2_UNICODE) @@ -3097,7 +3567,12 @@ SWIG_AsVal_long (PyObject *obj, long* val) if (!dispatch) { double d; int res = SWIG_AddCast(SWIG_AsVal_double (obj,&d)); - if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, LONG_MIN, LONG_MAX)) { + // Largest double not larger than LONG_MAX (not portably calculated easily) + // Note that double(LONG_MAX) is stored in a double rounded up by one (for 64-bit long) + // 0x7ffffffffffffc00LL == (int64_t)std::nextafter(double(__uint128_t(LONG_MAX)+1), double(0)) + const double long_max = sizeof(long) == 8 ? 0x7ffffffffffffc00LL : LONG_MAX; + // No equivalent needed for 64-bit double(LONG_MIN) is exactly LONG_MIN + if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, LONG_MIN, long_max)) { if (val) *val = (long)(d); return res; } @@ -3226,7 +3701,7 @@ SWIG_From_char (char c) #ifdef __cplusplus extern "C" { #endif -SWIGINTERN PyObject *_wrap_new_doubleArray(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_new_doubleArray(PyObject *self, PyObject *args) { PyObject *resultobj = 0; size_t arg1 ; size_t val1 ; @@ -3234,6 +3709,7 @@ SWIGINTERN PyObject *_wrap_new_doubleArray(PyObject *SWIGUNUSEDPARM(self), PyObj PyObject *swig_obj[1] ; double *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; ecode1 = SWIG_AsVal_size_t(swig_obj[0], &val1); @@ -3249,13 +3725,14 @@ SWIGINTERN PyObject *_wrap_new_doubleArray(PyObject *SWIGUNUSEDPARM(self), PyObj } -SWIGINTERN PyObject *_wrap_delete_doubleArray(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_delete_doubleArray(PyObject *self, PyObject *args) { PyObject *resultobj = 0; double *arg1 = (double *) 0 ; void *argp1 = 0 ; int res1 = 0 ; PyObject *swig_obj[1] ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_double, 0 | 0 ); @@ -3271,7 +3748,7 @@ SWIGINTERN PyObject *_wrap_delete_doubleArray(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_doubleArray_getitem(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_doubleArray_getitem(PyObject *self, PyObject *args) { PyObject *resultobj = 0; double *arg1 = (double *) 0 ; size_t arg2 ; @@ -3282,6 +3759,7 @@ SWIGINTERN PyObject *_wrap_doubleArray_getitem(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[2] ; double result; + (void)self; if (!SWIG_Python_UnpackTuple(args, "doubleArray_getitem", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_double, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -3301,7 +3779,7 @@ SWIGINTERN PyObject *_wrap_doubleArray_getitem(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_doubleArray_setitem(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_doubleArray_setitem(PyObject *self, PyObject *args) { PyObject *resultobj = 0; double *arg1 = (double *) 0 ; size_t arg2 ; @@ -3314,6 +3792,7 @@ SWIGINTERN PyObject *_wrap_doubleArray_setitem(PyObject *SWIGUNUSEDPARM(self), P int ecode3 = 0 ; PyObject *swig_obj[3] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "doubleArray_setitem", 3, 3, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_double, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -3338,7 +3817,7 @@ SWIGINTERN PyObject *_wrap_doubleArray_setitem(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_wcsinit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_wcsinit(PyObject *self, PyObject *args) { PyObject *resultobj = 0; char *arg1 = (char *) 0 ; int res1 ; @@ -3347,6 +3826,7 @@ SWIGINTERN PyObject *_wrap_wcsinit(PyObject *SWIGUNUSEDPARM(self), PyObject *arg PyObject *swig_obj[1] ; struct WorldCoor *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1); @@ -3364,7 +3844,7 @@ SWIGINTERN PyObject *_wrap_wcsinit(PyObject *SWIGUNUSEDPARM(self), PyObject *arg } -SWIGINTERN PyObject *_wrap_wcsxinit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_wcsxinit(PyObject *self, PyObject *args) { PyObject *resultobj = 0; double arg1 ; double arg2 ; @@ -3403,6 +3883,7 @@ SWIGINTERN PyObject *_wrap_wcsxinit(PyObject *SWIGUNUSEDPARM(self), PyObject *ar PyObject *swig_obj[11] ; struct WorldCoor *result = 0 ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "wcsxinit", 11, 11, swig_obj)) SWIG_fail; ecode1 = SWIG_AsVal_double(swig_obj[0], &val1); if (!SWIG_IsOK(ecode1)) { @@ -3469,7 +3950,7 @@ SWIGINTERN PyObject *_wrap_wcsxinit(PyObject *SWIGUNUSEDPARM(self), PyObject *ar } -SWIGINTERN PyObject *_wrap_wcskinit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_wcskinit(PyObject *self, PyObject *args) { PyObject *resultobj = 0; int arg1 ; int arg2 ; @@ -3518,6 +3999,7 @@ SWIGINTERN PyObject *_wrap_wcskinit(PyObject *SWIGUNUSEDPARM(self), PyObject *ar PyObject *swig_obj[14] ; struct WorldCoor *result = 0 ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "wcskinit", 14, 14, swig_obj)) SWIG_fail; ecode1 = SWIG_AsVal_int(swig_obj[0], &val1); if (!SWIG_IsOK(ecode1)) { @@ -3601,7 +4083,7 @@ SWIGINTERN PyObject *_wrap_wcskinit(PyObject *SWIGUNUSEDPARM(self), PyObject *ar } -SWIGINTERN PyObject *_wrap_iswcs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_iswcs(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -3609,6 +4091,7 @@ SWIGINTERN PyObject *_wrap_iswcs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -3624,7 +4107,7 @@ SWIGINTERN PyObject *_wrap_iswcs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) } -SWIGINTERN PyObject *_wrap_nowcs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_nowcs(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -3632,6 +4115,7 @@ SWIGINTERN PyObject *_wrap_nowcs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -3647,7 +4131,7 @@ SWIGINTERN PyObject *_wrap_nowcs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) } -SWIGINTERN PyObject *_wrap_wcs2pix(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_wcs2pix(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -3672,6 +4156,7 @@ SWIGINTERN PyObject *_wrap_wcs2pix(PyObject *SWIGUNUSEDPARM(self), PyObject *arg arg4 = &temp4; arg5 = &temp5; arg6 = &temp6; + (void)self; if (!SWIG_Python_UnpackTuple(args, "wcs2pix", 3, 3, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -3714,7 +4199,7 @@ SWIGINTERN PyObject *_wrap_wcs2pix(PyObject *SWIGUNUSEDPARM(self), PyObject *arg } -SWIGINTERN PyObject *_wrap_pix2wcs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_pix2wcs(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -3735,6 +4220,7 @@ SWIGINTERN PyObject *_wrap_pix2wcs(PyObject *SWIGUNUSEDPARM(self), PyObject *arg arg4 = &temp4; arg5 = &temp5; + (void)self; if (!SWIG_Python_UnpackTuple(args, "pix2wcs", 3, 3, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -3771,13 +4257,14 @@ SWIGINTERN PyObject *_wrap_pix2wcs(PyObject *SWIGUNUSEDPARM(self), PyObject *arg } -SWIGINTERN PyObject *_wrap_wcscent(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_wcscent(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; int res1 = 0 ; PyObject *swig_obj[1] ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -3793,7 +4280,7 @@ SWIGINTERN PyObject *_wrap_wcscent(PyObject *SWIGUNUSEDPARM(self), PyObject *arg } -SWIGINTERN PyObject *_wrap_getradecsys(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_getradecsys(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -3801,6 +4288,7 @@ SWIGINTERN PyObject *_wrap_getradecsys(PyObject *SWIGUNUSEDPARM(self), PyObject PyObject *swig_obj[1] ; char *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -3816,7 +4304,7 @@ SWIGINTERN PyObject *_wrap_getradecsys(PyObject *SWIGUNUSEDPARM(self), PyObject } -SWIGINTERN PyObject *_wrap_wcsoutinit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_wcsoutinit(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; char *arg2 = (char *) 0 ; @@ -3827,6 +4315,7 @@ SWIGINTERN PyObject *_wrap_wcsoutinit(PyObject *SWIGUNUSEDPARM(self), PyObject * int alloc2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "wcsoutinit", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -3848,7 +4337,7 @@ SWIGINTERN PyObject *_wrap_wcsoutinit(PyObject *SWIGUNUSEDPARM(self), PyObject * } -SWIGINTERN PyObject *_wrap_wcsininit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_wcsininit(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; char *arg2 = (char *) 0 ; @@ -3859,6 +4348,7 @@ SWIGINTERN PyObject *_wrap_wcsininit(PyObject *SWIGUNUSEDPARM(self), PyObject *a int alloc2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "wcsininit", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -3880,7 +4370,7 @@ SWIGINTERN PyObject *_wrap_wcsininit(PyObject *SWIGUNUSEDPARM(self), PyObject *a } -SWIGINTERN PyObject *_wrap_getwcsout(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_getwcsout(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -3888,6 +4378,7 @@ SWIGINTERN PyObject *_wrap_getwcsout(PyObject *SWIGUNUSEDPARM(self), PyObject *a PyObject *swig_obj[1] ; char *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -3903,7 +4394,7 @@ SWIGINTERN PyObject *_wrap_getwcsout(PyObject *SWIGUNUSEDPARM(self), PyObject *a } -SWIGINTERN PyObject *_wrap_getwcsin(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_getwcsin(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -3911,6 +4402,7 @@ SWIGINTERN PyObject *_wrap_getwcsin(PyObject *SWIGUNUSEDPARM(self), PyObject *ar PyObject *swig_obj[1] ; char *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -3926,7 +4418,7 @@ SWIGINTERN PyObject *_wrap_getwcsin(PyObject *SWIGUNUSEDPARM(self), PyObject *ar } -SWIGINTERN PyObject *_wrap_wcssize(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_wcssize(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double *arg2 = (double *) 0 ; @@ -3949,6 +4441,7 @@ SWIGINTERN PyObject *_wrap_wcssize(PyObject *SWIGUNUSEDPARM(self), PyObject *arg arg3 = &temp3; arg4 = &temp4; arg5 = &temp5; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -3988,7 +4481,7 @@ SWIGINTERN PyObject *_wrap_wcssize(PyObject *SWIGUNUSEDPARM(self), PyObject *arg } -SWIGINTERN PyObject *_wrap_wcsfull(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_wcsfull(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double *arg2 = (double *) 0 ; @@ -4011,6 +4504,7 @@ SWIGINTERN PyObject *_wrap_wcsfull(PyObject *SWIGUNUSEDPARM(self), PyObject *arg arg3 = &temp3; arg4 = &temp4; arg5 = &temp5; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4050,7 +4544,7 @@ SWIGINTERN PyObject *_wrap_wcsfull(PyObject *SWIGUNUSEDPARM(self), PyObject *arg } -SWIGINTERN PyObject *_wrap_WorldCoor_xref_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_xref_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -4060,6 +4554,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xref_set(PyObject *SWIGUNUSEDPARM(self), Py int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_xref_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4079,7 +4574,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xref_set(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_xref_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_xref_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4087,6 +4582,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xref_get(PyObject *SWIGUNUSEDPARM(self), Py PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4102,7 +4598,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xref_get(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_yref_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_yref_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -4112,6 +4608,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_yref_set(PyObject *SWIGUNUSEDPARM(self), Py int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_yref_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4131,7 +4628,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_yref_set(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_yref_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_yref_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4139,6 +4636,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_yref_get(PyObject *SWIGUNUSEDPARM(self), Py PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4154,7 +4652,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_yref_get(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_xrefpix_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_xrefpix_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -4164,6 +4662,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xrefpix_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_xrefpix_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4183,7 +4682,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xrefpix_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_xrefpix_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_xrefpix_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4191,6 +4690,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xrefpix_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4206,7 +4706,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xrefpix_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_yrefpix_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_yrefpix_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -4216,6 +4716,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_yrefpix_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_yrefpix_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4235,7 +4736,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_yrefpix_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_yrefpix_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_yrefpix_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4243,6 +4744,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_yrefpix_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4258,7 +4760,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_yrefpix_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_xinc_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_xinc_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -4268,6 +4770,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xinc_set(PyObject *SWIGUNUSEDPARM(self), Py int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_xinc_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4287,7 +4790,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xinc_set(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_xinc_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_xinc_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4295,6 +4798,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xinc_get(PyObject *SWIGUNUSEDPARM(self), Py PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4310,7 +4814,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xinc_get(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_yinc_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_yinc_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -4320,6 +4824,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_yinc_set(PyObject *SWIGUNUSEDPARM(self), Py int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_yinc_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4339,7 +4844,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_yinc_set(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_yinc_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_yinc_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4347,6 +4852,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_yinc_get(PyObject *SWIGUNUSEDPARM(self), Py PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4362,7 +4868,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_yinc_get(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_rot_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_rot_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -4372,6 +4878,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_rot_set(PyObject *SWIGUNUSEDPARM(self), PyO int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_rot_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4391,7 +4898,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_rot_set(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_WorldCoor_rot_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_rot_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4399,6 +4906,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_rot_get(PyObject *SWIGUNUSEDPARM(self), PyO PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4414,16 +4922,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_rot_get(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_WorldCoor_cd_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_cd_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - double *arg2 ; + double *arg2 = (double *) (double *)0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_cd_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4450,7 +4959,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_cd_set(PyObject *SWIGUNUSEDPARM(self), PyOb } -SWIGINTERN PyObject *_wrap_WorldCoor_cd_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_cd_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4458,6 +4967,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_cd_get(PyObject *SWIGUNUSEDPARM(self), PyOb PyObject *swig_obj[1] ; double *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4473,16 +4983,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_cd_get(PyObject *SWIGUNUSEDPARM(self), PyOb } -SWIGINTERN PyObject *_wrap_WorldCoor_dc_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_dc_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - double *arg2 ; + double *arg2 = (double *) (double *)0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_dc_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4509,7 +5020,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_dc_set(PyObject *SWIGUNUSEDPARM(self), PyOb } -SWIGINTERN PyObject *_wrap_WorldCoor_dc_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_dc_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4517,6 +5028,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_dc_get(PyObject *SWIGUNUSEDPARM(self), PyOb PyObject *swig_obj[1] ; double *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4532,7 +5044,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_dc_get(PyObject *SWIGUNUSEDPARM(self), PyOb } -SWIGINTERN PyObject *_wrap_WorldCoor_equinox_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_equinox_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -4542,6 +5054,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_equinox_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_equinox_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4561,7 +5074,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_equinox_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_equinox_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_equinox_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4569,6 +5082,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_equinox_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4584,7 +5098,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_equinox_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_epoch_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_epoch_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -4594,6 +5108,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_epoch_set(PyObject *SWIGUNUSEDPARM(self), P int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_epoch_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4613,7 +5128,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_epoch_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_epoch_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_epoch_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4621,6 +5136,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_epoch_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4636,7 +5152,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_epoch_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_nxpix_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_nxpix_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -4646,6 +5162,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_nxpix_set(PyObject *SWIGUNUSEDPARM(self), P int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_nxpix_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4665,7 +5182,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_nxpix_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_nxpix_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_nxpix_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4673,6 +5190,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_nxpix_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4688,7 +5206,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_nxpix_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_nypix_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_nypix_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -4698,6 +5216,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_nypix_set(PyObject *SWIGUNUSEDPARM(self), P int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_nypix_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4717,7 +5236,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_nypix_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_nypix_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_nypix_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4725,6 +5244,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_nypix_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4740,7 +5260,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_nypix_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_plate_ra_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_plate_ra_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -4750,6 +5270,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_plate_ra_set(PyObject *SWIGUNUSEDPARM(self) int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_plate_ra_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4769,7 +5290,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_plate_ra_set(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_plate_ra_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_plate_ra_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4777,6 +5298,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_plate_ra_get(PyObject *SWIGUNUSEDPARM(self) PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4792,7 +5314,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_plate_ra_get(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_plate_dec_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_plate_dec_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -4802,6 +5324,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_plate_dec_set(PyObject *SWIGUNUSEDPARM(self int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_plate_dec_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4821,7 +5344,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_plate_dec_set(PyObject *SWIGUNUSEDPARM(self } -SWIGINTERN PyObject *_wrap_WorldCoor_plate_dec_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_plate_dec_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4829,6 +5352,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_plate_dec_get(PyObject *SWIGUNUSEDPARM(self PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4844,7 +5368,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_plate_dec_get(PyObject *SWIGUNUSEDPARM(self } -SWIGINTERN PyObject *_wrap_WorldCoor_plate_scale_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_plate_scale_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -4854,6 +5378,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_plate_scale_set(PyObject *SWIGUNUSEDPARM(se int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_plate_scale_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4873,7 +5398,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_plate_scale_set(PyObject *SWIGUNUSEDPARM(se } -SWIGINTERN PyObject *_wrap_WorldCoor_plate_scale_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_plate_scale_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4881,6 +5406,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_plate_scale_get(PyObject *SWIGUNUSEDPARM(se PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4896,7 +5422,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_plate_scale_get(PyObject *SWIGUNUSEDPARM(se } -SWIGINTERN PyObject *_wrap_WorldCoor_x_pixel_offset_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_x_pixel_offset_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -4906,6 +5432,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_x_pixel_offset_set(PyObject *SWIGUNUSEDPARM int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_x_pixel_offset_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4925,7 +5452,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_x_pixel_offset_set(PyObject *SWIGUNUSEDPARM } -SWIGINTERN PyObject *_wrap_WorldCoor_x_pixel_offset_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_x_pixel_offset_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4933,6 +5460,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_x_pixel_offset_get(PyObject *SWIGUNUSEDPARM PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -4948,7 +5476,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_x_pixel_offset_get(PyObject *SWIGUNUSEDPARM } -SWIGINTERN PyObject *_wrap_WorldCoor_y_pixel_offset_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_y_pixel_offset_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -4958,6 +5486,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_y_pixel_offset_set(PyObject *SWIGUNUSEDPARM int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_y_pixel_offset_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -4977,7 +5506,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_y_pixel_offset_set(PyObject *SWIGUNUSEDPARM } -SWIGINTERN PyObject *_wrap_WorldCoor_y_pixel_offset_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_y_pixel_offset_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -4985,6 +5514,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_y_pixel_offset_get(PyObject *SWIGUNUSEDPARM PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5000,7 +5530,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_y_pixel_offset_get(PyObject *SWIGUNUSEDPARM } -SWIGINTERN PyObject *_wrap_WorldCoor_x_pixel_size_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_x_pixel_size_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -5010,6 +5540,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_x_pixel_size_set(PyObject *SWIGUNUSEDPARM(s int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_x_pixel_size_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5029,7 +5560,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_x_pixel_size_set(PyObject *SWIGUNUSEDPARM(s } -SWIGINTERN PyObject *_wrap_WorldCoor_x_pixel_size_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_x_pixel_size_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5037,6 +5568,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_x_pixel_size_get(PyObject *SWIGUNUSEDPARM(s PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5052,7 +5584,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_x_pixel_size_get(PyObject *SWIGUNUSEDPARM(s } -SWIGINTERN PyObject *_wrap_WorldCoor_y_pixel_size_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_y_pixel_size_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -5062,6 +5594,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_y_pixel_size_set(PyObject *SWIGUNUSEDPARM(s int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_y_pixel_size_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5081,7 +5614,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_y_pixel_size_set(PyObject *SWIGUNUSEDPARM(s } -SWIGINTERN PyObject *_wrap_WorldCoor_y_pixel_size_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_y_pixel_size_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5089,6 +5622,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_y_pixel_size_get(PyObject *SWIGUNUSEDPARM(s PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5104,16 +5638,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_y_pixel_size_get(PyObject *SWIGUNUSEDPARM(s } -SWIGINTERN PyObject *_wrap_WorldCoor_ppo_coeff_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ppo_coeff_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - double *arg2 ; + double *arg2 = (double *) (double *)0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_ppo_coeff_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5140,7 +5675,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ppo_coeff_set(PyObject *SWIGUNUSEDPARM(self } -SWIGINTERN PyObject *_wrap_WorldCoor_ppo_coeff_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ppo_coeff_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5148,6 +5683,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ppo_coeff_get(PyObject *SWIGUNUSEDPARM(self PyObject *swig_obj[1] ; double *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5163,16 +5699,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ppo_coeff_get(PyObject *SWIGUNUSEDPARM(self } -SWIGINTERN PyObject *_wrap_WorldCoor_x_coeff_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_x_coeff_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - double *arg2 ; + double *arg2 = (double *) (double *)0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_x_coeff_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5199,7 +5736,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_x_coeff_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_x_coeff_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_x_coeff_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5207,6 +5744,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_x_coeff_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; double *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5222,16 +5760,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_x_coeff_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_y_coeff_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_y_coeff_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - double *arg2 ; + double *arg2 = (double *) (double *)0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_y_coeff_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5258,7 +5797,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_y_coeff_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_y_coeff_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_y_coeff_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5266,6 +5805,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_y_coeff_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; double *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5281,7 +5821,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_y_coeff_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_xpix_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_xpix_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -5291,6 +5831,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xpix_set(PyObject *SWIGUNUSEDPARM(self), Py int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_xpix_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5310,7 +5851,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xpix_set(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_xpix_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_xpix_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5318,6 +5859,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xpix_get(PyObject *SWIGUNUSEDPARM(self), Py PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5333,7 +5875,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xpix_get(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_ypix_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ypix_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -5343,6 +5885,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ypix_set(PyObject *SWIGUNUSEDPARM(self), Py int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_ypix_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5362,7 +5905,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ypix_set(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_ypix_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ypix_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5370,6 +5913,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ypix_get(PyObject *SWIGUNUSEDPARM(self), Py PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5385,7 +5929,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ypix_get(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_zpix_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_zpix_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -5395,6 +5939,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zpix_set(PyObject *SWIGUNUSEDPARM(self), Py int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_zpix_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5414,7 +5959,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zpix_set(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_zpix_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_zpix_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5422,6 +5967,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zpix_get(PyObject *SWIGUNUSEDPARM(self), Py PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5437,7 +5983,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zpix_get(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_xpos_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_xpos_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -5447,6 +5993,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xpos_set(PyObject *SWIGUNUSEDPARM(self), Py int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_xpos_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5466,7 +6013,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xpos_set(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_xpos_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_xpos_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5474,6 +6021,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xpos_get(PyObject *SWIGUNUSEDPARM(self), Py PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5489,7 +6037,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_xpos_get(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_ypos_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ypos_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -5499,6 +6047,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ypos_set(PyObject *SWIGUNUSEDPARM(self), Py int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_ypos_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5518,7 +6067,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ypos_set(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_ypos_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ypos_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5526,6 +6075,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ypos_get(PyObject *SWIGUNUSEDPARM(self), Py PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5541,16 +6091,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ypos_get(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_crpix_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_crpix_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - double *arg2 ; + double *arg2 = (double *) (double *)0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_crpix_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5577,7 +6128,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_crpix_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_crpix_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_crpix_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5585,6 +6136,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_crpix_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; double *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5600,16 +6152,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_crpix_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_crval_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_crval_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - double *arg2 ; + double *arg2 = (double *) (double *)0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_crval_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5636,7 +6189,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_crval_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_crval_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_crval_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5644,6 +6197,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_crval_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; double *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5659,16 +6213,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_crval_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_cdelt_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_cdelt_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - double *arg2 ; + double *arg2 = (double *) (double *)0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_cdelt_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5695,7 +6250,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_cdelt_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_cdelt_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_cdelt_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5703,6 +6258,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_cdelt_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; double *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5718,16 +6274,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_cdelt_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_pc_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_pc_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - double *arg2 ; + double *arg2 = (double *) (double *)0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_pc_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5754,7 +6311,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_pc_set(PyObject *SWIGUNUSEDPARM(self), PyOb } -SWIGINTERN PyObject *_wrap_WorldCoor_pc_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_pc_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5762,6 +6319,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_pc_get(PyObject *SWIGUNUSEDPARM(self), PyOb PyObject *swig_obj[1] ; double *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5777,16 +6335,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_pc_get(PyObject *SWIGUNUSEDPARM(self), PyOb } -SWIGINTERN PyObject *_wrap_WorldCoor_projp_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_projp_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - double *arg2 ; + double *arg2 = (double *) (double *)0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_projp_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5813,7 +6372,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_projp_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_projp_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_projp_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5821,6 +6380,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_projp_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; double *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5836,7 +6396,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_projp_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_pvfail_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_pvfail_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -5846,6 +6406,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_pvfail_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_pvfail_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5865,7 +6426,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_pvfail_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_pvfail_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_pvfail_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5873,6 +6434,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_pvfail_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5888,16 +6450,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_pvfail_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_projppv_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_projppv_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - double *arg2 ; + double *arg2 = (double *) (double *)0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_projppv_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5924,7 +6487,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_projppv_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_projppv_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_projppv_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5932,6 +6495,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_projppv_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; double *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5947,7 +6511,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_projppv_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_inv_x_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_inv_x_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; struct poly *arg2 = (struct poly *) 0 ; @@ -5957,6 +6521,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_inv_x_set(PyObject *SWIGUNUSEDPARM(self), P int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_inv_x_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -5976,7 +6541,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_inv_x_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_inv_x_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_inv_x_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -5984,6 +6549,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_inv_x_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; struct poly *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -5999,7 +6565,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_inv_x_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_inv_y_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_inv_y_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; struct poly *arg2 = (struct poly *) 0 ; @@ -6009,6 +6575,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_inv_y_set(PyObject *SWIGUNUSEDPARM(self), P int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_inv_y_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6028,7 +6595,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_inv_y_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_inv_y_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_inv_y_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6036,6 +6603,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_inv_y_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; struct poly *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6051,7 +6619,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_inv_y_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_longpole_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_longpole_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -6061,6 +6629,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_longpole_set(PyObject *SWIGUNUSEDPARM(self) int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_longpole_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6080,7 +6649,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_longpole_set(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_longpole_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_longpole_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6088,6 +6657,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_longpole_get(PyObject *SWIGUNUSEDPARM(self) PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6103,7 +6673,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_longpole_get(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_latpole_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_latpole_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -6113,6 +6683,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_latpole_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_latpole_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6132,7 +6703,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_latpole_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_latpole_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_latpole_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6140,6 +6711,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_latpole_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6155,7 +6727,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_latpole_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_rodeg_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_rodeg_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -6165,6 +6737,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_rodeg_set(PyObject *SWIGUNUSEDPARM(self), P int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_rodeg_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6184,7 +6757,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_rodeg_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_rodeg_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_rodeg_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6192,6 +6765,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_rodeg_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6207,7 +6781,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_rodeg_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_imrot_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_imrot_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -6217,6 +6791,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_imrot_set(PyObject *SWIGUNUSEDPARM(self), P int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_imrot_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6236,7 +6811,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_imrot_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_imrot_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_imrot_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6244,6 +6819,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_imrot_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6259,7 +6835,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_imrot_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_pa_north_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_pa_north_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -6269,6 +6845,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_pa_north_set(PyObject *SWIGUNUSEDPARM(self) int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_pa_north_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6288,7 +6865,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_pa_north_set(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_pa_north_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_pa_north_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6296,6 +6873,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_pa_north_get(PyObject *SWIGUNUSEDPARM(self) PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6311,7 +6889,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_pa_north_get(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_pa_east_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_pa_east_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -6321,6 +6899,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_pa_east_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_pa_east_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6340,7 +6919,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_pa_east_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_pa_east_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_pa_east_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6348,6 +6927,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_pa_east_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6363,7 +6943,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_pa_east_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_radvel_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_radvel_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -6373,6 +6953,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_radvel_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_radvel_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6392,7 +6973,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_radvel_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_radvel_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_radvel_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6400,6 +6981,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_radvel_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6415,7 +6997,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_radvel_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_zvel_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_zvel_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -6425,6 +7007,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zvel_set(PyObject *SWIGUNUSEDPARM(self), Py int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_zvel_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6444,7 +7027,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zvel_set(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_zvel_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_zvel_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6452,6 +7035,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zvel_get(PyObject *SWIGUNUSEDPARM(self), Py PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6467,7 +7051,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zvel_get(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_zpzd_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_zpzd_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -6477,6 +7061,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zpzd_set(PyObject *SWIGUNUSEDPARM(self), Py int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_zpzd_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6496,7 +7081,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zpzd_set(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_zpzd_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_zpzd_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6504,6 +7089,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zpzd_get(PyObject *SWIGUNUSEDPARM(self), Py PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6519,7 +7105,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zpzd_get(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_zpr_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_zpr_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -6529,6 +7115,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zpr_set(PyObject *SWIGUNUSEDPARM(self), PyO int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_zpr_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6548,7 +7135,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zpr_set(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_WorldCoor_zpr_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_zpr_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6556,6 +7143,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zpr_get(PyObject *SWIGUNUSEDPARM(self), PyO PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6571,7 +7159,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zpr_get(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_WorldCoor_imflip_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_imflip_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -6581,6 +7169,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_imflip_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_imflip_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6600,7 +7189,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_imflip_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_imflip_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_imflip_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6608,6 +7197,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_imflip_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6623,7 +7213,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_imflip_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_prjcode_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_prjcode_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -6633,6 +7223,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_prjcode_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_prjcode_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6652,7 +7243,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_prjcode_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_prjcode_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_prjcode_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6660,6 +7251,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_prjcode_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6675,7 +7267,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_prjcode_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_latbase_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_latbase_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -6685,6 +7277,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_latbase_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_latbase_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6704,7 +7297,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_latbase_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_latbase_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_latbase_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6712,6 +7305,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_latbase_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6727,7 +7321,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_latbase_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_ncoeff1_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ncoeff1_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -6737,6 +7331,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ncoeff1_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_ncoeff1_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6756,7 +7351,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ncoeff1_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_ncoeff1_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ncoeff1_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6764,6 +7359,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ncoeff1_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6779,7 +7375,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ncoeff1_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_ncoeff2_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ncoeff2_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -6789,6 +7385,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ncoeff2_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_ncoeff2_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6808,7 +7405,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ncoeff2_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_ncoeff2_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ncoeff2_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6816,6 +7413,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ncoeff2_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6831,7 +7429,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ncoeff2_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_zpnp_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_zpnp_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -6841,6 +7439,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zpnp_set(PyObject *SWIGUNUSEDPARM(self), Py int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_zpnp_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6860,7 +7459,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zpnp_set(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_zpnp_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_zpnp_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6868,6 +7467,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zpnp_get(PyObject *SWIGUNUSEDPARM(self), Py PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6883,7 +7483,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_zpnp_get(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_changesys_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_changesys_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -6893,6 +7493,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_changesys_set(PyObject *SWIGUNUSEDPARM(self int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_changesys_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6912,7 +7513,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_changesys_set(PyObject *SWIGUNUSEDPARM(self } -SWIGINTERN PyObject *_wrap_WorldCoor_changesys_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_changesys_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6920,6 +7521,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_changesys_get(PyObject *SWIGUNUSEDPARM(self PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6935,7 +7537,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_changesys_get(PyObject *SWIGUNUSEDPARM(self } -SWIGINTERN PyObject *_wrap_WorldCoor_printsys_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_printsys_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -6945,6 +7547,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_printsys_set(PyObject *SWIGUNUSEDPARM(self) int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_printsys_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -6964,7 +7567,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_printsys_set(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_printsys_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_printsys_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -6972,6 +7575,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_printsys_get(PyObject *SWIGUNUSEDPARM(self) PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -6987,7 +7591,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_printsys_get(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_ndec_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ndec_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -6997,6 +7601,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ndec_set(PyObject *SWIGUNUSEDPARM(self), Py int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_ndec_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7016,7 +7621,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ndec_set(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_ndec_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ndec_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7024,6 +7629,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ndec_get(PyObject *SWIGUNUSEDPARM(self), Py PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7039,7 +7645,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ndec_get(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_degout_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_degout_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -7049,6 +7655,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_degout_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_degout_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7068,7 +7675,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_degout_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_degout_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_degout_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7076,6 +7683,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_degout_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7091,7 +7699,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_degout_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_tabsys_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_tabsys_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -7101,6 +7709,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_tabsys_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_tabsys_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7120,7 +7729,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_tabsys_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_tabsys_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_tabsys_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7128,6 +7737,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_tabsys_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7143,7 +7753,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_tabsys_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_rotmat_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_rotmat_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -7153,6 +7763,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_rotmat_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_rotmat_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7172,7 +7783,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_rotmat_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_rotmat_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_rotmat_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7180,6 +7791,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_rotmat_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7195,7 +7807,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_rotmat_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_coorflip_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_coorflip_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -7205,6 +7817,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_coorflip_set(PyObject *SWIGUNUSEDPARM(self) int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_coorflip_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7224,7 +7837,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_coorflip_set(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_coorflip_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_coorflip_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7232,6 +7845,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_coorflip_get(PyObject *SWIGUNUSEDPARM(self) PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7247,7 +7861,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_coorflip_get(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_offscl_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_offscl_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -7257,6 +7871,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_offscl_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_offscl_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7276,7 +7891,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_offscl_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_offscl_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_offscl_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7284,6 +7899,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_offscl_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7299,7 +7915,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_offscl_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_wcson_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_wcson_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -7309,6 +7925,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcson_set(PyObject *SWIGUNUSEDPARM(self), P int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_wcson_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7328,7 +7945,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcson_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_wcson_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_wcson_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7336,6 +7953,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcson_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7351,7 +7969,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcson_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_naxis_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_naxis_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -7361,6 +7979,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_naxis_set(PyObject *SWIGUNUSEDPARM(self), P int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_naxis_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7380,7 +7999,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_naxis_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_naxis_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_naxis_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7388,6 +8007,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_naxis_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7403,7 +8023,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_naxis_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_naxes_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_naxes_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -7413,6 +8033,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_naxes_set(PyObject *SWIGUNUSEDPARM(self), P int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_naxes_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7432,7 +8053,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_naxes_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_naxes_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_naxes_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7440,6 +8061,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_naxes_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7455,7 +8077,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_naxes_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_wcsproj_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_wcsproj_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -7465,6 +8087,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsproj_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_wcsproj_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7484,7 +8107,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsproj_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_wcsproj_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_wcsproj_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7492,6 +8115,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsproj_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7507,7 +8131,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsproj_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_linmode_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_linmode_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -7517,6 +8141,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_linmode_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_linmode_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7536,7 +8161,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_linmode_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_linmode_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_linmode_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7544,6 +8169,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_linmode_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7559,7 +8185,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_linmode_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_detector_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_detector_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -7569,6 +8195,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_detector_set(PyObject *SWIGUNUSEDPARM(self) int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_detector_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7588,7 +8215,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_detector_set(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_detector_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_detector_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7596,6 +8223,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_detector_get(PyObject *SWIGUNUSEDPARM(self) PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7611,16 +8239,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_detector_get(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_instrument_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_instrument_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - char *arg2 ; + char *arg2 = (char *) (char *)0 ; void *argp1 = 0 ; int res1 = 0 ; char temp2[32] ; int res2 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_instrument_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7641,7 +8270,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_instrument_set(PyObject *SWIGUNUSEDPARM(sel } -SWIGINTERN PyObject *_wrap_WorldCoor_instrument_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_instrument_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7649,6 +8278,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_instrument_get(PyObject *SWIGUNUSEDPARM(sel PyObject *swig_obj[1] ; char *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7670,16 +8300,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_instrument_get(PyObject *SWIGUNUSEDPARM(sel } -SWIGINTERN PyObject *_wrap_WorldCoor_ctype_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ctype_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - char (*arg2)[9] ; + char (*arg2)[9] = (char (*)[9]) (char (*)[9])0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_ctype_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7695,12 +8326,8 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ctype_set(PyObject *SWIGUNUSEDPARM(self), P if (arg2) { size_t ii = 0; for (; ii < (size_t)9; ++ii) { - if (arg2[ii]) { - size_t jj = 0; - for (; jj < (size_t)9; ++jj) arg1->ctype[ii][jj] = arg2[ii][jj]; - } else { - SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in variable '""ctype""' of type '""char [9][9]""'"); - } + size_t jj = 0; + for (; jj < (size_t)9; ++jj) arg1->ctype[ii][jj] = arg2[ii][jj]; } } else { SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in variable '""ctype""' of type '""char [9][9]""'"); @@ -7713,7 +8340,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ctype_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_ctype_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ctype_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7721,6 +8348,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ctype_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; char (*result)[9] = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7736,16 +8364,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ctype_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_c1type_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_c1type_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - char *arg2 ; + char *arg2 = (char *) (char *)0 ; void *argp1 = 0 ; int res1 = 0 ; char temp2[9] ; int res2 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_c1type_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7766,7 +8395,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_c1type_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_c1type_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_c1type_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7774,6 +8403,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_c1type_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; char *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7795,16 +8425,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_c1type_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_c2type_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_c2type_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - char *arg2 ; + char *arg2 = (char *) (char *)0 ; void *argp1 = 0 ; int res1 = 0 ; char temp2[9] ; int res2 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_c2type_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7825,7 +8456,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_c2type_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_c2type_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_c2type_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7833,6 +8464,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_c2type_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; char *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7854,16 +8486,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_c2type_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_ptype_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ptype_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - char *arg2 ; + char *arg2 = (char *) (char *)0 ; void *argp1 = 0 ; int res1 = 0 ; char temp2[9] ; int res2 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_ptype_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7884,7 +8517,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ptype_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_ptype_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ptype_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7892,6 +8525,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ptype_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; char *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7913,16 +8547,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ptype_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_units_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_units_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - char (*arg2)[32] ; + char (*arg2)[32] = (char (*)[32]) (char (*)[32])0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_units_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -7938,12 +8573,8 @@ SWIGINTERN PyObject *_wrap_WorldCoor_units_set(PyObject *SWIGUNUSEDPARM(self), P if (arg2) { size_t ii = 0; for (; ii < (size_t)9; ++ii) { - if (arg2[ii]) { - size_t jj = 0; - for (; jj < (size_t)32; ++jj) arg1->units[ii][jj] = arg2[ii][jj]; - } else { - SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in variable '""units""' of type '""char [9][32]""'"); - } + size_t jj = 0; + for (; jj < (size_t)32; ++jj) arg1->units[ii][jj] = arg2[ii][jj]; } } else { SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in variable '""units""' of type '""char [9][32]""'"); @@ -7956,7 +8587,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_units_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_units_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_units_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -7964,6 +8595,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_units_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; char (*result)[32] = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -7979,16 +8611,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_units_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_radecsys_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_radecsys_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - char *arg2 ; + char *arg2 = (char *) (char *)0 ; void *argp1 = 0 ; int res1 = 0 ; char temp2[32] ; int res2 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_radecsys_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8009,7 +8642,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_radecsys_set(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_radecsys_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_radecsys_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8017,6 +8650,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_radecsys_get(PyObject *SWIGUNUSEDPARM(self) PyObject *swig_obj[1] ; char *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8038,16 +8672,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_radecsys_get(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_radecout_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_radecout_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - char *arg2 ; + char *arg2 = (char *) (char *)0 ; void *argp1 = 0 ; int res1 = 0 ; char temp2[32] ; int res2 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_radecout_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8068,7 +8703,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_radecout_set(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_radecout_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_radecout_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8076,6 +8711,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_radecout_get(PyObject *SWIGUNUSEDPARM(self) PyObject *swig_obj[1] ; char *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8097,16 +8733,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_radecout_get(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_radecin_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_radecin_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - char *arg2 ; + char *arg2 = (char *) (char *)0 ; void *argp1 = 0 ; int res1 = 0 ; char temp2[32] ; int res2 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_radecin_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8127,7 +8764,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_radecin_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_radecin_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_radecin_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8135,6 +8772,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_radecin_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; char *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8156,7 +8794,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_radecin_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_eqin_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_eqin_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -8166,6 +8804,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_eqin_set(PyObject *SWIGUNUSEDPARM(self), Py int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_eqin_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8185,7 +8824,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_eqin_set(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_eqin_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_eqin_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8193,6 +8832,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_eqin_get(PyObject *SWIGUNUSEDPARM(self), Py PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8208,7 +8848,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_eqin_get(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_eqout_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_eqout_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; double arg2 ; @@ -8218,6 +8858,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_eqout_set(PyObject *SWIGUNUSEDPARM(self), P int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_eqout_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8237,7 +8878,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_eqout_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_eqout_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_eqout_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8245,6 +8886,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_eqout_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; double result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8260,7 +8902,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_eqout_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_sysin_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_sysin_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -8270,6 +8912,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_sysin_set(PyObject *SWIGUNUSEDPARM(self), P int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_sysin_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8289,7 +8932,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_sysin_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_sysin_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_sysin_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8297,6 +8940,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_sysin_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8312,7 +8956,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_sysin_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_syswcs_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_syswcs_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -8322,6 +8966,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_syswcs_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_syswcs_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8341,7 +8986,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_syswcs_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_syswcs_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_syswcs_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8349,6 +8994,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_syswcs_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8364,7 +9010,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_syswcs_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_sysout_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_sysout_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -8374,6 +9020,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_sysout_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_sysout_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8393,7 +9040,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_sysout_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_sysout_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_sysout_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8401,6 +9048,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_sysout_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8416,16 +9064,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_sysout_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_center_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_center_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - char *arg2 ; + char *arg2 = (char *) (char *)0 ; void *argp1 = 0 ; int res1 = 0 ; char temp2[32] ; int res2 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_center_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8446,7 +9095,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_center_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_center_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_center_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8454,6 +9103,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_center_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; char *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8475,7 +9125,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_center_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_wcsl_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_wcsl_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; struct wcsprm arg2 ; @@ -8485,6 +9135,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsl_set(PyObject *SWIGUNUSEDPARM(self), Py int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_wcsl_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8510,7 +9161,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsl_set(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_wcsl_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_wcsl_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8518,6 +9169,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsl_get(PyObject *SWIGUNUSEDPARM(self), Py PyObject *swig_obj[1] ; struct wcsprm result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8533,7 +9185,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsl_get(PyObject *SWIGUNUSEDPARM(self), Py } -SWIGINTERN PyObject *_wrap_WorldCoor_lin_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_lin_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; struct linprm arg2 ; @@ -8543,6 +9195,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_lin_set(PyObject *SWIGUNUSEDPARM(self), PyO int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_lin_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8568,7 +9221,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_lin_set(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_WorldCoor_lin_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_lin_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8576,6 +9229,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_lin_get(PyObject *SWIGUNUSEDPARM(self), PyO PyObject *swig_obj[1] ; struct linprm result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8591,7 +9245,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_lin_get(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_WorldCoor_cel_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_cel_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; struct celprm arg2 ; @@ -8601,6 +9255,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_cel_set(PyObject *SWIGUNUSEDPARM(self), PyO int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_cel_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8626,7 +9281,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_cel_set(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_WorldCoor_cel_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_cel_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8634,6 +9289,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_cel_get(PyObject *SWIGUNUSEDPARM(self), PyO PyObject *swig_obj[1] ; struct celprm result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8649,7 +9305,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_cel_get(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_WorldCoor_prj_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_prj_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; struct prjprm arg2 ; @@ -8659,6 +9315,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_prj_set(PyObject *SWIGUNUSEDPARM(self), PyO int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_prj_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8684,7 +9341,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_prj_set(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_WorldCoor_prj_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_prj_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8692,6 +9349,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_prj_get(PyObject *SWIGUNUSEDPARM(self), PyO PyObject *swig_obj[1] ; struct prjprm result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8707,7 +9365,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_prj_get(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_WorldCoor_lngcor_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_lngcor_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; struct IRAFsurface *arg2 = (struct IRAFsurface *) 0 ; @@ -8717,6 +9375,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_lngcor_set(PyObject *SWIGUNUSEDPARM(self), int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_lngcor_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8736,7 +9395,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_lngcor_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_lngcor_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_lngcor_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8744,6 +9403,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_lngcor_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; struct IRAFsurface *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8759,7 +9419,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_lngcor_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_latcor_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_latcor_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; struct IRAFsurface *arg2 = (struct IRAFsurface *) 0 ; @@ -8769,6 +9429,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_latcor_set(PyObject *SWIGUNUSEDPARM(self), int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_latcor_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8788,7 +9449,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_latcor_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_latcor_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_latcor_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8796,6 +9457,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_latcor_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; struct IRAFsurface *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8811,7 +9473,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_latcor_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_distcode_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_distcode_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -8821,6 +9483,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_distcode_set(PyObject *SWIGUNUSEDPARM(self) int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_distcode_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8840,7 +9503,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_distcode_set(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_distcode_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_distcode_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8848,6 +9511,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_distcode_get(PyObject *SWIGUNUSEDPARM(self) PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8863,7 +9527,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_distcode_get(PyObject *SWIGUNUSEDPARM(self) } -SWIGINTERN PyObject *_wrap_WorldCoor_distort_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_distort_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; struct Distort arg2 ; @@ -8873,6 +9537,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_distort_set(PyObject *SWIGUNUSEDPARM(self), int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_distort_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8898,7 +9563,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_distort_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_distort_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_distort_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8906,6 +9571,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_distort_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; struct Distort result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8921,16 +9587,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_distort_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_command_format_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_command_format_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - char **arg2 ; + char **arg2 = (char **) (char **)0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_command_format_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -8957,7 +9624,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_command_format_set(PyObject *SWIGUNUSEDPARM } -SWIGINTERN PyObject *_wrap_WorldCoor_command_format_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_command_format_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -8965,6 +9632,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_command_format_get(PyObject *SWIGUNUSEDPARM PyObject *swig_obj[1] ; char **result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -8980,16 +9648,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_command_format_get(PyObject *SWIGUNUSEDPARM } -SWIGINTERN PyObject *_wrap_WorldCoor_ltm_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ltm_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - double *arg2 ; + double *arg2 = (double *) (double *)0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_ltm_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -9016,7 +9685,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ltm_set(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_WorldCoor_ltm_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ltm_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -9024,6 +9693,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ltm_get(PyObject *SWIGUNUSEDPARM(self), PyO PyObject *swig_obj[1] ; double *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -9039,16 +9709,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ltm_get(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_WorldCoor_ltv_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ltv_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - double *arg2 ; + double *arg2 = (double *) (double *)0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_ltv_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -9075,7 +9746,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ltv_set(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_WorldCoor_ltv_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ltv_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -9083,6 +9754,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ltv_get(PyObject *SWIGUNUSEDPARM(self), PyO PyObject *swig_obj[1] ; double *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -9098,16 +9770,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ltv_get(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_WorldCoor_idpix_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_idpix_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - int *arg2 ; + int *arg2 = (int *) (int *)0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_idpix_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -9134,7 +9807,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_idpix_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_idpix_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_idpix_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -9142,6 +9815,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_idpix_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; int *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -9157,16 +9831,17 @@ SWIGINTERN PyObject *_wrap_WorldCoor_idpix_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_ndpix_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ndpix_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; - int *arg2 ; + int *arg2 = (int *) (int *)0 ; void *argp1 = 0 ; int res1 = 0 ; void *argp2 = 0 ; int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_ndpix_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -9193,7 +9868,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ndpix_set(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_ndpix_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_ndpix_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -9201,6 +9876,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ndpix_get(PyObject *SWIGUNUSEDPARM(self), P PyObject *swig_obj[1] ; int *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -9216,7 +9892,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_ndpix_get(PyObject *SWIGUNUSEDPARM(self), P } -SWIGINTERN PyObject *_wrap_WorldCoor_wcs_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_wcs_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; struct WorldCoor *arg2 = (struct WorldCoor *) 0 ; @@ -9226,6 +9902,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcs_set(PyObject *SWIGUNUSEDPARM(self), PyO int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_wcs_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -9245,7 +9922,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcs_set(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_WorldCoor_wcs_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_wcs_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -9253,6 +9930,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcs_get(PyObject *SWIGUNUSEDPARM(self), PyO PyObject *swig_obj[1] ; struct WorldCoor *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -9268,7 +9946,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcs_get(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_WorldCoor_wcsdep_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_wcsdep_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; struct WorldCoor *arg2 = (struct WorldCoor *) 0 ; @@ -9278,6 +9956,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsdep_set(PyObject *SWIGUNUSEDPARM(self), int res2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_wcsdep_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -9297,7 +9976,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsdep_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_wcsdep_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_wcsdep_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -9305,6 +9984,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsdep_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; struct WorldCoor *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -9320,7 +10000,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsdep_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_wcsname_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_wcsname_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; char *arg2 = (char *) 0 ; @@ -9331,6 +10011,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsname_set(PyObject *SWIGUNUSEDPARM(self), int alloc2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_wcsname_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -9342,7 +10023,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsname_set(PyObject *SWIGUNUSEDPARM(self), SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "WorldCoor_wcsname_set" "', argument " "2"" of type '" "char *""'"); } arg2 = (char *)(buf2); - if (arg1->wcsname) free((char*)arg1->wcsname); + free((char*)arg1->wcsname); if (arg2) { size_t size = strlen((const char *)(arg2)) + 1; arg1->wcsname = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size)); @@ -9358,7 +10039,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsname_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_wcsname_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_wcsname_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -9366,6 +10047,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsname_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; char *result = 0 ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -9381,7 +10063,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcsname_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_wcschar_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_wcschar_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; char arg2 ; @@ -9391,6 +10073,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcschar_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_wcschar_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -9410,7 +10093,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcschar_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_wcschar_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_wcschar_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -9418,6 +10101,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcschar_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; char result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -9433,7 +10117,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_wcschar_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_logwcs_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_logwcs_set(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; int arg2 ; @@ -9443,6 +10127,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_logwcs_set(PyObject *SWIGUNUSEDPARM(self), int ecode2 = 0 ; PyObject *swig_obj[2] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "WorldCoor_logwcs_set", 2, 2, swig_obj)) SWIG_fail; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); if (!SWIG_IsOK(res1)) { @@ -9462,7 +10147,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_logwcs_set(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_WorldCoor_logwcs_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_WorldCoor_logwcs_get(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; @@ -9470,6 +10155,7 @@ SWIGINTERN PyObject *_wrap_WorldCoor_logwcs_get(PyObject *SWIGUNUSEDPARM(self), PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, 0 | 0 ); @@ -9485,10 +10171,11 @@ SWIGINTERN PyObject *_wrap_WorldCoor_logwcs_get(PyObject *SWIGUNUSEDPARM(self), } -SWIGINTERN PyObject *_wrap_new_WorldCoor(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_new_WorldCoor(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *result = 0 ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "new_WorldCoor", 0, 0, 0)) SWIG_fail; result = (struct WorldCoor *)calloc(1, sizeof(struct WorldCoor)); resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_WorldCoor, SWIG_POINTER_NEW | 0 ); @@ -9498,13 +10185,14 @@ SWIGINTERN PyObject *_wrap_new_WorldCoor(PyObject *SWIGUNUSEDPARM(self), PyObjec } -SWIGINTERN PyObject *_wrap_delete_WorldCoor(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_delete_WorldCoor(PyObject *self, PyObject *args) { PyObject *resultobj = 0; struct WorldCoor *arg1 = (struct WorldCoor *) 0 ; void *argp1 = 0 ; int res1 = 0 ; PyObject *swig_obj[1] ; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_WorldCoor, SWIG_POINTER_DISOWN | 0 ); @@ -9532,7 +10220,6 @@ SWIGINTERN PyObject *WorldCoor_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject } static PyMethodDef SwigMethods[] = { - { "SWIG_PyInstanceMethod_New", SWIG_PyInstanceMethod_New, METH_O, NULL}, { "new_doubleArray", _wrap_new_doubleArray, METH_O, "new_doubleArray(nelements) -> double *"}, { "delete_doubleArray", _wrap_delete_doubleArray, METH_O, "delete_doubleArray(ary)"}, { "doubleArray_getitem", _wrap_doubleArray_getitem, METH_VARARGS, "doubleArray_getitem(ary, index) -> double"}, @@ -9759,10 +10446,6 @@ static PyMethodDef SwigMethods[] = { { NULL, NULL, 0, NULL } }; -static PyMethodDef SwigMethods_proxydocs[] = { - { NULL, NULL, 0, NULL } -}; - /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */ @@ -9891,9 +10574,12 @@ extern "C" { #define SWIGRUNTIME_DEBUG #endif +#ifndef SWIG_INIT_CLIENT_DATA_TYPE +#define SWIG_INIT_CLIENT_DATA_TYPE void * +#endif SWIGRUNTIME void -SWIG_InitializeModule(void *clientdata) { +SWIG_InitializeModule(SWIG_INIT_CLIENT_DATA_TYPE clientdata) { size_t i; swig_module_info *module_head, *iter; int init; @@ -10076,220 +10762,6 @@ SWIG_PropagateClientData(void) { extern "C" { #endif - /* Python-specific SWIG API */ -#define SWIG_newvarlink() SWIG_Python_newvarlink() -#define SWIG_addvarlink(p, name, get_attr, set_attr) SWIG_Python_addvarlink(p, name, get_attr, set_attr) -#define SWIG_InstallConstants(d, constants) SWIG_Python_InstallConstants(d, constants) - - /* ----------------------------------------------------------------------------- - * global variable support code. - * ----------------------------------------------------------------------------- */ - - typedef struct swig_globalvar { - char *name; /* Name of global variable */ - PyObject *(*get_attr)(void); /* Return the current value */ - int (*set_attr)(PyObject *); /* Set the value */ - struct swig_globalvar *next; - } swig_globalvar; - - typedef struct swig_varlinkobject { - PyObject_HEAD - swig_globalvar *vars; - } swig_varlinkobject; - - SWIGINTERN PyObject * - swig_varlink_repr(swig_varlinkobject *SWIGUNUSEDPARM(v)) { -#if PY_VERSION_HEX >= 0x03000000 - return PyUnicode_InternFromString(""); -#else - return PyString_FromString(""); -#endif - } - - SWIGINTERN PyObject * - swig_varlink_str(swig_varlinkobject *v) { -#if PY_VERSION_HEX >= 0x03000000 - PyObject *str = PyUnicode_InternFromString("("); - PyObject *tail; - PyObject *joined; - swig_globalvar *var; - for (var = v->vars; var; var=var->next) { - tail = PyUnicode_FromString(var->name); - joined = PyUnicode_Concat(str, tail); - Py_DecRef(str); - Py_DecRef(tail); - str = joined; - if (var->next) { - tail = PyUnicode_InternFromString(", "); - joined = PyUnicode_Concat(str, tail); - Py_DecRef(str); - Py_DecRef(tail); - str = joined; - } - } - tail = PyUnicode_InternFromString(")"); - joined = PyUnicode_Concat(str, tail); - Py_DecRef(str); - Py_DecRef(tail); - str = joined; -#else - PyObject *str = PyString_FromString("("); - swig_globalvar *var; - for (var = v->vars; var; var=var->next) { - PyString_ConcatAndDel(&str,PyString_FromString(var->name)); - if (var->next) PyString_ConcatAndDel(&str,PyString_FromString(", ")); - } - PyString_ConcatAndDel(&str,PyString_FromString(")")); -#endif - return str; - } - - SWIGINTERN void - swig_varlink_dealloc(swig_varlinkobject *v) { - swig_globalvar *var = v->vars; - while (var) { - swig_globalvar *n = var->next; - free(var->name); - free(var); - var = n; - } - } - - SWIGINTERN PyObject * - swig_varlink_getattr(swig_varlinkobject *v, char *n) { - PyObject *res = NULL; - swig_globalvar *var = v->vars; - while (var) { - if (strcmp(var->name,n) == 0) { - res = (*var->get_attr)(); - break; - } - var = var->next; - } - if (res == NULL && !PyErr_Occurred()) { - PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n); - } - return res; - } - - SWIGINTERN int - swig_varlink_setattr(swig_varlinkobject *v, char *n, PyObject *p) { - int res = 1; - swig_globalvar *var = v->vars; - while (var) { - if (strcmp(var->name,n) == 0) { - res = (*var->set_attr)(p); - break; - } - var = var->next; - } - if (res == 1 && !PyErr_Occurred()) { - PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n); - } - return res; - } - - SWIGINTERN PyTypeObject* - swig_varlink_type(void) { - static char varlink__doc__[] = "Swig var link object"; - static PyTypeObject varlink_type; - static int type_init = 0; - if (!type_init) { - const PyTypeObject tmp = { -#if PY_VERSION_HEX >= 0x03000000 - PyVarObject_HEAD_INIT(NULL, 0) -#else - PyObject_HEAD_INIT(NULL) - 0, /* ob_size */ -#endif - "swigvarlink", /* tp_name */ - sizeof(swig_varlinkobject), /* tp_basicsize */ - 0, /* tp_itemsize */ - (destructor) swig_varlink_dealloc, /* tp_dealloc */ - 0, /* tp_print */ - (getattrfunc) swig_varlink_getattr, /* tp_getattr */ - (setattrfunc) swig_varlink_setattr, /* tp_setattr */ - 0, /* tp_compare */ - (reprfunc) swig_varlink_repr, /* tp_repr */ - 0, /* tp_as_number */ - 0, /* tp_as_sequence */ - 0, /* tp_as_mapping */ - 0, /* tp_hash */ - 0, /* tp_call */ - (reprfunc) swig_varlink_str, /* tp_str */ - 0, /* tp_getattro */ - 0, /* tp_setattro */ - 0, /* tp_as_buffer */ - 0, /* tp_flags */ - varlink__doc__, /* tp_doc */ - 0, /* tp_traverse */ - 0, /* tp_clear */ - 0, /* tp_richcompare */ - 0, /* tp_weaklistoffset */ - 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* tp_iter -> tp_weaklist */ - 0, /* tp_del */ - 0, /* tp_version_tag */ -#if PY_VERSION_HEX >= 0x03040000 - 0, /* tp_finalize */ -#endif -#if PY_VERSION_HEX >= 0x03080000 - 0, /* tp_vectorcall */ -#endif -#if (PY_VERSION_HEX >= 0x03080000) && (PY_VERSION_HEX < 0x03090000) - 0, /* tp_print */ -#endif -#ifdef COUNT_ALLOCS - 0, /* tp_allocs */ - 0, /* tp_frees */ - 0, /* tp_maxalloc */ - 0, /* tp_prev */ - 0 /* tp_next */ -#endif - }; - varlink_type = tmp; - type_init = 1; - if (PyType_Ready(&varlink_type) < 0) - return NULL; - } - return &varlink_type; - } - - /* Create a variable linking object for use later */ - SWIGINTERN PyObject * - SWIG_Python_newvarlink(void) { - swig_varlinkobject *result = PyObject_NEW(swig_varlinkobject, swig_varlink_type()); - if (result) { - result->vars = 0; - } - return ((PyObject*) result); - } - - SWIGINTERN void - SWIG_Python_addvarlink(PyObject *p, const char *name, PyObject *(*get_attr)(void), int (*set_attr)(PyObject *p)) { - swig_varlinkobject *v = (swig_varlinkobject *) p; - swig_globalvar *gv = (swig_globalvar *) malloc(sizeof(swig_globalvar)); - if (gv) { - size_t size = strlen(name)+1; - gv->name = (char *)malloc(size); - if (gv->name) { - memcpy(gv->name, name, size); - gv->get_attr = get_attr; - gv->set_attr = set_attr; - gv->next = v->vars; - } - } - v->vars = gv; - } - - SWIGINTERN PyObject * - SWIG_globals(void) { - static PyObject *globals = 0; - if (!globals) { - globals = SWIG_newvarlink(); - } - return globals; - } - /* ----------------------------------------------------------------------------- * constants/methods manipulation * ----------------------------------------------------------------------------- */ @@ -10318,15 +10790,12 @@ extern "C" { } } - /* -----------------------------------------------------------------------------*/ - /* Fix SwigMethods to carry the callback ptrs when needed */ - /* -----------------------------------------------------------------------------*/ + /* ----------------------------------------------------------------------------- + * Patch %callback methods' docstrings to hold the callback ptrs + * -----------------------------------------------------------------------------*/ SWIGINTERN void - SWIG_Python_FixMethods(PyMethodDef *methods, - swig_const_info *const_table, - swig_type_info **types, - swig_type_info **types_initial) { + SWIG_Python_FixMethods(PyMethodDef *methods, const swig_const_info *const_table, swig_type_info **types, swig_type_info **types_initial) { size_t i; for (i = 0; methods[i].ml_name; ++i) { const char *c = methods[i].ml_doc; @@ -10334,7 +10803,7 @@ extern "C" { c = strstr(c, "swig_ptr: "); if (c) { int j; - swig_const_info *ci = 0; + const swig_const_info *ci = 0; const char *name = c + 10; for (j = 0; const_table[j].type; ++j) { if (strncmp(const_table[j].name, name, @@ -10366,68 +10835,13 @@ extern "C" { } } - /* ----------------------------------------------------------------------------- - * Method creation and docstring support functions - * ----------------------------------------------------------------------------- */ - - /* ----------------------------------------------------------------------------- - * Function to find the method definition with the correct docstring for the - * proxy module as opposed to the low-level API - * ----------------------------------------------------------------------------- */ - - SWIGINTERN PyMethodDef *SWIG_PythonGetProxyDoc(const char *name) { - /* Find the function in the modified method table */ - size_t offset = 0; - int found = 0; - while (SwigMethods_proxydocs[offset].ml_meth != NULL) { - if (strcmp(SwigMethods_proxydocs[offset].ml_name, name) == 0) { - found = 1; - break; - } - offset++; - } - /* Use the copy with the modified docstring if available */ - return found ? &SwigMethods_proxydocs[offset] : NULL; - } - - /* ----------------------------------------------------------------------------- - * Wrapper of PyInstanceMethod_New() used in Python 3 - * It is exported to the generated module, used for -fastproxy - * ----------------------------------------------------------------------------- */ - - SWIGINTERN PyObject *SWIG_PyInstanceMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func) { - if (PyCFunction_Check(func)) { - PyCFunctionObject *funcobj = (PyCFunctionObject *)func; - PyMethodDef *ml = SWIG_PythonGetProxyDoc(funcobj->m_ml->ml_name); - if (ml) - func = PyCFunction_NewEx(ml, funcobj->m_self, funcobj->m_module); - } -#if PY_VERSION_HEX >= 0x03000000 - return PyInstanceMethod_New(func); -#else - return PyMethod_New(func, NULL, NULL); -#endif - } - - /* ----------------------------------------------------------------------------- - * Wrapper of PyStaticMethod_New() - * It is exported to the generated module, used for -fastproxy - * ----------------------------------------------------------------------------- */ - - SWIGINTERN PyObject *SWIG_PyStaticMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func) { - if (PyCFunction_Check(func)) { - PyCFunctionObject *funcobj = (PyCFunctionObject *)func; - PyMethodDef *ml = SWIG_PythonGetProxyDoc(funcobj->m_ml->ml_name); - if (ml) - func = PyCFunction_NewEx(ml, funcobj->m_self, funcobj->m_module); - } - return PyStaticMethod_New(func); - } - #ifdef __cplusplus } #endif + + + /* -----------------------------------------------------------------------------* * Partial Init method * -----------------------------------------------------------------------------*/ diff --git a/PyWCSTools/wcssubs-3.9.5/wcscon.c b/PyWCSTools/wcssubs-3.9.7/wcscon.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/wcscon.c rename to PyWCSTools/wcssubs-3.9.7/wcscon.c diff --git a/PyWCSTools/wcssubs-3.9.5/wcscon.i b/PyWCSTools/wcssubs-3.9.7/wcscon.i similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/wcscon.i rename to PyWCSTools/wcssubs-3.9.7/wcscon.i diff --git a/PyWCSTools/wcssubs-3.9.5/wcscon_wrap.c b/PyWCSTools/wcssubs-3.9.7/wcscon_wrap.c similarity index 81% rename from PyWCSTools/wcssubs-3.9.5/wcscon_wrap.c rename to PyWCSTools/wcssubs-3.9.7/wcscon_wrap.c index eec67f9..df470e0 100644 --- a/PyWCSTools/wcssubs-3.9.5/wcscon_wrap.c +++ b/PyWCSTools/wcssubs-3.9.7/wcscon_wrap.c @@ -1,18 +1,14 @@ /* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 4.0.2 + * This file was automatically generated by SWIG (https://www.swig.org). + * Version 4.2.1 * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. + * Do not make changes to this file unless you know what you are doing - modify + * the SWIG interface file instead. * ----------------------------------------------------------------------------- */ -#ifndef SWIGPYTHON +#define SWIG_VERSION 0x040201 #define SWIGPYTHON -#endif - #define SWIG_PYTHON_DIRECTOR_NO_VTABLE /* ----------------------------------------------------------------------------- @@ -139,14 +135,62 @@ # pragma warning disable 592 #endif +#if defined(__cplusplus) && __cplusplus >=201103L +# define SWIG_NULLPTR nullptr +#else +# define SWIG_NULLPTR NULL +#endif + +/* ----------------------------------------------------------------------------- + * swigcompat.swg + * + * Macros to provide support compatibility with older C and C++ standards. + * ----------------------------------------------------------------------------- */ + +/* C99 and C++11 should provide snprintf, but define SWIG_NO_SNPRINTF + * if you're missing it. + */ +#if ((defined __STDC_VERSION__ && __STDC_VERSION__ >= 199901L) || \ + (defined __cplusplus && __cplusplus >= 201103L) || \ + defined SWIG_HAVE_SNPRINTF) && \ + !defined SWIG_NO_SNPRINTF +# define SWIG_snprintf(O,S,F,A) snprintf(O,S,F,A) +# define SWIG_snprintf2(O,S,F,A,B) snprintf(O,S,F,A,B) +#else +/* Fallback versions ignore the buffer size, but most of our uses either have a + * fixed maximum possible size or dynamically allocate a buffer that's large + * enough. + */ +# define SWIG_snprintf(O,S,F,A) sprintf(O,F,A) +# define SWIG_snprintf2(O,S,F,A,B) sprintf(O,F,A,B) +#endif + #if defined(__GNUC__) && defined(_WIN32) && !defined(SWIG_PYTHON_NO_HYPOT_WORKAROUND) /* Workaround for '::hypot' has not been declared', see https://bugs.python.org/issue11566 */ # include #endif +#if !defined(PY_SSIZE_T_CLEAN) && !defined(SWIG_NO_PY_SSIZE_T_CLEAN) +#define PY_SSIZE_T_CLEAN +#endif + +#if __GNUC__ >= 7 +#pragma GCC diagnostic push +#if defined(__cplusplus) && __cplusplus >=201703L +#pragma GCC diagnostic ignored "-Wregister" /* For python-2.7 headers that use register */ +#endif +#endif + #if defined(_DEBUG) && defined(SWIG_PYTHON_INTERPRETER_NO_DEBUG) /* Use debug wrappers with the Python release dll */ + +#if defined(_MSC_VER) && _MSC_VER >= 1929 +/* Workaround compilation errors when redefining _DEBUG in MSVC 2019 version 16.10 and later + * See https://github.com/swig/swig/issues/2090 */ +# include +#endif + # undef _DEBUG # include # define _DEBUG 1 @@ -154,6 +198,12 @@ # include #endif +#if __GNUC__ >= 7 +#pragma GCC diagnostic pop +#endif + +#include + /* ----------------------------------------------------------------------------- * swigrun.swg * @@ -200,6 +250,8 @@ #define SWIG_POINTER_DISOWN 0x1 #define SWIG_CAST_NEW_MEMORY 0x2 #define SWIG_POINTER_NO_NULL 0x4 +#define SWIG_POINTER_CLEAR 0x8 +#define SWIG_POINTER_RELEASE (SWIG_POINTER_CLEAR | SWIG_POINTER_DISOWN) /* Flags for new pointer objects */ #define SWIG_POINTER_OWN 0x1 @@ -271,7 +323,7 @@ SWIG errors code. Finally, if the SWIG_CASTRANK_MODE is enabled, the result code - allows to return the 'cast rank', for example, if you have this + allows returning the 'cast rank', for example, if you have this int food(double) int fooi(int); @@ -285,7 +337,13 @@ */ #define SWIG_OK (0) +/* Runtime errors are < 0 */ #define SWIG_ERROR (-1) +/* Errors in range -1 to -99 are in swigerrors.swg (errors for all languages including those not using the runtime) */ +/* Errors in range -100 to -199 are language specific errors defined in *errors.swg */ +/* Errors < -200 are generic runtime specific errors */ +#define SWIG_ERROR_RELEASE_NOT_OWNED (-200) + #define SWIG_IsOK(r) (r >= 0) #define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError) @@ -293,14 +351,14 @@ #define SWIG_CASTRANKLIMIT (1 << 8) /* The NewMask denotes the object was created (using new/malloc) */ #define SWIG_NEWOBJMASK (SWIG_CASTRANKLIMIT << 1) -/* The TmpMask is for in/out typemaps that use temporal objects */ +/* The TmpMask is for in/out typemaps that use temporary objects */ #define SWIG_TMPOBJMASK (SWIG_NEWOBJMASK << 1) /* Simple returning values */ #define SWIG_BADOBJ (SWIG_ERROR) #define SWIG_OLDOBJ (SWIG_OK) #define SWIG_NEWOBJ (SWIG_OK | SWIG_NEWOBJMASK) #define SWIG_TMPOBJ (SWIG_OK | SWIG_TMPOBJMASK) -/* Check, add and del mask methods */ +/* Check, add and del object mask methods */ #define SWIG_AddNewMask(r) (SWIG_IsOK(r) ? (r | SWIG_NEWOBJMASK) : r) #define SWIG_DelNewMask(r) (SWIG_IsOK(r) ? (r & ~SWIG_NEWOBJMASK) : r) #define SWIG_IsNewObj(r) (SWIG_IsOK(r) && (r & SWIG_NEWOBJMASK)) @@ -446,7 +504,7 @@ SWIG_TypeCheck(const char *c, swig_type_info *ty) { Identical to SWIG_TypeCheck, except strcmp is replaced with a pointer comparison */ SWIGRUNTIME swig_cast_info * -SWIG_TypeCheckStruct(swig_type_info *from, swig_type_info *ty) { +SWIG_TypeCheckStruct(const swig_type_info *from, swig_type_info *ty) { if (ty) { swig_cast_info *iter = ty->cast; while (iter) { @@ -506,9 +564,9 @@ SWIG_TypeName(const swig_type_info *ty) { SWIGRUNTIME const char * SWIG_TypePrettyName(const swig_type_info *type) { /* The "str" field contains the equivalent pretty names of the - type, separated by vertical-bar characters. We choose - to print the last name, as it is often (?) the most - specific. */ + type, separated by vertical-bar characters. Choose the last + name. It should be the most specific; a fully resolved name + but not necessarily with default template parameters expanded. */ if (!type) return NULL; if (type->str != NULL) { const char *last_name = type->str; @@ -728,7 +786,7 @@ SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) { } #endif -/* Errors in SWIG */ +/* SWIG Errors applicable to all language modules, values are reserved from -1 to -99 */ #define SWIG_UnknownError -1 #define SWIG_IOError -2 #define SWIG_RuntimeError -3 @@ -744,7 +802,6 @@ SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) { #define SWIG_NullReferenceError -13 - /* Compatibility macros for Python 3 */ #if PY_VERSION_HEX >= 0x03000000 @@ -760,7 +817,6 @@ SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) { #define PyString_Size(str) PyBytes_Size(str) #define PyString_InternFromString(key) PyUnicode_InternFromString(key) #define Py_TPFLAGS_HAVE_CLASS Py_TPFLAGS_BASETYPE -#define PyString_AS_STRING(x) PyUnicode_AS_STRING(x) #define _PyLong_FromSsize_t(x) PyLong_FromSsize_t(x) #endif @@ -778,40 +834,29 @@ SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) { #endif -/* Warning: This function will allocate a new string in Python 3, - * so please call SWIG_Python_str_DelForPy3(x) to free the space. - */ -SWIGINTERN char* -SWIG_Python_str_AsChar(PyObject *str) +/* Wrapper around PyUnicode_AsUTF8AndSize - call Py_XDECREF on the returned pbytes when finished with the returned string */ +SWIGINTERN const char * +SWIG_PyUnicode_AsUTF8AndSize(PyObject *str, Py_ssize_t *psize, PyObject **pbytes) { #if PY_VERSION_HEX >= 0x03030000 - return (char *)PyUnicode_AsUTF8(str); -#elif PY_VERSION_HEX >= 0x03000000 - char *newstr = 0; - str = PyUnicode_AsUTF8String(str); - if (str) { - char *cstr; - Py_ssize_t len; - if (PyBytes_AsStringAndSize(str, &cstr, &len) != -1) { - newstr = (char *) malloc(len+1); - if (newstr) - memcpy(newstr, cstr, len+1); - } - Py_XDECREF(str); - } - return newstr; +# if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x030A0000 + *pbytes = NULL; + return PyUnicode_AsUTF8AndSize(str, psize); +# else + *pbytes = PyUnicode_AsUTF8String(str); + const char *chars = *pbytes ? PyBytes_AsString(*pbytes) : NULL; + if (chars && psize) + *psize = PyBytes_Size(*pbytes); + return chars; +# endif #else - return PyString_AsString(str); + char *chars = NULL; + *pbytes = NULL; + PyString_AsStringAndSize(str, &chars, psize); + return chars; #endif } -#if PY_VERSION_HEX >= 0x03030000 || PY_VERSION_HEX < 0x03000000 -# define SWIG_Python_str_DelForPy3(x) -#else -# define SWIG_Python_str_DelForPy3(x) free( (void*) (x) ) -#endif - - SWIGINTERN PyObject* SWIG_Python_str_FromChar(const char *c) { @@ -826,10 +871,14 @@ SWIG_Python_str_FromChar(const char *c) # define PyObject_DEL PyObject_Del #endif -// SWIGPY_USE_CAPSULE is no longer used within SWIG itself, but some user -// interface files check for it. +/* SWIGPY_USE_CAPSULE is no longer used within SWIG itself, but some user interface files check for it. */ # define SWIGPY_USE_CAPSULE -# define SWIGPY_CAPSULE_NAME ("swig_runtime_data" SWIG_RUNTIME_VERSION ".type_pointer_capsule" SWIG_TYPE_TABLE_NAME) +#ifdef SWIGPYTHON_BUILTIN +# define SWIGPY_CAPSULE_ATTR_NAME "type_pointer_capsule_builtin" SWIG_TYPE_TABLE_NAME +#else +# define SWIGPY_CAPSULE_ATTR_NAME "type_pointer_capsule" SWIG_TYPE_TABLE_NAME +#endif +# define SWIGPY_CAPSULE_NAME ("swig_runtime_data" SWIG_RUNTIME_VERSION "." SWIGPY_CAPSULE_ATTR_NAME) #if PY_VERSION_HEX < 0x03020000 #define PyDescr_TYPE(x) (((PyDescrObject *)(x))->d_type) @@ -837,6 +886,20 @@ SWIG_Python_str_FromChar(const char *c) #define Py_hash_t long #endif +#ifdef Py_LIMITED_API +# define PyTuple_GET_ITEM PyTuple_GetItem +/* Note that PyTuple_SetItem() has different semantics from PyTuple_SET_ITEM as it decref's the original tuple item, so in general they cannot be used + interchangeably. However in SWIG-generated code PyTuple_SET_ITEM is only used with newly initialized tuples without any items and for them this does work. */ +# define PyTuple_SET_ITEM PyTuple_SetItem +# define PyTuple_GET_SIZE PyTuple_Size +# define PyCFunction_GET_FLAGS PyCFunction_GetFlags +# define PyCFunction_GET_FUNCTION PyCFunction_GetFunction +# define PyCFunction_GET_SELF PyCFunction_GetSelf +# define PyList_GET_ITEM PyList_GetItem +# define PyList_SET_ITEM PyList_SetItem +# define PySliceObject PyObject +#endif + /* ----------------------------------------------------------------------------- * error manipulation * ----------------------------------------------------------------------------- */ @@ -896,14 +959,15 @@ SWIG_Python_AddErrorMsg(const char* mesg) PyErr_Fetch(&type, &value, &traceback); if (value) { PyObject *old_str = PyObject_Str(value); - const char *tmp = SWIG_Python_str_AsChar(old_str); + PyObject *bytes = NULL; + const char *tmp = SWIG_PyUnicode_AsUTF8AndSize(old_str, NULL, &bytes); PyErr_Clear(); Py_XINCREF(type); if (tmp) PyErr_Format(type, "%s %s", tmp, mesg); else PyErr_Format(type, "%s", mesg); - SWIG_Python_str_DelForPy3(tmp); + Py_XDECREF(bytes); Py_DECREF(old_str); Py_DECREF(value); } else { @@ -934,8 +998,12 @@ SWIG_Python_RaiseOrModifyTypeError(const char *message) #else newvalue = PyString_FromFormat("%s\nAdditional information:\n%s", PyString_AsString(value), message); #endif - Py_XDECREF(value); - PyErr_Restore(type, newvalue, traceback); + if (newvalue) { + Py_XDECREF(value); + PyErr_Restore(type, newvalue, traceback); + } else { + PyErr_Restore(type, value, traceback); + } } else { /* Raise TypeError using given message */ PyErr_SetString(PyExc_TypeError, message); @@ -952,8 +1020,12 @@ SWIG_Python_RaiseOrModifyTypeError(const char *message) # define SWIG_PYTHON_USE_GIL # endif # if defined(SWIG_PYTHON_USE_GIL) /* Use PyGILState threads calls */ -# ifndef SWIG_PYTHON_INITIALIZE_THREADS -# define SWIG_PYTHON_INITIALIZE_THREADS PyEval_InitThreads() +# if !defined(SWIG_PYTHON_INITIALIZE_THREADS) +# if PY_VERSION_HEX < 0x03070000 +# define SWIG_PYTHON_INITIALIZE_THREADS PyEval_InitThreads() +# else +# define SWIG_PYTHON_INITIALIZE_THREADS +# endif # endif # ifdef __cplusplus /* C++ code */ class SWIG_Python_Thread_Block { @@ -968,7 +1040,7 @@ SWIG_Python_RaiseOrModifyTypeError(const char *message) bool status; PyThreadState *save; public: - void end() { if (status) { PyEval_RestoreThread(save); status = false; }} + void end() { if (status) { status = false; PyEval_RestoreThread(save); }} SWIG_Python_Thread_Allow() : status(true), save(PyEval_SaveThread()) {} ~SWIG_Python_Thread_Allow() { end(); } }; @@ -1051,8 +1123,8 @@ typedef struct swig_const_info { # error "This version of SWIG only supports Python >= 2.7" #endif -#if PY_VERSION_HEX >= 0x03000000 && PY_VERSION_HEX < 0x03020000 -# error "This version of SWIG only supports Python 3 >= 3.2" +#if PY_VERSION_HEX >= 0x03000000 && PY_VERSION_HEX < 0x03030000 +# error "This version of SWIG only supports Python 3 >= 3.3" #endif /* Common SWIG API */ @@ -1167,7 +1239,12 @@ SWIG_Python_AppendOutput(PyObject* result, PyObject* obj) { if (!PyList_Check(result)) { PyObject *o2 = result; result = PyList_New(1); - PyList_SetItem(result, 0, o2); + if (result) { + PyList_SET_ITEM(result, 0, o2); + } else { + Py_DECREF(obj); + return o2; + } } PyList_Append(result,obj); Py_DECREF(obj); @@ -1249,6 +1326,261 @@ SWIG_Python_CheckNoKeywords(PyObject *kwargs, const char *name) { #define SWIG_STATIC_POINTER(var) var = 0; if (!var) var #endif +#ifdef __cplusplus +extern "C" { +#endif + +/* Python-specific SWIG API */ +#define SWIG_newvarlink() SWIG_Python_newvarlink() +#define SWIG_addvarlink(p, name, get_attr, set_attr) SWIG_Python_addvarlink(p, name, get_attr, set_attr) +#define SWIG_InstallConstants(d, constants) SWIG_Python_InstallConstants(d, constants) + +/* ----------------------------------------------------------------------------- + * global variable support code. + * ----------------------------------------------------------------------------- */ + +typedef struct swig_globalvar { + char *name; /* Name of global variable */ + PyObject *(*get_attr)(void); /* Return the current value */ + int (*set_attr)(PyObject *); /* Set the value */ + struct swig_globalvar *next; +} swig_globalvar; + +typedef struct swig_varlinkobject { + PyObject_HEAD + swig_globalvar *vars; +} swig_varlinkobject; + +SWIGINTERN PyObject * +swig_varlink_repr(PyObject *SWIGUNUSEDPARM(v)) { +#if PY_VERSION_HEX >= 0x03000000 + return PyUnicode_InternFromString(""); +#else + return PyString_FromString(""); +#endif +} + +SWIGINTERN PyObject * +swig_varlink_str(PyObject *o) { + swig_varlinkobject *v = (swig_varlinkobject *) o; +#if PY_VERSION_HEX >= 0x03000000 + PyObject *str = PyUnicode_InternFromString("("); + PyObject *tail; + PyObject *joined; + swig_globalvar *var; + for (var = v->vars; var; var=var->next) { + tail = PyUnicode_FromString(var->name); + joined = PyUnicode_Concat(str, tail); + Py_DecRef(str); + Py_DecRef(tail); + str = joined; + if (var->next) { + tail = PyUnicode_InternFromString(", "); + joined = PyUnicode_Concat(str, tail); + Py_DecRef(str); + Py_DecRef(tail); + str = joined; + } + } + tail = PyUnicode_InternFromString(")"); + joined = PyUnicode_Concat(str, tail); + Py_DecRef(str); + Py_DecRef(tail); + str = joined; +#else + PyObject *str = PyString_FromString("("); + swig_globalvar *var; + for (var = v->vars; var; var=var->next) { + PyString_ConcatAndDel(&str,PyString_FromString(var->name)); + if (var->next) PyString_ConcatAndDel(&str,PyString_FromString(", ")); + } + PyString_ConcatAndDel(&str,PyString_FromString(")")); +#endif + return str; +} + +SWIGINTERN void +swig_varlink_dealloc(PyObject *o) { + swig_varlinkobject *v = (swig_varlinkobject *) o; + swig_globalvar *var = v->vars; + while (var) { + swig_globalvar *n = var->next; + free(var->name); + free(var); + var = n; + } +} + +SWIGINTERN PyObject * +swig_varlink_getattr(PyObject *o, char *n) { + swig_varlinkobject *v = (swig_varlinkobject *) o; + PyObject *res = NULL; + swig_globalvar *var = v->vars; + while (var) { + if (strcmp(var->name,n) == 0) { + res = (*var->get_attr)(); + break; + } + var = var->next; + } + if (res == NULL && !PyErr_Occurred()) { + PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n); + } + return res; +} + +SWIGINTERN int +swig_varlink_setattr(PyObject *o, char *n, PyObject *p) { + swig_varlinkobject *v = (swig_varlinkobject *) o; + int res = 1; + swig_globalvar *var = v->vars; + while (var) { + if (strcmp(var->name,n) == 0) { + res = (*var->set_attr)(p); + break; + } + var = var->next; + } + if (res == 1 && !PyErr_Occurred()) { + PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n); + } + return res; +} + +SWIGINTERN PyTypeObject* +swig_varlink_type(void) { + static char varlink__doc__[] = "Swig var link object"; +#ifndef Py_LIMITED_API + static PyTypeObject varlink_type; + static int type_init = 0; + if (!type_init) { + const PyTypeObject tmp = { +#if PY_VERSION_HEX >= 0x03000000 + PyVarObject_HEAD_INIT(NULL, 0) +#else + PyObject_HEAD_INIT(NULL) + 0, /* ob_size */ +#endif + "swigvarlink", /* tp_name */ + sizeof(swig_varlinkobject), /* tp_basicsize */ + 0, /* tp_itemsize */ + (destructor) swig_varlink_dealloc, /* tp_dealloc */ +#if PY_VERSION_HEX < 0x030800b4 + (printfunc)0, /*tp_print*/ +#else + (Py_ssize_t)0, /*tp_vectorcall_offset*/ +#endif + (getattrfunc) swig_varlink_getattr, /* tp_getattr */ + (setattrfunc) swig_varlink_setattr, /* tp_setattr */ + 0, /* tp_compare */ + (reprfunc) swig_varlink_repr, /* tp_repr */ + 0, /* tp_as_number */ + 0, /* tp_as_sequence */ + 0, /* tp_as_mapping */ + 0, /* tp_hash */ + 0, /* tp_call */ + (reprfunc) swig_varlink_str, /* tp_str */ + 0, /* tp_getattro */ + 0, /* tp_setattro */ + 0, /* tp_as_buffer */ + 0, /* tp_flags */ + varlink__doc__, /* tp_doc */ + 0, /* tp_traverse */ + 0, /* tp_clear */ + 0, /* tp_richcompare */ + 0, /* tp_weaklistoffset */ + 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* tp_iter -> tp_weaklist */ + 0, /* tp_del */ + 0, /* tp_version_tag */ +#if PY_VERSION_HEX >= 0x03040000 + 0, /* tp_finalize */ +#endif +#if PY_VERSION_HEX >= 0x03080000 + 0, /* tp_vectorcall */ +#endif +#if (PY_VERSION_HEX >= 0x03080000) && (PY_VERSION_HEX < 0x03090000) + 0, /* tp_print */ +#endif +#if PY_VERSION_HEX >= 0x030C0000 + 0, /* tp_watched */ +#endif +#ifdef COUNT_ALLOCS + 0, /* tp_allocs */ + 0, /* tp_frees */ + 0, /* tp_maxalloc */ + 0, /* tp_prev */ + 0 /* tp_next */ +#endif + }; + varlink_type = tmp; + type_init = 1; + if (PyType_Ready(&varlink_type) < 0) + return NULL; + } + return &varlink_type; +#else + PyType_Slot slots[] = { + { Py_tp_dealloc, (void *)swig_varlink_dealloc }, + { Py_tp_repr, (void *)swig_varlink_repr }, + { Py_tp_getattr, (void *)swig_varlink_getattr }, + { Py_tp_setattr, (void *)swig_varlink_setattr }, + { Py_tp_str, (void *)swig_varlink_str }, + { Py_tp_doc, (void *)varlink__doc__ }, + { 0, NULL } + }; + PyType_Spec spec = { + "swigvarlink", + sizeof(swig_varlinkobject), + 0, + Py_TPFLAGS_DEFAULT, + slots + }; + return (PyTypeObject *)PyType_FromSpec(&spec); +#endif +} + +/* Create a variable linking object for use later */ +SWIGINTERN PyObject * +SWIG_Python_newvarlink(void) { + swig_varlinkobject *result = PyObject_New(swig_varlinkobject, swig_varlink_type()); + if (result) { + result->vars = 0; + } + return ((PyObject*) result); +} + +SWIGINTERN void +SWIG_Python_addvarlink(PyObject *p, const char *name, PyObject *(*get_attr)(void), int (*set_attr)(PyObject *p)) { + swig_varlinkobject *v = (swig_varlinkobject *) p; + swig_globalvar *gv = (swig_globalvar *) malloc(sizeof(swig_globalvar)); + if (gv) { + size_t size = strlen(name)+1; + gv->name = (char *)malloc(size); + if (gv->name) { + memcpy(gv->name, name, size); + gv->get_attr = get_attr; + gv->set_attr = set_attr; + gv->next = v->vars; + } + } + v->vars = gv; +} + + +static PyObject *Swig_Globals_global = NULL; + +SWIGINTERN PyObject * +SWIG_globals(void) { + if (Swig_Globals_global == NULL) { + Swig_Globals_global = SWIG_newvarlink(); + } + return Swig_Globals_global; +} + +#ifdef __cplusplus +} +#endif + /* ----------------------------------------------------------------------------- * Pointer declarations * ----------------------------------------------------------------------------- */ @@ -1319,18 +1651,25 @@ SwigPyClientData_New(PyObject* obj) /* the newraw method and newargs arguments used to create a new raw instance */ if (PyClass_Check(obj)) { data->newraw = 0; - data->newargs = obj; Py_INCREF(obj); + data->newargs = obj; } else { data->newraw = PyObject_GetAttrString(data->klass, "__new__"); if (data->newraw) { - Py_INCREF(data->newraw); - data->newargs = PyTuple_New(1); - PyTuple_SetItem(data->newargs, 0, obj); + data->newargs = PyTuple_New(1); + if (data->newargs) { + Py_INCREF(obj); + PyTuple_SET_ITEM(data->newargs, 0, obj); + } else { + Py_DECREF(data->newraw); + Py_DECREF(data->klass); + free(data); + return 0; + } } else { - data->newargs = obj; + Py_INCREF(obj); + data->newargs = obj; } - Py_INCREF(data->newargs); } /* the destroy method, aka as the C++ delete method */ data->destroy = PyObject_GetAttrString(data->klass, "__swig_destroy__"); @@ -1339,10 +1678,7 @@ SwigPyClientData_New(PyObject* obj) data->destroy = 0; } if (data->destroy) { - int flags; - Py_INCREF(data->destroy); - flags = PyCFunction_GET_FLAGS(data->destroy); - data->delargs = !(flags & (METH_O)); + data->delargs = !(PyCFunction_GET_FLAGS(data->destroy) & METH_O); } else { data->delargs = 0; } @@ -1353,10 +1689,13 @@ SwigPyClientData_New(PyObject* obj) } SWIGRUNTIME void -SwigPyClientData_Del(SwigPyClientData *data) { +SwigPyClientData_Del(SwigPyClientData *data) +{ + Py_XDECREF(data->klass); Py_XDECREF(data->newraw); Py_XDECREF(data->newargs); Py_XDECREF(data->destroy); + free(data); } /* =============== SwigPyObject =====================*/ @@ -1383,7 +1722,7 @@ SwigPyObject_get___dict__(PyObject *v, PyObject *SWIGUNUSEDPARM(args)) if (!sobj->dict) sobj->dict = PyDict_New(); - Py_INCREF(sobj->dict); + Py_XINCREF(sobj->dict); return sobj->dict; } @@ -1401,18 +1740,21 @@ SwigPyObject_format(const char* fmt, SwigPyObject *v) PyObject *res = NULL; PyObject *args = PyTuple_New(1); if (args) { - if (PyTuple_SetItem(args, 0, SwigPyObject_long(v)) == 0) { - PyObject *ofmt = SWIG_Python_str_FromChar(fmt); + PyObject *val = SwigPyObject_long(v); + if (val) { + PyObject *ofmt; + PyTuple_SET_ITEM(args, 0, val); + ofmt = SWIG_Python_str_FromChar(fmt); if (ofmt) { #if PY_VERSION_HEX >= 0x03000000 - res = PyUnicode_Format(ofmt,args); + res = PyUnicode_Format(ofmt,args); #else - res = PyString_Format(ofmt,args); + res = PyString_Format(ofmt,args); #endif - Py_DECREF(ofmt); + Py_DECREF(ofmt); } - Py_DECREF(args); } + Py_DECREF(args); } return res; } @@ -1434,18 +1776,23 @@ SwigPyObject_repr(SwigPyObject *v) { const char *name = SWIG_TypePrettyName(v->ty); PyObject *repr = SWIG_Python_str_FromFormat("", (name ? name : "unknown"), (void *)v); - if (v->next) { + if (repr && v->next) { PyObject *nrep = SwigPyObject_repr((SwigPyObject *)v->next); + if (nrep) { # if PY_VERSION_HEX >= 0x03000000 - PyObject *joined = PyUnicode_Concat(repr, nrep); - Py_DecRef(repr); - Py_DecRef(nrep); - repr = joined; + PyObject *joined = PyUnicode_Concat(repr, nrep); + Py_DecRef(repr); + Py_DecRef(nrep); + repr = joined; # else - PyString_ConcatAndDel(&repr,nrep); + PyString_ConcatAndDel(&repr,nrep); # endif + } else { + Py_DecRef(repr); + repr = NULL; + } } - return repr; + return repr; } /* We need a version taking two PyObject* parameters so it's a valid @@ -1468,12 +1815,14 @@ SwigPyObject_compare(SwigPyObject *v, SwigPyObject *w) SWIGRUNTIME PyObject* SwigPyObject_richcompare(SwigPyObject *v, SwigPyObject *w, int op) { - PyObject* res; - if( op != Py_EQ && op != Py_NE ) { - Py_INCREF(Py_NotImplemented); - return Py_NotImplemented; + PyObject* res = NULL; + if (!PyErr_Occurred()) { + if (op != Py_EQ && op != Py_NE) { + Py_INCREF(Py_NotImplemented); + return Py_NotImplemented; + } + res = PyBool_FromLong( (SwigPyObject_compare(v, w)==0) == (op == Py_EQ) ? 1 : 0); } - res = PyBool_FromLong( (SwigPyObject_compare(v, w)==0) == (op == Py_EQ) ? 1 : 0); return res; } @@ -1501,20 +1850,34 @@ SwigPyObject_type(void) { SWIGRUNTIMEINLINE int SwigPyObject_Check(PyObject *op) { -#ifdef SWIGPYTHON_BUILTIN PyTypeObject *target_tp = SwigPyObject_type(); - if (PyType_IsSubtype(op->ob_type, target_tp)) + PyTypeObject *op_type = Py_TYPE(op); +#ifdef SWIGPYTHON_BUILTIN + if (PyType_IsSubtype(op_type, target_tp)) return 1; - return (strcmp(op->ob_type->tp_name, "SwigPyObject") == 0); + return (strcmp(op_type->tp_name, "SwigPyObject") == 0); #else - return (Py_TYPE(op) == SwigPyObject_type()) - || (strcmp(Py_TYPE(op)->tp_name,"SwigPyObject") == 0); + if (op_type == target_tp) + return 1; +# ifdef Py_LIMITED_API + int cmp; + PyObject *tp_name = PyObject_GetAttrString((PyObject *)op_type, "__name__"); + if (!tp_name) + return 0; + cmp = PyUnicode_CompareWithASCIIString(tp_name, "SwigPyObject"); + Py_DECREF(tp_name); + return cmp == 0; +# else + return (strcmp(op_type->tp_name, "SwigPyObject") == 0); +# endif #endif } SWIGRUNTIME PyObject * SwigPyObject_New(void *ptr, swig_type_info *ty, int own); +static PyObject* Swig_Capsule_global = NULL; + SWIGRUNTIME void SwigPyObject_dealloc(PyObject *v) { @@ -1541,8 +1904,12 @@ SwigPyObject_dealloc(PyObject *v) if (data->delargs) { /* we need to create a temporary object to carry the destroy operation */ PyObject *tmp = SwigPyObject_New(sobj->ptr, ty, 0); - res = SWIG_Python_CallFunctor(destroy, tmp); - Py_DECREF(tmp); + if (tmp) { + res = SWIG_Python_CallFunctor(destroy, tmp); + } else { + res = 0; + } + Py_XDECREF(tmp); } else { PyCFunction meth = PyCFunction_GET_FUNCTION(destroy); PyObject *mself = PyCFunction_GET_SELF(destroy); @@ -1561,8 +1928,12 @@ SwigPyObject_dealloc(PyObject *v) printf("swig/python detected a memory leak of type '%s', no destructor found.\n", (name ? name : "unknown")); } #endif - } + Py_XDECREF(Swig_Capsule_global); + } Py_XDECREF(next); +#ifdef SWIGPYTHON_BUILTIN + Py_XDECREF(sobj->dict); +#endif PyObject_DEL(v); } @@ -1574,6 +1945,7 @@ SwigPyObject_append(PyObject* v, PyObject* next) PyErr_SetString(PyExc_TypeError, "Attempt to append a non SwigPyObject"); return NULL; } + ((SwigPyObject *)next)->next = sobj->next; sobj->next = next; Py_INCREF(next); return SWIG_Py_Void(); @@ -1618,9 +1990,9 @@ SwigPyObject_own(PyObject *v, PyObject *args) PyObject *obj = PyBool_FromLong(sobj->own); if (val) { if (PyObject_IsTrue(val)) { - SwigPyObject_acquire(v,args); + Py_DECREF(SwigPyObject_acquire(v,args)); } else { - SwigPyObject_disown(v,args); + Py_DECREF(SwigPyObject_disown(v,args)); } } return obj; @@ -1641,7 +2013,7 @@ swigobject_methods[] = { SWIGRUNTIME PyTypeObject* SwigPyObject_TypeOnce(void) { static char swigobject_doc[] = "Swig object carries a C/C++ instance pointer"; - +#ifndef Py_LIMITED_API static PyNumberMethods SwigPyObject_as_number = { (binaryfunc)0, /*nb_add*/ (binaryfunc)0, /*nb_subtract*/ @@ -1700,7 +2072,11 @@ SwigPyObject_TypeOnce(void) { sizeof(SwigPyObject), /* tp_basicsize */ 0, /* tp_itemsize */ (destructor)SwigPyObject_dealloc, /* tp_dealloc */ - 0, /* tp_print */ +#if PY_VERSION_HEX < 0x030800b4 + (printfunc)0, /*tp_print*/ +#else + (Py_ssize_t)0, /*tp_vectorcall_offset*/ +#endif (getattrfunc)0, /* tp_getattr */ (setattrfunc)0, /* tp_setattr */ #if PY_VERSION_HEX >= 0x03000000 @@ -1755,6 +2131,9 @@ SwigPyObject_TypeOnce(void) { #if (PY_VERSION_HEX >= 0x03080000) && (PY_VERSION_HEX < 0x03090000) 0, /* tp_print */ #endif +#if PY_VERSION_HEX >= 0x030C0000 + 0, /* tp_watched */ +#endif #ifdef COUNT_ALLOCS 0, /* tp_allocs */ 0, /* tp_frees */ @@ -1765,21 +2144,50 @@ SwigPyObject_TypeOnce(void) { }; swigpyobject_type = tmp; type_init = 1; - if (PyType_Ready(&swigpyobject_type) < 0) + if (PyType_Ready(&swigpyobject_type) != 0) return NULL; } return &swigpyobject_type; +#else + PyType_Slot slots[] = { + { Py_tp_dealloc, (void *)SwigPyObject_dealloc }, + { Py_tp_repr, (void *)SwigPyObject_repr }, + { Py_tp_getattro, (void *)PyObject_GenericGetAttr }, + { Py_tp_doc, (void *)swigobject_doc }, + { Py_tp_richcompare, (void *)SwigPyObject_richcompare }, + { Py_tp_methods, (void *)swigobject_methods }, + { Py_nb_int, (void *)SwigPyObject_long }, + { 0, NULL } + }; + PyType_Spec spec = { + "SwigPyObject", + sizeof(SwigPyObject), + 0, + Py_TPFLAGS_DEFAULT, + slots + }; + return (PyTypeObject *)PyType_FromSpec(&spec); +#endif } SWIGRUNTIME PyObject * SwigPyObject_New(void *ptr, swig_type_info *ty, int own) { - SwigPyObject *sobj = PyObject_NEW(SwigPyObject, SwigPyObject_type()); + SwigPyObject *sobj = PyObject_New(SwigPyObject, SwigPyObject_type()); if (sobj) { sobj->ptr = ptr; sobj->ty = ty; sobj->own = own; sobj->next = 0; +#ifdef SWIGPYTHON_BUILTIN + sobj->dict = 0; +#endif + if (own == SWIG_POINTER_OWN) { + /* Obtain a reference to the Python capsule wrapping the module information, so that the + * module information is correctly destroyed after all SWIG python objects have been freed + * by the GC (and corresponding destructors invoked) */ + Py_XINCREF(Swig_Capsule_global); + } } return (PyObject *)sobj; } @@ -1836,8 +2244,20 @@ SwigPyPacked_type(void) { SWIGRUNTIMEINLINE int SwigPyPacked_Check(PyObject *op) { - return ((op)->ob_type == SwigPyPacked_TypeOnce()) - || (strcmp((op)->ob_type->tp_name,"SwigPyPacked") == 0); + PyTypeObject* op_type = Py_TYPE(op); + if (op_type == SwigPyPacked_TypeOnce()) + return 1; +#ifdef Py_LIMITED_API + int cmp; + PyObject *tp_name = PyObject_GetAttrString((PyObject *)op_type, "__name__"); + if (!tp_name) + return 0; + cmp = PyUnicode_CompareWithASCIIString(tp_name, "SwigPyPacked"); + Py_DECREF(tp_name); + return cmp == 0; +#else + return (strcmp(op_type->tp_name, "SwigPyPacked") == 0); +#endif } SWIGRUNTIME void @@ -1853,6 +2273,7 @@ SwigPyPacked_dealloc(PyObject *v) SWIGRUNTIME PyTypeObject* SwigPyPacked_TypeOnce(void) { static char swigpacked_doc[] = "Swig object carries a C/C++ instance pointer"; +#ifndef Py_LIMITED_API static PyTypeObject swigpypacked_type; static int type_init = 0; if (!type_init) { @@ -1867,7 +2288,11 @@ SwigPyPacked_TypeOnce(void) { sizeof(SwigPyPacked), /* tp_basicsize */ 0, /* tp_itemsize */ (destructor)SwigPyPacked_dealloc, /* tp_dealloc */ - 0, /* tp_print */ +#if PY_VERSION_HEX < 0x030800b4 + (printfunc)0, /*tp_print*/ +#else + (Py_ssize_t)0, /*tp_vectorcall_offset*/ +#endif (getattrfunc)0, /* tp_getattr */ (setattrfunc)0, /* tp_setattr */ #if PY_VERSION_HEX>=0x03000000 @@ -1922,6 +2347,9 @@ SwigPyPacked_TypeOnce(void) { #if (PY_VERSION_HEX >= 0x03080000) && (PY_VERSION_HEX < 0x03090000) 0, /* tp_print */ #endif +#if PY_VERSION_HEX >= 0x030C0000 + 0, /* tp_watched */ +#endif #ifdef COUNT_ALLOCS 0, /* tp_allocs */ 0, /* tp_frees */ @@ -1932,16 +2360,34 @@ SwigPyPacked_TypeOnce(void) { }; swigpypacked_type = tmp; type_init = 1; - if (PyType_Ready(&swigpypacked_type) < 0) + if (PyType_Ready(&swigpypacked_type) != 0) return NULL; } return &swigpypacked_type; +#else + PyType_Slot slots[] = { + { Py_tp_dealloc, (void *)SwigPyPacked_dealloc }, + { Py_tp_repr, (void *)SwigPyPacked_repr }, + { Py_tp_str, (void *)SwigPyPacked_str }, + { Py_tp_getattro, (void *)PyObject_GenericGetAttr }, + { Py_tp_doc, (void *)swigpacked_doc }, + { 0, NULL } + }; + PyType_Spec spec = { + "SwigPyPacked", + sizeof(SwigPyPacked), + 0, + Py_TPFLAGS_DEFAULT, + slots + }; + return (PyTypeObject *)PyType_FromSpec(&spec); +#endif } SWIGRUNTIME PyObject * SwigPyPacked_New(void *ptr, size_t size, swig_type_info *ty) { - SwigPyPacked *sobj = PyObject_NEW(SwigPyPacked, SwigPyPacked_type()); + SwigPyPacked *sobj = PyObject_New(SwigPyPacked, SwigPyPacked_type()); if (sobj) { void *pack = malloc(size); if (pack) { @@ -2122,12 +2568,19 @@ SWIG_Python_ConvertPtrAndOwn(PyObject *obj, void **ptr, swig_type_info *ty, int } } if (sobj) { - if (own) - *own = *own | sobj->own; - if (flags & SWIG_POINTER_DISOWN) { - sobj->own = 0; + if (((flags & SWIG_POINTER_RELEASE) == SWIG_POINTER_RELEASE) && !sobj->own) { + res = SWIG_ERROR_RELEASE_NOT_OWNED; + } else { + if (own) + *own = *own | sobj->own; + if (flags & SWIG_POINTER_DISOWN) { + sobj->own = 0; + } + if (flags & SWIG_POINTER_CLEAR) { + sobj->ptr = 0; + } + res = SWIG_OK; } - res = SWIG_OK; } else { if (implicit_conv) { SwigPyClientData *data = ty ? (SwigPyClientData *) ty->clientdata : 0; @@ -2186,10 +2639,20 @@ SWIG_Python_ConvertFunctionPtr(PyObject *obj, void **ptr, swig_type_info *ty) { swig_cast_info *tc; /* here we get the method pointer for callbacks */ +#ifndef Py_LIMITED_API const char *doc = (((PyCFunctionObject *)obj) -> m_ml -> ml_doc); +#else + PyObject* pystr_doc = PyObject_GetAttrString(obj, "__doc__"); + PyObject *bytes = NULL; + const char *doc = pystr_doc ? SWIG_PyUnicode_AsUTF8AndSize(pystr_doc, NULL, &bytes) : 0; +#endif const char *desc = doc ? strstr(doc, "swig_ptr: ") : 0; if (desc) desc = ty ? SWIG_UnpackVoidPtr(desc + 10, &vptr, ty->name) : 0; +#ifdef Py_LIMITED_API + Py_XDECREF(bytes); + Py_XDECREF(pystr_doc); +#endif if (!desc) return SWIG_ERROR; tc = SWIG_TypeCheck(desc,ty); @@ -2240,12 +2703,17 @@ SWIG_Python_NewShadowInstance(SwigPyClientData *data, PyObject *swig_this) #if !defined(SWIG_PYTHON_SLOW_GETSET_THIS) PyObject **dictptr = _PyObject_GetDictPtr(inst); if (dictptr != NULL) { - PyObject *dict = *dictptr; - if (dict == NULL) { - dict = PyDict_New(); - *dictptr = dict; - PyDict_SetItem(dict, SWIG_This(), swig_this); - } + PyObject *dict = *dictptr; + if (dict == NULL) { + dict = PyDict_New(); + *dictptr = dict; + } + if (dict) { + PyDict_SetItem(dict, SWIG_This(), swig_this); + } else{ + Py_DECREF(inst); + inst = 0; + } } #else if (PyObject_SetAttr(inst, SWIG_This(), swig_this) == -1) { @@ -2260,14 +2728,19 @@ SWIG_Python_NewShadowInstance(SwigPyClientData *data, PyObject *swig_this) if (empty_args) { PyObject *empty_kwargs = PyDict_New(); if (empty_kwargs) { - inst = ((PyTypeObject *)data->newargs)->tp_new((PyTypeObject *)data->newargs, empty_args, empty_kwargs); +#ifndef Py_LIMITED_API + newfunc newfn = ((PyTypeObject *)data->newargs)->tp_new; +#else + newfunc newfn = (newfunc)PyType_GetSlot((PyTypeObject *)data->newargs, Py_tp_new); +#endif + inst = newfn((PyTypeObject *)data->newargs, empty_args, empty_kwargs); Py_DECREF(empty_kwargs); if (inst) { if (PyObject_SetAttr(inst, SWIG_This(), swig_this) == -1) { Py_DECREF(inst); inst = 0; } else { - Py_TYPE(inst)->tp_flags &= ~Py_TPFLAGS_VALID_VERSION_TAG; + PyType_Modified(Py_TYPE(inst)); } } } @@ -2296,7 +2769,11 @@ SWIG_Python_SetSwigThis(PyObject *inst, PyObject *swig_this) dict = PyDict_New(); *dictptr = dict; } - return PyDict_SetItem(dict, SWIG_This(), swig_this); + if (dict) { + return PyDict_SetItem(dict, SWIG_This(), swig_this); + } else{ + return -1; + } } #endif return PyObject_SetAttr(inst, SWIG_This(), swig_this); @@ -2311,7 +2788,7 @@ SWIG_Python_InitShadowInstance(PyObject *args) { } else { SwigPyObject *sthis = SWIG_Python_GetSwigThis(obj[0]); if (sthis) { - SwigPyObject_append((PyObject*) sthis, obj[1]); + Py_DECREF(SwigPyObject_append((PyObject*) sthis, obj[1])); } else { if (SWIG_Python_SetSwigThis(obj[0], obj[1]) != 0) return NULL; @@ -2338,7 +2815,12 @@ SWIG_Python_NewPointerObj(PyObject *self, void *ptr, swig_type_info *type, int f if (flags & SWIG_BUILTIN_TP_INIT) { newobj = (SwigPyObject*) self; if (newobj->ptr) { - PyObject *next_self = clientdata->pytype->tp_alloc(clientdata->pytype, 0); +#ifndef Py_LIMITED_API + allocfunc alloc = clientdata->pytype->tp_alloc; +#else + allocfunc alloc = (allocfunc)PyType_GetSlot(clientdata->pytype, Py_tp_alloc); +#endif + PyObject *next_self = alloc(clientdata->pytype, 0); while (newobj->next) newobj = (SwigPyObject *) newobj->next; newobj->next = next_self; @@ -2350,7 +2832,9 @@ SWIG_Python_NewPointerObj(PyObject *self, void *ptr, swig_type_info *type, int f } else { newobj = PyObject_New(SwigPyObject, clientdata->pytype); #ifdef SWIGPYTHON_BUILTIN - newobj->dict = 0; + if (newobj) { + newobj->dict = 0; + } #endif } if (newobj) { @@ -2389,39 +2873,61 @@ SWIG_Python_NewPackedObj(void *ptr, size_t sz, swig_type_info *type) { void *SWIG_ReturnGlobalTypeList(void *); #endif +static PyObject *Swig_TypeCache_global = NULL; + +/* The python cached type query */ +SWIGRUNTIME PyObject * +SWIG_Python_TypeCache(void) { + if (Swig_TypeCache_global == NULL) { + Swig_TypeCache_global = PyDict_New(); + } + return Swig_TypeCache_global; +} + SWIGRUNTIME swig_module_info * SWIG_Python_GetModule(void *SWIGUNUSEDPARM(clientdata)) { +#ifdef SWIG_LINK_RUNTIME static void *type_pointer = (void *)0; /* first check if module already created */ if (!type_pointer) { -#ifdef SWIG_LINK_RUNTIME type_pointer = SWIG_ReturnGlobalTypeList((void *)0); + } #else - type_pointer = PyCapsule_Import(SWIGPY_CAPSULE_NAME, 0); - if (PyErr_Occurred()) { - PyErr_Clear(); - type_pointer = (void *)0; - } -#endif + void *type_pointer = PyCapsule_Import(SWIGPY_CAPSULE_NAME, 0); + if (PyErr_Occurred()) { + PyErr_Clear(); + type_pointer = (void *)0; } +#endif return (swig_module_info *) type_pointer; } + +static int interpreter_counter = 0; /* how many (sub-)interpreters are using swig_module's types */ + SWIGRUNTIME void SWIG_Python_DestroyModule(PyObject *obj) { swig_module_info *swig_module = (swig_module_info *) PyCapsule_GetPointer(obj, SWIGPY_CAPSULE_NAME); swig_type_info **types = swig_module->types; size_t i; + if (--interpreter_counter != 0) /* another sub-interpreter may still be using the swig_module's types */ + return; for (i =0; i < swig_module->size; ++i) { swig_type_info *ty = types[i]; if (ty->owndata) { SwigPyClientData *data = (SwigPyClientData *) ty->clientdata; + ty->clientdata = 0; if (data) SwigPyClientData_Del(data); } } Py_DECREF(SWIG_This()); Swig_This_global = NULL; + Py_DECREF(SWIG_globals()); + Swig_Globals_global = NULL; + Py_DECREF(SWIG_Python_TypeCache()); + Swig_TypeCache_global = NULL; + Swig_Capsule_global = NULL; } SWIGRUNTIME void @@ -2435,19 +2941,17 @@ SWIG_Python_SetModule(swig_module_info *swig_module) { #endif PyObject *pointer = PyCapsule_New((void *) swig_module, SWIGPY_CAPSULE_NAME, SWIG_Python_DestroyModule); if (pointer && module) { - PyModule_AddObject(module, "type_pointer_capsule" SWIG_TYPE_TABLE_NAME, pointer); + if (PyModule_AddObject(module, SWIGPY_CAPSULE_ATTR_NAME, pointer) == 0) { + ++interpreter_counter; + Swig_Capsule_global = pointer; + } else { + Py_DECREF(pointer); + } } else { Py_XDECREF(pointer); } } -/* The python cached type query */ -SWIGRUNTIME PyObject * -SWIG_Python_TypeCache(void) { - static PyObject *SWIG_STATIC_POINTER(cache) = PyDict_New(); - return cache; -} - SWIGRUNTIME swig_type_info * SWIG_Python_TypeQuery(const char *type) { @@ -2462,8 +2966,10 @@ SWIG_Python_TypeQuery(const char *type) descriptor = SWIG_TypeQueryModule(swig_module, swig_module, type); if (descriptor) { obj = PyCapsule_New((void*) descriptor, NULL, NULL); - PyDict_SetItem(cache, key, obj); - Py_DECREF(obj); + if (obj) { + PyDict_SetItem(cache, key, obj); + Py_DECREF(obj); + } } } Py_DECREF(key); @@ -2487,7 +2993,8 @@ SWIG_Python_AddErrMesg(const char* mesg, int infront) PyErr_Fetch(&type, &value, &traceback); if (value) { PyObject *old_str = PyObject_Str(value); - const char *tmp = SWIG_Python_str_AsChar(old_str); + PyObject *bytes = NULL; + const char *tmp = SWIG_PyUnicode_AsUTF8AndSize(old_str, NULL, &bytes); const char *errmesg = tmp ? tmp : "Invalid error message"; Py_XINCREF(type); PyErr_Clear(); @@ -2496,7 +3003,7 @@ SWIG_Python_AddErrMesg(const char* mesg, int infront) } else { PyErr_Format(type, "%s %s", errmesg, mesg); } - SWIG_Python_str_DelForPy3(tmp); + Py_XDECREF(bytes); Py_DECREF(old_str); } return 1; @@ -2541,21 +3048,25 @@ SWIG_Python_TypeError(const char *type, PyObject *obj) } else #endif { +#ifndef Py_LIMITED_API + /* tp_name is not accessible */ const char *otype = (obj ? obj->ob_type->tp_name : 0); if (otype) { PyObject *str = PyObject_Str(obj); - const char *cstr = str ? SWIG_Python_str_AsChar(str) : 0; + PyObject *bytes = NULL; + const char *cstr = str ? SWIG_PyUnicode_AsUTF8AndSize(str, NULL, &bytes) : 0; if (cstr) { PyErr_Format(PyExc_TypeError, "a '%s' is expected, '%s(%s)' is received", type, otype, cstr); - SWIG_Python_str_DelForPy3(cstr); } else { PyErr_Format(PyExc_TypeError, "a '%s' is expected, '%s' is received", type, otype); } + Py_XDECREF(bytes); Py_XDECREF(str); return; } +#endif } PyErr_Format(PyExc_TypeError, "a '%s' is expected", type); } else { @@ -2570,12 +3081,6 @@ SWIG_Python_MustGetPtr(PyObject *obj, swig_type_info *ty, int SWIGUNUSEDPARM(arg void *result; if (SWIG_Python_ConvertPtr(obj, &result, ty, flags) == -1) { PyErr_Clear(); -#if SWIG_POINTER_EXCEPTION - if (flags) { - SWIG_Python_TypeError(SWIG_TypePrettyName(ty), obj); - SWIG_Python_ArgFail(argnum); - } -#endif } return result; } @@ -2606,7 +3111,7 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) { } if (!tp->tp_dict) { - if (PyType_Ready(tp) < 0) + if (PyType_Ready(tp) != 0) goto done; } @@ -2621,7 +3126,7 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) { } else { encoded_name = PyUnicode_AsUTF8String(name); if (!encoded_name) - return -1; + goto done; } PyErr_Format(PyExc_AttributeError, "'%.100s' object has no attribute '%.200s'", tp->tp_name, PyString_AsString(encoded_name)); Py_DECREF(encoded_name); @@ -2644,23 +3149,8 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) { #define SWIG_exception_fail(code, msg) do { SWIG_Error(code, msg); SWIG_fail; } while(0) -#define SWIG_contract_assert(expr, msg) if (!(expr)) { SWIG_Error(SWIG_RuntimeError, msg); SWIG_fail; } else - - - -#ifdef __cplusplus -extern "C" { -#endif - -/* Method creation and docstring support functions */ +#define SWIG_contract_assert(expr, msg) do { if (!(expr)) { SWIG_Error(SWIG_RuntimeError, msg); SWIG_fail; } } while (0) -SWIGINTERN PyMethodDef *SWIG_PythonGetProxyDoc(const char *name); -SWIGINTERN PyObject *SWIG_PyInstanceMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func); -SWIGINTERN PyObject *SWIG_PyStaticMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func); - -#ifdef __cplusplus -} -#endif /* -------- TYPES TABLE (BEGIN) -------- */ @@ -2691,10 +3181,6 @@ static swig_module_info swig_module = {swig_types, 2, 0, 0, 0, 0}; #endif #define SWIG_name "_wcscon" -#define SWIGVERSION 0x040002 -#define SWIG_VERSION SWIGVERSION - - #define SWIG_as_voidptr(a) (void *)((const void *)(a)) #define SWIG_as_voidptrptr(a) ((void)SWIG_as_voidptr(*a),(void**)(a)) @@ -2765,9 +3251,11 @@ SWIGINTERNINLINE int SWIG_CanCastAsInteger(double *d, double min, double max) { double x = *d; if ((min <= x && x <= max)) { - double fx = floor(x); - double cx = ceil(x); - double rd = ((x - fx) < 0.5) ? fx : cx; /* simple rint */ + double fx, cx, rd; + errno = 0; + fx = floor(x); + cx = ceil(x); + rd = ((x - fx) < 0.5) ? fx : cx; /* simple rint */ if ((errno == EDOM) || (errno == ERANGE)) { errno = 0; } else { @@ -2823,7 +3311,12 @@ SWIG_AsVal_long (PyObject *obj, long* val) if (!dispatch) { double d; int res = SWIG_AddCast(SWIG_AsVal_double (obj,&d)); - if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, LONG_MIN, LONG_MAX)) { + // Largest double not larger than LONG_MAX (not portably calculated easily) + // Note that double(LONG_MAX) is stored in a double rounded up by one (for 64-bit long) + // 0x7ffffffffffffc00LL == (int64_t)std::nextafter(double(__uint128_t(LONG_MAX)+1), double(0)) + const double long_max = sizeof(long) == 8 ? 0x7ffffffffffffc00LL : LONG_MAX; + // No equivalent needed for 64-bit double(LONG_MIN) is exactly LONG_MIN + if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, LONG_MIN, long_max)) { if (val) *val = (long)(d); return res; } @@ -2866,8 +3359,10 @@ SWIG_pchar_descriptor(void) } +/* Return string from Python obj. NOTE: obj must remain in scope in order + to use the returned cptr (but only when alloc is set to SWIG_OLDOBJ) */ SWIGINTERN int -SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc) +SWIG_AsCharPtrAndSize(PyObject *obj, char **cptr, size_t *psize, int *alloc) { #if PY_VERSION_HEX>=0x03000000 #if defined(SWIG_PYTHON_STRICT_BYTE_CHAR) @@ -2880,55 +3375,31 @@ SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc) #endif { char *cstr; Py_ssize_t len; + PyObject *bytes = NULL; int ret = SWIG_OK; -#if PY_VERSION_HEX>=0x03000000 -#if !defined(SWIG_PYTHON_STRICT_BYTE_CHAR) - if (!alloc && cptr) { - /* We can't allow converting without allocation, since the internal - representation of string in Python 3 is UCS-2/UCS-4 but we require - a UTF-8 representation. - TODO(bhy) More detailed explanation */ - return SWIG_RuntimeError; - } - obj = PyUnicode_AsUTF8String(obj); - if (!obj) - return SWIG_TypeError; if (alloc) - *alloc = SWIG_NEWOBJ; -#endif + *alloc = SWIG_OLDOBJ; +#if PY_VERSION_HEX>=0x03000000 && defined(SWIG_PYTHON_STRICT_BYTE_CHAR) if (PyBytes_AsStringAndSize(obj, &cstr, &len) == -1) return SWIG_TypeError; #else - if (PyString_AsStringAndSize(obj, &cstr, &len) == -1) + cstr = (char *)SWIG_PyUnicode_AsUTF8AndSize(obj, &len, &bytes); + if (!cstr) return SWIG_TypeError; -#endif - if (cptr) { + /* The returned string is only duplicated if the char * returned is not owned and memory managed by obj */ + if (bytes && cptr) { if (alloc) { - if (*alloc == SWIG_NEWOBJ) { - *cptr = (char *)memcpy(malloc((len + 1)*sizeof(char)), cstr, sizeof(char)*(len + 1)); - *alloc = SWIG_NEWOBJ; - } else { - *cptr = cstr; - *alloc = SWIG_OLDOBJ; - } + cstr = (char *)memcpy(malloc((len + 1)*sizeof(char)), cstr, sizeof(char)*(len + 1)); + *alloc = SWIG_NEWOBJ; } else { -#if PY_VERSION_HEX>=0x03000000 -#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR) - *cptr = PyBytes_AsString(obj); -#else - assert(0); /* Should never reach here with Unicode strings in Python 3 */ -#endif -#else - *cptr = SWIG_Python_str_AsChar(obj); - if (!*cptr) - ret = SWIG_TypeError; -#endif + /* alloc must be set in order to clean up allocated memory */ + return SWIG_RuntimeError; } } - if (psize) *psize = len + 1; -#if PY_VERSION_HEX>=0x03000000 && !defined(SWIG_PYTHON_STRICT_BYTE_CHAR) - Py_XDECREF(obj); #endif + if (cptr) *cptr = cstr; + if (psize) *psize = len + 1; + Py_XDECREF(bytes); return ret; } else { #if defined(SWIG_PYTHON_2_UNICODE) @@ -2987,7 +3458,7 @@ SWIGINTERNINLINE PyObject* #ifdef __cplusplus extern "C" { #endif -SWIGINTERN PyObject *_wrap_wcscon(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_wcscon(PyObject *self, PyObject *args) { PyObject *resultobj = 0; int arg1 ; int arg2 ; @@ -3012,6 +3483,7 @@ SWIGINTERN PyObject *_wrap_wcscon(PyObject *SWIGUNUSEDPARM(self), PyObject *args int ecode7 = 0 ; PyObject *swig_obj[7] ; + (void)self; if (!SWIG_Python_UnpackTuple(args, "wcscon", 7, 7, swig_obj)) SWIG_fail; ecode1 = SWIG_AsVal_int(swig_obj[0], &val1); if (!SWIG_IsOK(ecode1)) { @@ -3078,7 +3550,7 @@ SWIGINTERN PyObject *_wrap_wcscon(PyObject *SWIGUNUSEDPARM(self), PyObject *args } -SWIGINTERN PyObject *_wrap_wcscsys(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { +SWIGINTERN PyObject *_wrap_wcscsys(PyObject *self, PyObject *args) { PyObject *resultobj = 0; char *arg1 = (char *) 0 ; int res1 ; @@ -3087,6 +3559,7 @@ SWIGINTERN PyObject *_wrap_wcscsys(PyObject *SWIGUNUSEDPARM(self), PyObject *arg PyObject *swig_obj[1] ; int result; + (void)self; if (!args) SWIG_fail; swig_obj[0] = args; res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1); @@ -3105,16 +3578,11 @@ SWIGINTERN PyObject *_wrap_wcscsys(PyObject *SWIGUNUSEDPARM(self), PyObject *arg static PyMethodDef SwigMethods[] = { - { "SWIG_PyInstanceMethod_New", SWIG_PyInstanceMethod_New, METH_O, NULL}, { "wcscon", _wrap_wcscon, METH_VARARGS, "wcscon(sys1, sys2, eq1, eq2, arg5, arg6, epoch)"}, { "wcscsys", _wrap_wcscsys, METH_O, "wcscsys(wcstring) -> int"}, { NULL, NULL, 0, NULL } }; -static PyMethodDef SwigMethods_proxydocs[] = { - { NULL, NULL, 0, NULL } -}; - /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */ @@ -3195,9 +3663,12 @@ extern "C" { #define SWIGRUNTIME_DEBUG #endif +#ifndef SWIG_INIT_CLIENT_DATA_TYPE +#define SWIG_INIT_CLIENT_DATA_TYPE void * +#endif SWIGRUNTIME void -SWIG_InitializeModule(void *clientdata) { +SWIG_InitializeModule(SWIG_INIT_CLIENT_DATA_TYPE clientdata) { size_t i; swig_module_info *module_head, *iter; int init; @@ -3380,220 +3851,6 @@ SWIG_PropagateClientData(void) { extern "C" { #endif - /* Python-specific SWIG API */ -#define SWIG_newvarlink() SWIG_Python_newvarlink() -#define SWIG_addvarlink(p, name, get_attr, set_attr) SWIG_Python_addvarlink(p, name, get_attr, set_attr) -#define SWIG_InstallConstants(d, constants) SWIG_Python_InstallConstants(d, constants) - - /* ----------------------------------------------------------------------------- - * global variable support code. - * ----------------------------------------------------------------------------- */ - - typedef struct swig_globalvar { - char *name; /* Name of global variable */ - PyObject *(*get_attr)(void); /* Return the current value */ - int (*set_attr)(PyObject *); /* Set the value */ - struct swig_globalvar *next; - } swig_globalvar; - - typedef struct swig_varlinkobject { - PyObject_HEAD - swig_globalvar *vars; - } swig_varlinkobject; - - SWIGINTERN PyObject * - swig_varlink_repr(swig_varlinkobject *SWIGUNUSEDPARM(v)) { -#if PY_VERSION_HEX >= 0x03000000 - return PyUnicode_InternFromString(""); -#else - return PyString_FromString(""); -#endif - } - - SWIGINTERN PyObject * - swig_varlink_str(swig_varlinkobject *v) { -#if PY_VERSION_HEX >= 0x03000000 - PyObject *str = PyUnicode_InternFromString("("); - PyObject *tail; - PyObject *joined; - swig_globalvar *var; - for (var = v->vars; var; var=var->next) { - tail = PyUnicode_FromString(var->name); - joined = PyUnicode_Concat(str, tail); - Py_DecRef(str); - Py_DecRef(tail); - str = joined; - if (var->next) { - tail = PyUnicode_InternFromString(", "); - joined = PyUnicode_Concat(str, tail); - Py_DecRef(str); - Py_DecRef(tail); - str = joined; - } - } - tail = PyUnicode_InternFromString(")"); - joined = PyUnicode_Concat(str, tail); - Py_DecRef(str); - Py_DecRef(tail); - str = joined; -#else - PyObject *str = PyString_FromString("("); - swig_globalvar *var; - for (var = v->vars; var; var=var->next) { - PyString_ConcatAndDel(&str,PyString_FromString(var->name)); - if (var->next) PyString_ConcatAndDel(&str,PyString_FromString(", ")); - } - PyString_ConcatAndDel(&str,PyString_FromString(")")); -#endif - return str; - } - - SWIGINTERN void - swig_varlink_dealloc(swig_varlinkobject *v) { - swig_globalvar *var = v->vars; - while (var) { - swig_globalvar *n = var->next; - free(var->name); - free(var); - var = n; - } - } - - SWIGINTERN PyObject * - swig_varlink_getattr(swig_varlinkobject *v, char *n) { - PyObject *res = NULL; - swig_globalvar *var = v->vars; - while (var) { - if (strcmp(var->name,n) == 0) { - res = (*var->get_attr)(); - break; - } - var = var->next; - } - if (res == NULL && !PyErr_Occurred()) { - PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n); - } - return res; - } - - SWIGINTERN int - swig_varlink_setattr(swig_varlinkobject *v, char *n, PyObject *p) { - int res = 1; - swig_globalvar *var = v->vars; - while (var) { - if (strcmp(var->name,n) == 0) { - res = (*var->set_attr)(p); - break; - } - var = var->next; - } - if (res == 1 && !PyErr_Occurred()) { - PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n); - } - return res; - } - - SWIGINTERN PyTypeObject* - swig_varlink_type(void) { - static char varlink__doc__[] = "Swig var link object"; - static PyTypeObject varlink_type; - static int type_init = 0; - if (!type_init) { - const PyTypeObject tmp = { -#if PY_VERSION_HEX >= 0x03000000 - PyVarObject_HEAD_INIT(NULL, 0) -#else - PyObject_HEAD_INIT(NULL) - 0, /* ob_size */ -#endif - "swigvarlink", /* tp_name */ - sizeof(swig_varlinkobject), /* tp_basicsize */ - 0, /* tp_itemsize */ - (destructor) swig_varlink_dealloc, /* tp_dealloc */ - 0, /* tp_print */ - (getattrfunc) swig_varlink_getattr, /* tp_getattr */ - (setattrfunc) swig_varlink_setattr, /* tp_setattr */ - 0, /* tp_compare */ - (reprfunc) swig_varlink_repr, /* tp_repr */ - 0, /* tp_as_number */ - 0, /* tp_as_sequence */ - 0, /* tp_as_mapping */ - 0, /* tp_hash */ - 0, /* tp_call */ - (reprfunc) swig_varlink_str, /* tp_str */ - 0, /* tp_getattro */ - 0, /* tp_setattro */ - 0, /* tp_as_buffer */ - 0, /* tp_flags */ - varlink__doc__, /* tp_doc */ - 0, /* tp_traverse */ - 0, /* tp_clear */ - 0, /* tp_richcompare */ - 0, /* tp_weaklistoffset */ - 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* tp_iter -> tp_weaklist */ - 0, /* tp_del */ - 0, /* tp_version_tag */ -#if PY_VERSION_HEX >= 0x03040000 - 0, /* tp_finalize */ -#endif -#if PY_VERSION_HEX >= 0x03080000 - 0, /* tp_vectorcall */ -#endif -#if (PY_VERSION_HEX >= 0x03080000) && (PY_VERSION_HEX < 0x03090000) - 0, /* tp_print */ -#endif -#ifdef COUNT_ALLOCS - 0, /* tp_allocs */ - 0, /* tp_frees */ - 0, /* tp_maxalloc */ - 0, /* tp_prev */ - 0 /* tp_next */ -#endif - }; - varlink_type = tmp; - type_init = 1; - if (PyType_Ready(&varlink_type) < 0) - return NULL; - } - return &varlink_type; - } - - /* Create a variable linking object for use later */ - SWIGINTERN PyObject * - SWIG_Python_newvarlink(void) { - swig_varlinkobject *result = PyObject_NEW(swig_varlinkobject, swig_varlink_type()); - if (result) { - result->vars = 0; - } - return ((PyObject*) result); - } - - SWIGINTERN void - SWIG_Python_addvarlink(PyObject *p, const char *name, PyObject *(*get_attr)(void), int (*set_attr)(PyObject *p)) { - swig_varlinkobject *v = (swig_varlinkobject *) p; - swig_globalvar *gv = (swig_globalvar *) malloc(sizeof(swig_globalvar)); - if (gv) { - size_t size = strlen(name)+1; - gv->name = (char *)malloc(size); - if (gv->name) { - memcpy(gv->name, name, size); - gv->get_attr = get_attr; - gv->set_attr = set_attr; - gv->next = v->vars; - } - } - v->vars = gv; - } - - SWIGINTERN PyObject * - SWIG_globals(void) { - static PyObject *globals = 0; - if (!globals) { - globals = SWIG_newvarlink(); - } - return globals; - } - /* ----------------------------------------------------------------------------- * constants/methods manipulation * ----------------------------------------------------------------------------- */ @@ -3622,15 +3879,12 @@ extern "C" { } } - /* -----------------------------------------------------------------------------*/ - /* Fix SwigMethods to carry the callback ptrs when needed */ - /* -----------------------------------------------------------------------------*/ + /* ----------------------------------------------------------------------------- + * Patch %callback methods' docstrings to hold the callback ptrs + * -----------------------------------------------------------------------------*/ SWIGINTERN void - SWIG_Python_FixMethods(PyMethodDef *methods, - swig_const_info *const_table, - swig_type_info **types, - swig_type_info **types_initial) { + SWIG_Python_FixMethods(PyMethodDef *methods, const swig_const_info *const_table, swig_type_info **types, swig_type_info **types_initial) { size_t i; for (i = 0; methods[i].ml_name; ++i) { const char *c = methods[i].ml_doc; @@ -3638,7 +3892,7 @@ extern "C" { c = strstr(c, "swig_ptr: "); if (c) { int j; - swig_const_info *ci = 0; + const swig_const_info *ci = 0; const char *name = c + 10; for (j = 0; const_table[j].type; ++j) { if (strncmp(const_table[j].name, name, @@ -3670,68 +3924,13 @@ extern "C" { } } - /* ----------------------------------------------------------------------------- - * Method creation and docstring support functions - * ----------------------------------------------------------------------------- */ - - /* ----------------------------------------------------------------------------- - * Function to find the method definition with the correct docstring for the - * proxy module as opposed to the low-level API - * ----------------------------------------------------------------------------- */ - - SWIGINTERN PyMethodDef *SWIG_PythonGetProxyDoc(const char *name) { - /* Find the function in the modified method table */ - size_t offset = 0; - int found = 0; - while (SwigMethods_proxydocs[offset].ml_meth != NULL) { - if (strcmp(SwigMethods_proxydocs[offset].ml_name, name) == 0) { - found = 1; - break; - } - offset++; - } - /* Use the copy with the modified docstring if available */ - return found ? &SwigMethods_proxydocs[offset] : NULL; - } - - /* ----------------------------------------------------------------------------- - * Wrapper of PyInstanceMethod_New() used in Python 3 - * It is exported to the generated module, used for -fastproxy - * ----------------------------------------------------------------------------- */ - - SWIGINTERN PyObject *SWIG_PyInstanceMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func) { - if (PyCFunction_Check(func)) { - PyCFunctionObject *funcobj = (PyCFunctionObject *)func; - PyMethodDef *ml = SWIG_PythonGetProxyDoc(funcobj->m_ml->ml_name); - if (ml) - func = PyCFunction_NewEx(ml, funcobj->m_self, funcobj->m_module); - } -#if PY_VERSION_HEX >= 0x03000000 - return PyInstanceMethod_New(func); -#else - return PyMethod_New(func, NULL, NULL); -#endif - } - - /* ----------------------------------------------------------------------------- - * Wrapper of PyStaticMethod_New() - * It is exported to the generated module, used for -fastproxy - * ----------------------------------------------------------------------------- */ - - SWIGINTERN PyObject *SWIG_PyStaticMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func) { - if (PyCFunction_Check(func)) { - PyCFunctionObject *funcobj = (PyCFunctionObject *)func; - PyMethodDef *ml = SWIG_PythonGetProxyDoc(funcobj->m_ml->ml_name); - if (ml) - func = PyCFunction_NewEx(ml, funcobj->m_self, funcobj->m_module); - } - return PyStaticMethod_New(func); - } - #ifdef __cplusplus } #endif + + + /* -----------------------------------------------------------------------------* * Partial Init method * -----------------------------------------------------------------------------*/ diff --git a/PyWCSTools/wcssubs-3.9.5/wcsinit.c b/PyWCSTools/wcssubs-3.9.7/wcsinit.c similarity index 99% rename from PyWCSTools/wcssubs-3.9.5/wcsinit.c rename to PyWCSTools/wcssubs-3.9.7/wcsinit.c index c184ca0..13ca405 100644 --- a/PyWCSTools/wcssubs-3.9.5/wcsinit.c +++ b/PyWCSTools/wcssubs-3.9.7/wcsinit.c @@ -1,8 +1,8 @@ /*** File libwcs/wcsinit.c - *** July 24, 2016 + *** May 21, 2018 *** By Jessica Mink, jmink@cfa.harvard.edu *** Harvard-Smithsonian Center for Astrophysics - *** Copyright (C) 1998-2016 + *** Copyright (C) 1998-2018 *** Smithsonian Astrophysical Observatory, Cambridge, MA, USA This library is free software; you can redistribute it and/or @@ -416,9 +416,9 @@ char *wchar; /* Suffix character for one of multiple WCS */ /* Read third and fourth coordinate types, if present */ strcpy (wcs->ctype[2], ""); - hgetsc (hstring, "CTYPE3", &mchar, 9, wcs->ctype[2]); + hgetsc (hstring, "CTYPE3", &mchar, 16, wcs->ctype[2]); strcpy (wcs->ctype[3], ""); - hgetsc (hstring, "CTYPE4", &mchar, 9, wcs->ctype[3]); + hgetsc (hstring, "CTYPE4", &mchar, 16, wcs->ctype[3]); /* Set projection type in WCS data structure */ if (wcstype (wcs, ctype1, ctype2)) { @@ -1613,5 +1613,8 @@ char *mchar; /* Suffix character for one of multiple WCS */ * Feb 07 2013 Avoid SWARP distortion if SIRTF distortion is present * Jul 25 2013 Initialize n=0 when checking for SCAMP distortion terms (fix from Martin Kuemmel) * + * Jun 8 2016 Read up tpo 16 characters for ctype[0] and ctype[1] for SIP distortion * Jun 24 2016 wcs->ptype contains only 3-letter projection code + * + * May 21 2018 Read up to 16 characters for ctype[2] and ctype[3], too. */ diff --git a/PyWCSTools/wcssubs-3.9.5/wcslib.c b/PyWCSTools/wcssubs-3.9.7/wcslib.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/wcslib.c rename to PyWCSTools/wcssubs-3.9.7/wcslib.c diff --git a/PyWCSTools/wcssubs-3.9.5/wcslib.h b/PyWCSTools/wcssubs-3.9.7/wcslib.h similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/wcslib.h rename to PyWCSTools/wcssubs-3.9.7/wcslib.h diff --git a/PyWCSTools/wcssubs-3.9.5/wcstrig.c b/PyWCSTools/wcssubs-3.9.7/wcstrig.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/wcstrig.c rename to PyWCSTools/wcssubs-3.9.7/wcstrig.c diff --git a/PyWCSTools/wcssubs-3.9.5/worldpos.c b/PyWCSTools/wcssubs-3.9.7/worldpos.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/worldpos.c rename to PyWCSTools/wcssubs-3.9.7/worldpos.c diff --git a/PyWCSTools/wcssubs-3.9.5/zpxpos.c b/PyWCSTools/wcssubs-3.9.7/zpxpos.c similarity index 100% rename from PyWCSTools/wcssubs-3.9.5/zpxpos.c rename to PyWCSTools/wcssubs-3.9.7/zpxpos.c diff --git a/astLib/__init__.py b/astLib/__init__.py index 9c44747..d1e023d 100644 --- a/astLib/__init__.py +++ b/astLib/__init__.py @@ -3,9 +3,9 @@ (c) 2007-2012 Matt Hilton -(c) 2013-2023 Matt Hilton & Steven Boada +(c) 2013-2024 Matt Hilton & Steven Boada -U{http://astlib.sourceforge.net} +U{https://astlib.readthedocs.io} See the README file for information on usage and installation. See the LICENSE file for information on distribution. @@ -13,4 +13,4 @@ """ __all__=['astCalc', 'astCoords', 'astImages', 'astPlots', 'astStats', 'astWCS', 'astSED'] -__version__ = '0.11.10' +__version__ = '0.11.11' diff --git a/setup.py b/setup.py index 4052a30..6f7c95a 100644 --- a/setup.py +++ b/setup.py @@ -8,25 +8,25 @@ from pkg_resources import require topDir = os.getcwd() -sourceDir = "PyWCSTools"+os.path.sep+"wcssubs-3.9.5"+os.path.sep +sourceDir = "PyWCSTools"+os.path.sep+"wcssubs-3.9.7"+os.path.sep #oFiles=glob.glob(sourceDir+"*.o") #print oFiles -oFiles = ['PyWCSTools/wcssubs-3.9.5/cel.o', 'PyWCSTools/wcssubs-3.9.5/wcs.o', - 'PyWCSTools/wcssubs-3.9.5/proj.o', 'PyWCSTools/wcssubs-3.9.5/distort.o', - 'PyWCSTools/wcssubs-3.9.5/wcsinit.o', 'PyWCSTools/wcssubs-3.9.5/wcslib.o', - 'PyWCSTools/wcssubs-3.9.5/poly.o', 'PyWCSTools/wcssubs-3.9.5/platepos.o', - 'PyWCSTools/wcssubs-3.9.5/zpxpos.o', 'PyWCSTools/wcssubs-3.9.5/iget.o', - 'PyWCSTools/wcssubs-3.9.5/imio.o', 'PyWCSTools/wcssubs-3.9.5/dsspos.o', - 'PyWCSTools/wcssubs-3.9.5/tnxpos.o', 'PyWCSTools/wcssubs-3.9.5/wcscon.o', - 'PyWCSTools/wcssubs-3.9.5/fitsfile.o', - 'PyWCSTools/wcssubs-3.9.5/dateutil.o', - 'PyWCSTools/wcssubs-3.9.5/imhfile.o', 'PyWCSTools/wcssubs-3.9.5/lin.o', - 'PyWCSTools/wcssubs-3.9.5/fileutil.o', - 'PyWCSTools/wcssubs-3.9.5/wcstrig.o', - 'PyWCSTools/wcssubs-3.9.5/sph.o', - 'PyWCSTools/wcssubs-3.9.5/worldpos.o', 'PyWCSTools/wcssubs-3.9.5/hget.o', - 'PyWCSTools/wcssubs-3.9.5/hput.o'] +oFiles = ['PyWCSTools/wcssubs-3.9.7/cel.o', 'PyWCSTools/wcssubs-3.9.7/wcs.o', + 'PyWCSTools/wcssubs-3.9.7/proj.o', 'PyWCSTools/wcssubs-3.9.7/distort.o', + 'PyWCSTools/wcssubs-3.9.7/wcsinit.o', 'PyWCSTools/wcssubs-3.9.7/wcslib.o', + 'PyWCSTools/wcssubs-3.9.7/poly.o', 'PyWCSTools/wcssubs-3.9.7/platepos.o', + 'PyWCSTools/wcssubs-3.9.7/zpxpos.o', 'PyWCSTools/wcssubs-3.9.7/iget.o', + 'PyWCSTools/wcssubs-3.9.7/imio.o', 'PyWCSTools/wcssubs-3.9.7/dsspos.o', + 'PyWCSTools/wcssubs-3.9.7/tnxpos.o', 'PyWCSTools/wcssubs-3.9.7/wcscon.o', + 'PyWCSTools/wcssubs-3.9.7/fitsfile.o', + 'PyWCSTools/wcssubs-3.9.7/dateutil.o', + 'PyWCSTools/wcssubs-3.9.7/imhfile.o', 'PyWCSTools/wcssubs-3.9.7/lin.o', + 'PyWCSTools/wcssubs-3.9.7/fileutil.o', + 'PyWCSTools/wcssubs-3.9.7/wcstrig.o', + 'PyWCSTools/wcssubs-3.9.7/sph.o', + 'PyWCSTools/wcssubs-3.9.7/worldpos.o', 'PyWCSTools/wcssubs-3.9.7/hget.o', + 'PyWCSTools/wcssubs-3.9.7/hput.o'] exampleScripts = glob.glob("scripts"+os.path.sep+"*.py") @@ -38,7 +38,7 @@ def build_extensions(self): cc=setuptools._distutils.ccompiler.new_compiler(setuptools._distutils.ccompiler.get_default_compiler()) cc.compiler_so=sysconfig.get_config_var('CC').split()+sysconfig.get_config_var('CFLAGS').split()+sysconfig.get_config_var('CFLAGSFORSHARED').split() - # Suppress warnings from compiling WCSTools wcssubs-3.9.5 + # Suppress warnings from compiling WCSTools wcssubs-3.9.7 if "-Wstrict-prototypes" in cc.compiler_so: cc.compiler_so.pop(cc.compiler_so.index("-Wstrict-prototypes")) if "-Wall" in cc.compiler_so: