Expand description
Pure-Rust FITS I/O, validated against CFITSIO 4.7.0.
This crate reimplements the FITS Standard 4.0 and CFITSIO’s documented
behaviour. It does not wrap libcfitsio. Status codes, ffgerr text,
and header-card formatting are locked to CFITSIO 4.7.0 by tests that
call the vendored C library.
Re-exports§
pub use card::Card;pub use card::fits_get_keyclass;pub use card::fits_get_keyname;pub use card::fits_make_key;pub use card::fits_parse_value;pub use card::fits_test_keyword;pub use card::make_card_string;pub use checksum::add_checksum_record;pub use checksum::decode_checksum;pub use checksum::encode_checksum;pub use checksum::fits_decode_chksum;pub use checksum::fits_encode_chksum;pub use checksum::fits_get_chksum;pub use checksum::fits_update_chksum;pub use checksum::fits_verify_chksum;pub use checksum::fits_write_chksum;pub use compress::CompressionType;pub use compress::fits_is_compressed_image;pub use compress::fits_set_compression_type;pub use edithdu::fits_copy_data;pub use edithdu::fits_copy_file;pub use edithdu::fits_copy_hdu;pub use edithdu::fits_copy_header;pub use edithdu::fits_create_hdu;pub use edithdu::fits_delete_hdu;pub use edithdu::fits_insert_atbl;pub use edithdu::fits_insert_btbl;pub use edithdu::fits_insert_img;pub use edithdu::fits_write_hdu;pub use error::FitsError;pub use error::Result;pub use error::clear_err_msg;pub use error::pop_err_msg;pub use error::push_err_msg;pub use file::AccessMode;pub use file::FitsFile;pub use file::fits_close_file;pub use file::fits_create_file;pub use file::fits_create_memfile;pub use file::fits_open_file;pub use header::AsciiTableInfo;pub use header::BinaryTableInfo;pub use header::Header;pub use header::PrimaryInfo;pub use image::Pixel;pub use image::fits_create_img;pub use image::fits_read_img;pub use image::fits_write_img;pub use keys::fits_read_key_str;pub use keys::fits_write_date;pub use keys::fits_write_key_str;pub use nbit::pack_samples;pub use nbit::samples_per_byte;pub use nbit::unpack_samples;pub use psrfits::CubeLayout;pub use psrfits::SubintInfo;pub use psrfits::apply_channel_weights;pub use psrfits::apply_scale;pub use psrfits::decode_packed_samples;pub use psrfits::encode_packed_samples;pub use psrfits::invert_scale;pub use status::fits_get_errstatus;pub use status::status_text;pub use table::fits_create_tbl;pub use table::fits_movabs_hdu;pub use tdim::decode_tdim;pub use tdim::fits_read_tdim;pub use tdim::fits_write_tdim;pub use tdim::format_tdim;pub use tdim::tdim_coords;pub use tdim::tdim_elem;pub use tdim::tdim_product;pub use tform::AsciiKind;pub use tform::AsciiTform;pub use tform::BinaryKind;pub use tform::BinaryTform;pub use tform::VariableKind;pub use tform::ascii_column_starts;pub use tform::binary_column_offsets;pub use tform::parse_ascii_tform;pub use tform::parse_binary_tform;pub use types::CARD_LEN;pub use types::CFITSIO_MAJOR;pub use types::CFITSIO_MICRO;pub use types::CFITSIO_MINOR;pub use types::GZIP_1;pub use types::GZIP_2;pub use types::HCOMPRESS_1;pub use types::HduType;pub use types::ImageType;pub use types::KeyClass;pub use types::NO_DITHER;pub use types::NO_QUANTIZE;pub use types::NOCOMPRESS;pub use types::PLIO_1;pub use types::RECORD_LEN;pub use types::RICE_1;pub use types::SUBTRACTIVE_DITHER_1;pub use types::SUBTRACTIVE_DITHER_2;pub use types::cfitsio_version_float;pub use wcs::pix_to_world;pub use wcs::read_img_coord;pub use wcs::world_to_pix;
Modules§
- bintable
- Binary table create / column I/O / variable-length heap.
- card
- 80-byte FITS header cards: parse, format, classify.
- checksum
- FITS
CHECKSUM/DATASUM(Seaman–Pence 32-bit 1’s complement). - compress
- Tiled image compression (FITS ZIMAGE binary tables).
- convert
- Implicit datatype conversion and BSCALE/BZERO scaling.
- datetime
- FITS DATE keyword utilities (
fits_write_date/ffpdat). - edithdu
- Copy, insert, and delete HDUs (
edithdu.c). - error
FitsError: CFITSIO status plus an optional message stack.- file
FitsFile: create, open, close.- hdu
- Header Data Unit metadata.
- header
- In-memory header: a sequence of 80-byte cards plus record padding.
- image
- Image HDU create / read / write.
- io
- Pluggable I/O backends. FITS is a sequence of 2880-byte records.
- keys
- Header keyword CRUD on
FitsFile(fits_write_key_*/ read / update / …). - nbit
- PSRFITS search-mode sample packing (
NBIT= 1, 2, 4, or 8). - psrfits
- PSRFITS convention helpers on top of binary-table vector I/O.
- status
- CFITSIO 4.7.0 error status codes and
ffgerrtext. - table
- ASCII table HDU create / column I/O / row-column edit.
- tdim
- Binary-table
TDIMnparse / write (ffgtdm/ffptdm) and Fortran-order indexing so a vector cell can be addressed as a multidimensional array. - tform
- ASCII-table TFORM parsing (
ffasfm), binary TFORM (ffbnfm), column spacing (ffgabc), and Cprintf-compatible field formatting. - types
- FITS / CFITSIO constants and datatype enumerations.
- wcs
- World coordinate conversion (
ffwldp/ffxypx/ffgics).