This program is a wrapper procedure to the extast routine in the
IDL astronomy user's library. extast3 is designed to handle
data cubes, which extast cannot handle. This procedure is used by
sky2pix to convert between sky and pixel coordinates in data cubes.
extast3, hdr, result, [/delete]
hdr: A string array, containing a fits header. The header must
describe a 2 or 3 dimensional fits file. If the fits file is 3D,
all information related to 2d position on the sky must be contained
within the first 2 dimensions of the fits file (in otherwords, the
fits axes cannot be rotated such that spatial information lies
along the third axis. This would be pretty non-standard, however).
result: A structure containing the following fields:
extast: A pointer to the result of calling extast on hdr. If hdr
describes a data cube, extast is 'tricked' into thinking hdr
actually describes a 2d images. Extast contains all of the 2D sky
delete: Since result contains a pointer, these should be properly
de-allocated at the end of use. Set the delete keyword to free the
extast pointer and delete the result variable
June 2009: Written by Chris Beaumont
March 2010: Added input checking. cnb.