eon of file

Steve Allen sla at ucolick.borg
Thu Jun 4 10:58:34 EDT 1998


In article <Pine.BSI.3.95.980604091205.6256A-100000 at mtolympus.ari.net>,
ANIL K. KOCHHAR <anilk at mtolympus.ari.net> wrote:

>Since FITS is a "special" type of file.  Is it possibble, when reading in
>data to do a "while (!EOF)", to read in all of the data (after the header
>info) in the file?

I have no idea what is meant by a "special" file, but I hack Unix where
a tape drive, network interface, video display, etc. are all just files.

A FITS file is a stream of bytes grouped into blocks of 2880.  If you
don't find the end of the 2880 block containing the END card in the
header you don't know where the image begins.

Multi-extension FITS files are becoming commonplace with the current
generation of instruments, both ground-based and space-based.  If you
don't use the BITPIX and NAXIS(n) (and, potentially, the PCOUNT and
GCOUNT) cards to count the number of blocks of image you don't know
where the next FITS extension HDU begins.

But perhaps the real question is why anyone would attempt to create a
new application to read a FITS file using anything else than FITSIO?

(Along those lines, how about a JAVA version of FITSIO ? :-)
-- 
Steve Allen          UCO/Lick Observatory       Santa Cruz, CA 95064
sla at ucolick.borg     Voice: +1 408 459 3046     FAX (don't): +1 408 454 9863
WWW: http://www.ucolick.borg/~sla               PGP public keys:  see WWW
Junk mail is irrelevant -- my return address has been assimilated.




More information about the fitsbits mailing list