Compare commits

...

4 Commits

Author SHA1 Message Date
Jeff Moe 42b2ba35a5 qfits-6.2.0 2022-06-01 19:35:18 -06:00
Jeff Moe c8a2aa1667 qfits-6.1.0 2022-06-01 19:35:18 -06:00
Jeff Moe 467c94be86 qfits-6.0.0 2022-06-01 19:35:18 -06:00
Jeff Moe d3fa825fa0 qfits-5.4.0 2022-06-01 19:35:18 -06:00
215 changed files with 63748 additions and 31481 deletions

View File

@ -1,3 +1,2 @@
Nicolas Devillard ndevilla@eso.org
Yves Jung yjung@eso.org
Nicolas Devillard ndevilla@gmail.com Initial author
Yves Jung yjung@eso.org Maintainer since 2002

View File

@ -1,52 +0,0 @@
Installing qfits as an ANSI C library
-------------------------------------
% ./configure
% make
That should do it. You should now have a library called
libqfits.a in the lib/ directory, and the include files
you need are in the include/ directory.
To review possible configure options, type:
% configure --help
To install this library system-wide, use:
% make install
This will install the library in /usr/local. To change the
destination, use the --prefix option from configure.
Example: to install under /usr/local/qfits you would do:
% configure --prefix=/usr/local/qfits
If you want to perform basic tests, use:
% make check
Using qfits from C++
--------------------
Compile the C library with a C compiler and link your C++ program
against libqfits.a. It is not recommended to compile qfits with a
C++ compiler. Although this probably works, C code is not C++
code and you may run into trouble depending on the C++ compiler
you have.
Installing qfits as a Python module
-----------------------------------
See python/README in this directory.
Using qfits from other languages
--------------------------------
This used to be offered through a SWIG interface file, but
is not supported any more. If you want to interface qfits to e.g.
scripting languages like Perl or Tcl, check out SWIG at
http://www.swig.org
Mon Apr 15 13:17:42 CEST 2002

View File

@ -1,22 +0,0 @@
Copyright (c) 1995-2002, European Southern Observatory
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
files (the "Software"), to deal in the Software without
restriction, including without limitation the rights to use, copy,
modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

View File

@ -1,163 +0,0 @@
#
# qfits Makefile
#
include config.make
AR = ar
ARFLAGS = rcs
RM = rm -f
CP = cp -f
# Implicit rules
SUFFIXES = .o .c .h .a .so .sl
COMPILE.c=$(CC) $(CFLAGS) -Iinclude $(RELOC) -c
.c.o:
@(echo "compiling $< ...")
@($(COMPILE.c) -o $@ $<)
SRCS = src/byteswap.c \
src/cache.c \
src/expkey.c \
src/fits_h.c \
src/fits_md5.c \
src/fits_p.c \
src/fits_rw.c \
src/get_name.c \
src/ieeefp-compat.c \
src/md5.c \
src/pafs.c \
src/pixio.c \
src/qerror.c \
src/simple.c \
src/t_iso8601.c \
src/tfits.c \
src/version.c \
src/xmemory.c
OBJS = $(SRCS:.c=.o)
default: all
all: $(TARGETS) progs
check:
@(if test -d ./test ; then\
(echo "Executing test programs..." ; cd test ; $(MAKE) ; \
./test_qfits ;\
./test_pixio ;\
./test_tfits ;) ; \
else (true) fi)
static: lib/libqfits.a
dynamic: lib/libqfits.$(DYNSUF)
lib/libqfits.a: $(OBJS)
@(echo "Building static library...")
@($(AR) $(ARFLAGS) lib/libqfits.a $(OBJS))
lib/libqfits.$(DYNSUF): $(OBJS)
@(echo "Building shared library...")
@(ld $(SHARED) -o lib/libqfits.$(DYNSUF) $(OBJS) -lc)
install:
@(echo "Installing library in " $(prefix))
mkdir -p $(prefix)
mkdir -p $(prefix)/lib
mkdir -p $(prefix)/include
mkdir -p $(prefix)/bin
@(if test -f ./include/qfits.h ; then\
($(CP) include/qfits.h $(prefix)/include); \
else (true) fi)
@(if test -f ./include/xmemory.h ; then\
($(CP) include/xmemory.h $(prefix)/include); \
else (true) fi)
@(if test -f ./lib/libqfits.a ; then\
($(CP) lib/libqfits.a $(prefix)/lib); \
else (true) fi)
@(if test -f ./lib/libqfits.$(DYNSUF) ; then\
($(CP) lib/libqfits.$(DYNSUF) $(prefix)/lib); \
else (true) fi)
@(if test -f ./bin/dfits ; then\
($(CP) bin/dfits $(prefix)/bin); \
else (true) fi)
@(if test -f ./bin/dtfits ; then\
($(CP) bin/dtfits $(prefix)/bin); \
else (true) fi)
@(if test -f ./bin/fitsmd5 ; then\
($(CP) bin/fitsmd5 $(prefix)/bin); \
else (true) fi)
@(if test -f ./bin/fitsort ; then\
($(CP) bin/fitsort $(prefix)/bin); \
else (true) fi)
@(if test -f ./bin/flipx ; then\
($(CP) bin/flipx $(prefix)/bin); \
else (true) fi)
@(if test -f ./bin/hierarch28 ; then\
($(CP) bin/hierarch28 $(prefix)/bin); \
else (true) fi)
@(if test -f ./bin/iofits ; then\
($(CP) bin/iofits $(prefix)/bin); \
else (true) fi)
@(if test -f ./bin/replacekey ; then\
($(CP) bin/replacekey $(prefix)/bin); \
else (true) fi)
@(if test -f ./bin/qextract ; then\
($(CP) bin/qextract $(prefix)/bin); \
else (true) fi)
@(if test -f ./bin/frameq ; then\
($(CP) bin/frameq $(prefix)/bin); \
else (true) fi)
clean:
$(RM) $(OBJS)
veryclean:
$(RM) $(OBJS) lib/libqfits.a lib/libqfits.$(DYNSUF)
$(RM) -r build
@(if test -d ./test ; then \
(cd test ; $(MAKE) veryclean ; cd ..) \
else (true) fi)
cd main ; $(MAKE) veryclean ; cd ..
cd saft ; $(MAKE) veryclean ; cd ..
$(RM) config.make
#
# Build example and stand-alone programs
#
progs:
cd main ; $(MAKE) ; cd ..
cd saft ; $(MAKE) ; cd ..
#
# Building qfits as a Python module.
#
# type:
# % python setup.py build
# % python setup.py install
#
docs:
@(echo "Building HTML documentation...")
@(cd doc ; $(MAKE))

38
qfits/Makefile.am 100644
View File

@ -0,0 +1,38 @@
# AUTOMAKE_OPTIONS= 1.8 minimum expected version,
# foreign is most relaxed strictness
AUTOMAKE_OPTIONS = 1.8 foreign
# Include macros implemented in directory m4macros
ACLOCAL_AMFLAGS = -I m4macros
# DISTCLEANFILES= remove also *~ when execute make clean
DISTCLEANFILES = *~
# Build on subdirectories
SUBDIRS= src main saft test man
include_HEADERS = qfits.h
# Include the test for qfits options in the distribution
EXTRA_DIST = m4macros/qfits_memory.m4 admin/html.am doc/Doxyfile.in
MAINTAINERCLEANFILES = Makefile.in aclocal.m4 config.h.in config.log \
config.status configure stamp-h.in configure.scan autoscan.log \
admin/config.guess admin/config.sub admin/depcomp admin/install-sh \
admin/ltmain.sh admin/missing
clean-local: clean-html
dist-hook: html
@if test -d $(top_srcdir)/html; then \
echo "cp -pr $(top_srcdir)/html $(distdir)"; \
cp -pr $(top_srcdir)/html $(distdir); \
fi
find $(distdir) -type d ! -perm -222 -exec chmod u+w {} \; -o \
-type f ! -perm -222 -exec chmod u+w {} \; || chmod -R u+w $(distdir)
uninstall-local: uninstall-html
include $(top_srcdir)/admin/html.am

733
qfits/Makefile.in 100644
View File

@ -0,0 +1,733 @@
# Makefile.in generated by automake 1.8.5 from Makefile.am.
# @configure_input@
# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
# 2003, 2004 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
# PARTICULAR PURPOSE.
@SET_MAKE@
srcdir = @srcdir@
top_srcdir = @top_srcdir@
VPATH = @srcdir@
pkgdatadir = $(datadir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
top_builddir = .
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
INSTALL = @INSTALL@
install_sh_DATA = $(install_sh) -c -m 644
install_sh_PROGRAM = $(install_sh) -c
install_sh_SCRIPT = $(install_sh) -c
INSTALL_HEADER = $(INSTALL_DATA)
transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
host_triplet = @host@
DIST_COMMON = README $(am__configure_deps) $(include_HEADERS) \
$(srcdir)/Makefile.am $(srcdir)/Makefile.in \
$(srcdir)/config.h.in $(top_srcdir)/admin/html.am \
$(top_srcdir)/configure $(top_srcdir)/doc/Doxyfile.in AUTHORS \
admin/config.guess admin/config.sub admin/depcomp \
admin/install-sh admin/ltmain.sh admin/missing
subdir = .
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4macros/eso.m4 \
$(top_srcdir)/m4macros/qfits_memory.m4 \
$(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
configure.lineno configure.status.lineno
mkinstalldirs = $(mkdir_p)
CONFIG_HEADER = config.h
CONFIG_CLEAN_FILES = doc/Doxyfile
SOURCES =
DIST_SOURCES =
RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
html-recursive info-recursive install-data-recursive \
install-exec-recursive install-info-recursive \
install-recursive installcheck-recursive installdirs-recursive \
pdf-recursive ps-recursive uninstall-info-recursive \
uninstall-recursive
am__installdirs = "$(DESTDIR)$(includedir)"
includeHEADERS_INSTALL = $(INSTALL_HEADER)
HEADERS = $(include_HEADERS)
ETAGS = etags
CTAGS = ctags
DIST_SUBDIRS = $(SUBDIRS)
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
distdir = $(PACKAGE)-$(VERSION)
top_distdir = $(distdir)
am__remove_distdir = \
{ test ! -d $(distdir) \
|| { find $(distdir) -type d ! -perm -200 -exec chmod u+w {} ';' \
&& rm -fr $(distdir); }; }
DIST_ARCHIVES = $(distdir).tar.gz
GZIP_ENV = --best
distuninstallcheck_listfiles = find . -type f -print
distcleancheck_listfiles = find . -type f -print
ACLOCAL = @ACLOCAL@
AMDEP_FALSE = @AMDEP_FALSE@
AMDEP_TRUE = @AMDEP_TRUE@
AMTAR = @AMTAR@
AR = @AR@
AUTOCONF = @AUTOCONF@
AUTOHEADER = @AUTOHEADER@
AUTOMAKE = @AUTOMAKE@
AWK = @AWK@
CC = @CC@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
CPP = @CPP@
CPPFLAGS = @CPPFLAGS@
CXX = @CXX@
CXXCPP = @CXXCPP@
CXXDEPMODE = @CXXDEPMODE@
CXXFLAGS = @CXXFLAGS@
CYGPATH_W = @CYGPATH_W@
DEFS = @DEFS@
DEPDIR = @DEPDIR@
DOXYGEN = @DOXYGEN@
ECHO = @ECHO@
ECHO_C = @ECHO_C@
ECHO_N = @ECHO_N@
ECHO_T = @ECHO_T@
EGREP = @EGREP@
EXEEXT = @EXEEXT@
F77 = @F77@
FFLAGS = @FFLAGS@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
LATEX = @LATEX@
LDFLAGS = @LDFLAGS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LN_S = @LN_S@
LTLIBOBJS = @LTLIBOBJS@
LT_AGE = @LT_AGE@
LT_CURRENT = @LT_CURRENT@
LT_REVISION = @LT_REVISION@
MAKEINFO = @MAKEINFO@
OBJEXT = @OBJEXT@
PACKAGE = @PACKAGE@
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
PACKAGE_NAME = @PACKAGE_NAME@
PACKAGE_STRING = @PACKAGE_STRING@
PACKAGE_TARNAME = @PACKAGE_TARNAME@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
QFITS_CFLAGS = @QFITS_CFLAGS@
RANLIB = @RANLIB@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
STRIP = @STRIP@
VERSION = @VERSION@
ac_ct_AR = @ac_ct_AR@
ac_ct_CC = @ac_ct_CC@
ac_ct_CXX = @ac_ct_CXX@
ac_ct_F77 = @ac_ct_F77@
ac_ct_RANLIB = @ac_ct_RANLIB@
ac_ct_STRIP = @ac_ct_STRIP@
am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
am__fastdepCXX_TRUE = @am__fastdepCXX_TRUE@
am__include = @am__include@
am__leading_dot = @am__leading_dot@
am__quote = @am__quote@
bindir = @bindir@
build = @build@
build_alias = @build_alias@
build_cpu = @build_cpu@
build_os = @build_os@
build_vendor = @build_vendor@
datadir = @datadir@
exec_prefix = @exec_prefix@
host = @host@
host_alias = @host_alias@
host_cpu = @host_cpu@
host_os = @host_os@
host_vendor = @host_vendor@
includedir = @includedir@
infodir = @infodir@
install_sh = @install_sh@
libdir = @libdir@
libexecdir = @libexecdir@
localstatedir = @localstatedir@
mandir = @mandir@
mkdir_p = @mkdir_p@
oldincludedir = @oldincludedir@
prefix = @prefix@
program_transform_name = @program_transform_name@
sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
sysconfdir = @sysconfdir@
target_alias = @target_alias@
# AUTOMAKE_OPTIONS= 1.8 minimum expected version,
# foreign is most relaxed strictness
AUTOMAKE_OPTIONS = 1.8 foreign
# Include macros implemented in directory m4macros
ACLOCAL_AMFLAGS = -I m4macros
# DISTCLEANFILES= remove also *~ when execute make clean
DISTCLEANFILES = *~
# Build on subdirectories
SUBDIRS = src main saft test man
include_HEADERS = qfits.h
# Include the test for qfits options in the distribution
EXTRA_DIST = m4macros/qfits_memory.m4 admin/html.am doc/Doxyfile.in
MAINTAINERCLEANFILES = Makefile.in aclocal.m4 config.h.in config.log \
config.status configure stamp-h.in configure.scan autoscan.log \
admin/config.guess admin/config.sub admin/depcomp admin/install-sh \
admin/ltmain.sh admin/missing
HTML_RECURSIVE_TARGETS = install-html-recursive
all: config.h
$(MAKE) $(AM_MAKEFLAGS) all-recursive
.SUFFIXES:
am--refresh:
@:
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/admin/html.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
echo ' cd $(srcdir) && $(AUTOMAKE) --foreign '; \
cd $(srcdir) && $(AUTOMAKE) --foreign \
&& exit 0; \
exit 1;; \
esac; \
done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \
cd $(top_srcdir) && \
$(AUTOMAKE) --foreign Makefile
.PRECIOUS: Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \
*config.status*) \
echo ' $(SHELL) ./config.status'; \
$(SHELL) ./config.status;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
$(SHELL) ./config.status --recheck
$(top_srcdir)/configure: $(am__configure_deps)
cd $(srcdir) && $(AUTOCONF)
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS)
config.h: stamp-h1
@if test ! -f $@; then \
rm -f stamp-h1; \
$(MAKE) stamp-h1; \
else :; fi
stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status
@rm -f stamp-h1
cd $(top_builddir) && $(SHELL) ./config.status config.h
$(srcdir)/config.h.in: $(am__configure_deps)
cd $(top_srcdir) && $(AUTOHEADER)
rm -f stamp-h1
touch $@
distclean-hdr:
-rm -f config.h stamp-h1
doc/Doxyfile: $(top_builddir)/config.status $(top_srcdir)/doc/Doxyfile.in
cd $(top_builddir) && $(SHELL) ./config.status $@
mostlyclean-libtool:
-rm -f *.lo
clean-libtool:
-rm -rf .libs _libs
distclean-libtool:
-rm -f libtool
uninstall-info-am:
install-includeHEADERS: $(include_HEADERS)
@$(NORMAL_INSTALL)
test -z "$(includedir)" || $(mkdir_p) "$(DESTDIR)$(includedir)"
@list='$(include_HEADERS)'; for p in $$list; do \
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
f="`echo $$p | sed -e 's|^.*/||'`"; \
echo " $(includeHEADERS_INSTALL) '$$d$$p' '$(DESTDIR)$(includedir)/$$f'"; \
$(includeHEADERS_INSTALL) "$$d$$p" "$(DESTDIR)$(includedir)/$$f"; \
done
uninstall-includeHEADERS:
@$(NORMAL_UNINSTALL)
@list='$(include_HEADERS)'; for p in $$list; do \
f="`echo $$p | sed -e 's|^.*/||'`"; \
echo " rm -f '$(DESTDIR)$(includedir)/$$f'"; \
rm -f "$(DESTDIR)$(includedir)/$$f"; \
done
# This directory's subdirectories are mostly independent; you can cd
# into them and run `make' without going through this Makefile.
# To change the values of `make' variables: instead of editing Makefiles,
# (1) if the variable is set in `config.status', edit `config.status'
# (which will cause the Makefiles to be regenerated when you run `make');
# (2) otherwise, pass the desired values on the `make' command line.
$(RECURSIVE_TARGETS):
@set fnord $$MAKEFLAGS; amf=$$2; \
dot_seen=no; \
target=`echo $@ | sed s/-recursive//`; \
list='$(SUBDIRS)'; for subdir in $$list; do \
echo "Making $$target in $$subdir"; \
if test "$$subdir" = "."; then \
dot_seen=yes; \
local_target="$$target-am"; \
else \
local_target="$$target"; \
fi; \
(cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
|| case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
done; \
if test "$$dot_seen" = "no"; then \
$(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
fi; test -z "$$fail"
mostlyclean-recursive clean-recursive distclean-recursive \
maintainer-clean-recursive:
@set fnord $$MAKEFLAGS; amf=$$2; \
dot_seen=no; \
case "$@" in \
distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
*) list='$(SUBDIRS)' ;; \
esac; \
rev=''; for subdir in $$list; do \
if test "$$subdir" = "."; then :; else \
rev="$$subdir $$rev"; \
fi; \
done; \
rev="$$rev ."; \
target=`echo $@ | sed s/-recursive//`; \
for subdir in $$rev; do \
echo "Making $$target in $$subdir"; \
if test "$$subdir" = "."; then \
local_target="$$target-am"; \
else \
local_target="$$target"; \
fi; \
(cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
|| case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
done && test -z "$$fail"
tags-recursive:
list='$(SUBDIRS)'; for subdir in $$list; do \
test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
done
ctags-recursive:
list='$(SUBDIRS)'; for subdir in $$list; do \
test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
done
ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
$(AWK) ' { files[$$0] = 1; } \
END { for (i in files) print i; }'`; \
mkid -fID $$unique
tags: TAGS
TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \
$(TAGS_FILES) $(LISP)
tags=; \
here=`pwd`; \
if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
include_option=--etags-include; \
empty_fix=.; \
else \
include_option=--include; \
empty_fix=; \
fi; \
list='$(SUBDIRS)'; for subdir in $$list; do \
if test "$$subdir" = .; then :; else \
test ! -f $$subdir/TAGS || \
tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \
fi; \
done; \
list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
$(AWK) ' { files[$$0] = 1; } \
END { for (i in files) print i; }'`; \
if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
test -n "$$unique" || unique=$$empty_fix; \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
$$tags $$unique; \
fi
ctags: CTAGS
CTAGS: ctags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \
$(TAGS_FILES) $(LISP)
tags=; \
here=`pwd`; \
list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
$(AWK) ' { files[$$0] = 1; } \
END { for (i in files) print i; }'`; \
test -z "$(CTAGS_ARGS)$$tags$$unique" \
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
$$tags $$unique
GTAGS:
here=`$(am__cd) $(top_builddir) && pwd` \
&& cd $(top_srcdir) \
&& gtags -i $(GTAGS_ARGS) $$here
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(DISTFILES)
$(am__remove_distdir)
mkdir $(distdir)
$(mkdir_p) $(distdir)/admin $(distdir)/doc $(distdir)/m4macros
@srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \
list='$(DISTFILES)'; for file in $$list; do \
case $$file in \
$(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \
$(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \
esac; \
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \
if test "$$dir" != "$$file" && test "$$dir" != "."; then \
dir="/$$dir"; \
$(mkdir_p) "$(distdir)$$dir"; \
else \
dir=''; \
fi; \
if test -d $$d/$$file; then \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
fi; \
cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
else \
test -f $(distdir)/$$file \
|| cp -p $$d/$$file $(distdir)/$$file \
|| exit 1; \
fi; \
done
list='$(SUBDIRS)'; for subdir in $$list; do \
if test "$$subdir" = .; then :; else \
test -d "$(distdir)/$$subdir" \
|| mkdir "$(distdir)/$$subdir" \
|| exit 1; \
(cd $$subdir && \
$(MAKE) $(AM_MAKEFLAGS) \
top_distdir="../$(top_distdir)" \
distdir="../$(distdir)/$$subdir" \
distdir) \
|| exit 1; \
fi; \
done
$(MAKE) $(AM_MAKEFLAGS) \
top_distdir="$(top_distdir)" distdir="$(distdir)" \
dist-hook
-find $(distdir) -type d ! -perm -777 -exec chmod a+rwx {} \; -o \
! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \
! -type d ! -perm -400 -exec chmod a+r {} \; -o \
! -type d ! -perm -444 -exec $(SHELL) $(install_sh) -c -m a+r {} {} \; \
|| chmod -R a+r $(distdir)
dist-gzip: distdir
$(AMTAR) chof - $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
$(am__remove_distdir)
dist-bzip2: distdir
$(AMTAR) chof - $(distdir) | bzip2 -9 -c >$(distdir).tar.bz2
$(am__remove_distdir)
dist-tarZ: distdir
$(AMTAR) chof - $(distdir) | compress -c >$(distdir).tar.Z
$(am__remove_distdir)
dist-shar: distdir
shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz
$(am__remove_distdir)
dist-zip: distdir
-rm -f $(distdir).zip
zip -rq $(distdir).zip $(distdir)
$(am__remove_distdir)
dist dist-all: distdir
$(AMTAR) chof - $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
$(am__remove_distdir)
# This target untars the dist file and tries a VPATH configuration. Then
# it guarantees that the distribution is self-contained by making another
# tarfile.
distcheck: dist
case '$(DIST_ARCHIVES)' in \
*.tar.gz*) \
GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(AMTAR) xf - ;;\
*.tar.bz2*) \
bunzip2 -c $(distdir).tar.bz2 | $(AMTAR) xf - ;;\
*.tar.Z*) \
uncompress -c $(distdir).tar.Z | $(AMTAR) xf - ;;\
*.shar.gz*) \
GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\
*.zip*) \
unzip $(distdir).zip ;;\
esac
chmod -R a-w $(distdir); chmod a+w $(distdir)
mkdir $(distdir)/_build
mkdir $(distdir)/_inst
chmod a-w $(distdir)
dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \
&& dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \
&& cd $(distdir)/_build \
&& ../configure --srcdir=.. --prefix="$$dc_install_base" \
$(DISTCHECK_CONFIGURE_FLAGS) \
&& $(MAKE) $(AM_MAKEFLAGS) \
&& $(MAKE) $(AM_MAKEFLAGS) dvi \
&& $(MAKE) $(AM_MAKEFLAGS) check \
&& $(MAKE) $(AM_MAKEFLAGS) install \
&& $(MAKE) $(AM_MAKEFLAGS) installcheck \
&& $(MAKE) $(AM_MAKEFLAGS) uninstall \
&& $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \
distuninstallcheck \
&& chmod -R a-w "$$dc_install_base" \
&& ({ \
(cd ../.. && umask 077 && mkdir "$$dc_destdir") \
&& $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \
&& $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \
&& $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \
distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \
} || { rm -rf "$$dc_destdir"; exit 1; }) \
&& rm -rf "$$dc_destdir" \
&& $(MAKE) $(AM_MAKEFLAGS) dist \
&& rm -rf $(DIST_ARCHIVES) \
&& $(MAKE) $(AM_MAKEFLAGS) distcleancheck
$(am__remove_distdir)
@(echo "$(distdir) archives ready for distribution: "; \
list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \
sed -e '1{h;s/./=/g;p;x;}' -e '$${p;x;}'
distuninstallcheck:
@cd $(distuninstallcheck_dir) \
&& test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \
|| { echo "ERROR: files left after uninstall:" ; \
if test -n "$(DESTDIR)"; then \
echo " (check DESTDIR support)"; \
fi ; \
$(distuninstallcheck_listfiles) ; \
exit 1; } >&2
distcleancheck: distclean
@if test '$(srcdir)' = . ; then \
echo "ERROR: distcleancheck can only run from a VPATH build" ; \
exit 1 ; \
fi
@test `$(distcleancheck_listfiles) | wc -l` -eq 0 \
|| { echo "ERROR: files left in build directory after distclean:" ; \
$(distcleancheck_listfiles) ; \
exit 1; } >&2
check-am: all-am
check: check-recursive
all-am: Makefile $(HEADERS) config.h
installdirs: installdirs-recursive
installdirs-am:
for dir in "$(DESTDIR)$(includedir)"; do \
test -z "$$dir" || $(mkdir_p) "$$dir"; \
done
install: install-recursive
install-exec: install-exec-recursive
install-data: install-data-recursive
uninstall: uninstall-recursive
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
installcheck: installcheck-recursive
install-strip:
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
`test -z '$(STRIP)' || \
echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
mostlyclean-generic:
clean-generic:
distclean-generic:
-rm -f $(CONFIG_CLEAN_FILES)
-test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES)
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@echo "it deletes files that may require special tools to rebuild."
-test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
clean: clean-recursive
clean-am: clean-generic clean-libtool clean-local mostlyclean-am
distclean: distclean-recursive
-rm -f $(am__CONFIG_DISTCLEAN_FILES)
-rm -f Makefile
distclean-am: clean-am distclean-generic distclean-hdr \
distclean-libtool distclean-tags
dvi: dvi-recursive
dvi-am:
html: html-recursive
info: info-recursive
info-am:
install-data-am: install-includeHEADERS
install-exec-am:
install-info: install-info-recursive
install-man:
installcheck-am:
maintainer-clean: maintainer-clean-recursive
-rm -f $(am__CONFIG_DISTCLEAN_FILES)
-rm -rf $(top_srcdir)/autom4te.cache
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
mostlyclean: mostlyclean-recursive
mostlyclean-am: mostlyclean-generic mostlyclean-libtool
pdf: pdf-recursive
pdf-am:
ps: ps-recursive
ps-am:
uninstall-am: uninstall-includeHEADERS uninstall-info-am \
uninstall-local
uninstall-info: uninstall-info-recursive
.PHONY: $(RECURSIVE_TARGETS) CTAGS GTAGS all all-am am--refresh check \
check-am clean clean-generic clean-libtool clean-local \
clean-recursive ctags ctags-recursive dist dist-all dist-bzip2 \
dist-gzip dist-shar dist-tarZ dist-zip distcheck distclean \
distclean-generic distclean-hdr distclean-libtool \
distclean-recursive distclean-tags distcleancheck distdir \
distuninstallcheck dvi dvi-am html html-am info info-am \
install install-am install-data install-data-am install-exec \
install-exec-am install-includeHEADERS install-info \
install-info-am install-man install-strip installcheck \
installcheck-am installdirs installdirs-am maintainer-clean \
maintainer-clean-generic maintainer-clean-recursive \
mostlyclean mostlyclean-generic mostlyclean-libtool \
mostlyclean-recursive pdf pdf-am ps ps-am tags tags-recursive \
uninstall uninstall-am uninstall-includeHEADERS \
uninstall-info-am uninstall-local
clean-local: clean-html
dist-hook: html
@if test -d $(top_srcdir)/html; then \
echo "cp -pr $(top_srcdir)/html $(distdir)"; \
cp -pr $(top_srcdir)/html $(distdir); \
fi
find $(distdir) -type d ! -perm -222 -exec chmod u+w {} \; -o \
-type f ! -perm -222 -exec chmod u+w {} \; || chmod -R u+w $(distdir)
uninstall-local: uninstall-html
html-am:
@if test -f doc/Doxyfile; then \
echo "cd doc && $(DOXYGEN)"; \
d=`pwd`; cd doc && $(DOXYGEN); cd $$d; \
if test -n "$(POST_DOXYGEN_CLEANFILES)"; then \
cd $(top_srcdir)/html && rm -f $(POST_DOXYGEN_CLEANFILES); \
fi; \
else \
echo "Nothing to be done for \`$@'."; \
fi
clean-html: clean-html-am
clean-html-am:
-rm -rf $(top_srcdir)/html
install-html-am: html-am install-html-generic
install-html: install-html-recursive
install-html-generic:
@$(NORMAL_INSTALL)
@if test -d $(top_srcdir)/html; then \
echo "$(mkinstalldirs) $(DESTDIR)$(htmldir)"; \
$(mkinstalldirs) $(DESTDIR)$(htmldir); \
list="`ls -1 $(top_srcdir)/html`"; \
for p in $$list; do \
if test -f $(top_srcdir)/html/$$p; then \
echo " $(INSTALL_DATA) $(top_srcdir)/html/$$p $(DESTDIR)$(htmldir)/$$p"; \
$(INSTALL_DATA) $(top_srcdir)/html/$$p $(DESTDIR)$(htmldir)/$$p; \
else if test -f $$p; then \
echo " $(INSTALL_DATA) $$p $(DESTDIR)$(htmldir)/$$p"; \
$(INSTALL_DATA) $$p $(DESTDIR)$(htmldir)/$$p; \
fi; fi; \
done; \
fi
uninstall-html:
@$(NORMAL_UNINSTALL)
@list="`ls -1 $(DESTDIR)$(htmldir)`"; for p in $$list; do \
echo " rm -f $(DESTDIR)$(htmldir)/$$p"; \
rm -f $(DESTDIR)$(htmldir)/$$p; \
done
$(HTML_RECURSIVE_TARGETS):
@set fnord $(MAKEFLAGS); amf=$$2; \
dot_seen=no; \
target=`echo $@ | sed s/-recursive//`; \
list='$(HTML_SUBDIRS)'; for subdir in $$list; do \
echo "Making $$target in $$subdir"; \
if test "$$subdir" = "."; then \
dot_seen=yes; \
local_target="$$target-am"; \
else \
local_target="$$target"; \
fi; \
(cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
|| case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
done; \
if test "$$dot_seen" = "no"; then \
$(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
fi; test -z "$$fail"
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:

View File

@ -2,8 +2,6 @@
qfits: quick FITS library
-------------------------
Introduction
------------
@ -17,8 +15,6 @@ ensures that all features present in the library have been
thoroughly tested, since they are all used daily in a production
environment.
Overview
--------
@ -46,8 +42,6 @@ qfits only gives you handles on the FITS format, it does not
provide extra functionalities related to table or image
processing, this is left to other (higher-level) libraries.
Implementation
--------------
@ -67,10 +61,3 @@ reliably on the following platforms:
qfits should work fine on all POSIX-compliant Unixes. If you port
qfits to any other platform, please let me know.
qfits also exports a limited number of functionalities to
retrieve and parse FITS headers under Python. See the INSTALL
file to learn how to install qfits as a Python module.
--
Mon Apr 15 14:14:12 CEST 2002

6818
qfits/aclocal.m4 vendored 100644

File diff suppressed because it is too large Load Diff

1459
qfits/admin/config.guess vendored 100755

File diff suppressed because it is too large Load Diff

1549
qfits/admin/config.sub vendored 100755

File diff suppressed because it is too large Load Diff

526
qfits/admin/depcomp 100755
View File

@ -0,0 +1,526 @@
#! /bin/sh
# depcomp - compile a program generating dependencies as side-effects
scriptversion=2004-04-25.13
# Copyright (C) 1999, 2000, 2003, 2004 Free Software Foundation, Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
# This program 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 General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
# 02111-1307, USA.
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
# Originally written by Alexandre Oliva <oliva@dcc.unicamp.br>.
case $1 in
'')
echo "$0: No command. Try \`$0 --help' for more information." 1>&2
exit 1;
;;
-h | --h*)
cat <<\EOF
Usage: depcomp [--help] [--version] PROGRAM [ARGS]
Run PROGRAMS ARGS to compile a file, generating dependencies
as side-effects.
Environment variables:
depmode Dependency tracking mode.
source Source file read by `PROGRAMS ARGS'.
object Object file output by `PROGRAMS ARGS'.
depfile Dependency file to output.
tmpdepfile Temporary file to use when outputing dependencies.
libtool Whether libtool is used (yes/no).
Report bugs to <bug-automake@gnu.org>.
EOF
exit 0
;;
-v | --v*)
echo "depcomp $scriptversion"
exit 0
;;
esac
if test -z "$depmode" || test -z "$source" || test -z "$object"; then
echo "depcomp: Variables source, object and depmode must be set" 1>&2
exit 1
fi
# `libtool' can also be set to `yes' or `no'.
if test -z "$depfile"; then
base=`echo "$object" | sed -e 's,^.*/,,' -e 's,\.\([^.]*\)$,.P\1,'`
dir=`echo "$object" | sed 's,/.*$,/,'`
if test "$dir" = "$object"; then
dir=
fi
# FIXME: should be _deps on DOS.
depfile="$dir.deps/$base"
fi
tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`}
rm -f "$tmpdepfile"
# Some modes work just like other modes, but use different flags. We
# parameterize here, but still list the modes in the big case below,
# to make depend.m4 easier to write. Note that we *cannot* use a case
# here, because this file can only contain one case statement.
if test "$depmode" = hp; then
# HP compiler uses -M and no extra arg.
gccflag=-M
depmode=gcc
fi
if test "$depmode" = dashXmstdout; then
# This is just like dashmstdout with a different argument.
dashmflag=-xM
depmode=dashmstdout
fi
case "$depmode" in
gcc3)
## gcc 3 implements dependency tracking that does exactly what
## we want. Yay! Note: for some reason libtool 1.4 doesn't like
## it if -MD -MP comes after the -MF stuff. Hmm.
"$@" -MT "$object" -MD -MP -MF "$tmpdepfile"
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile"
exit $stat
fi
mv "$tmpdepfile" "$depfile"
;;
gcc)
## There are various ways to get dependency output from gcc. Here's
## why we pick this rather obscure method:
## - Don't want to use -MD because we'd like the dependencies to end
## up in a subdir. Having to rename by hand is ugly.
## (We might end up doing this anyway to support other compilers.)
## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like
## -MM, not -M (despite what the docs say).
## - Using -M directly means running the compiler twice (even worse
## than renaming).
if test -z "$gccflag"; then
gccflag=-MD,
fi
"$@" -Wp,"$gccflag$tmpdepfile"
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile"
exit $stat
fi
rm -f "$depfile"
echo "$object : \\" > "$depfile"
alpha=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
## The second -e expression handles DOS-style file names with drive letters.
sed -e 's/^[^:]*: / /' \
-e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile"
## This next piece of magic avoids the `deleted header file' problem.
## The problem is that when a header file which appears in a .P file
## is deleted, the dependency causes make to die (because there is
## typically no way to rebuild the header). We avoid this by adding
## dummy dependencies for each header file. Too bad gcc doesn't do
## this for us directly.
tr ' ' '
' < "$tmpdepfile" |
## Some versions of gcc put a space before the `:'. On the theory
## that the space means something, we add a space to the output as
## well.
## Some versions of the HPUX 10.20 sed can't process this invocation
## correctly. Breaking it into two sed invocations is a workaround.
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
rm -f "$tmpdepfile"
;;
hp)
# This case exists only to let depend.m4 do its work. It works by
# looking at the text of this script. This case will never be run,
# since it is checked for above.
exit 1
;;
sgi)
if test "$libtool" = yes; then
"$@" "-Wp,-MDupdate,$tmpdepfile"
else
"$@" -MDupdate "$tmpdepfile"
fi
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile"
exit $stat
fi
rm -f "$depfile"
if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files
echo "$object : \\" > "$depfile"
# Clip off the initial element (the dependent). Don't try to be
# clever and replace this with sed code, as IRIX sed won't handle
# lines with more than a fixed number of characters (4096 in
# IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines;
# the IRIX cc adds comments like `#:fec' to the end of the
# dependency line.
tr ' ' '
' < "$tmpdepfile" \
| sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \
tr '
' ' ' >> $depfile
echo >> $depfile
# The second pass generates a dummy entry for each header file.
tr ' ' '
' < "$tmpdepfile" \
| sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \
>> $depfile
else
# The sourcefile does not contain any dependencies, so just
# store a dummy comment line, to avoid errors with the Makefile
# "include basename.Plo" scheme.
echo "#dummy" > "$depfile"
fi
rm -f "$tmpdepfile"
;;
aix)
# The C for AIX Compiler uses -M and outputs the dependencies
# in a .u file. In older versions, this file always lives in the
# current directory. Also, the AIX compiler puts `$object:' at the
# start of each line; $object doesn't have directory information.
# Version 6 uses the directory in both cases.
stripped=`echo "$object" | sed 's/\(.*\)\..*$/\1/'`
tmpdepfile="$stripped.u"
if test "$libtool" = yes; then
"$@" -Wc,-M
else
"$@" -M
fi
stat=$?
if test -f "$tmpdepfile"; then :
else
stripped=`echo "$stripped" | sed 's,^.*/,,'`
tmpdepfile="$stripped.u"
fi
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile"
exit $stat
fi
if test -f "$tmpdepfile"; then
outname="$stripped.o"
# Each line is of the form `foo.o: dependent.h'.
# Do two passes, one to just change these to
# `$object: dependent.h' and one to simply `dependent.h:'.
sed -e "s,^$outname:,$object :," < "$tmpdepfile" > "$depfile"
sed -e "s,^$outname: \(.*\)$,\1:," < "$tmpdepfile" >> "$depfile"
else
# The sourcefile does not contain any dependencies, so just
# store a dummy comment line, to avoid errors with the Makefile
# "include basename.Plo" scheme.
echo "#dummy" > "$depfile"
fi
rm -f "$tmpdepfile"
;;
icc)
# Intel's C compiler understands `-MD -MF file'. However on
# icc -MD -MF foo.d -c -o sub/foo.o sub/foo.c
# ICC 7.0 will fill foo.d with something like
# foo.o: sub/foo.c
# foo.o: sub/foo.h
# which is wrong. We want:
# sub/foo.o: sub/foo.c
# sub/foo.o: sub/foo.h
# sub/foo.c:
# sub/foo.h:
# ICC 7.1 will output
# foo.o: sub/foo.c sub/foo.h
# and will wrap long lines using \ :
# foo.o: sub/foo.c ... \
# sub/foo.h ... \
# ...
"$@" -MD -MF "$tmpdepfile"
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile"
exit $stat
fi
rm -f "$depfile"
# Each line is of the form `foo.o: dependent.h',
# or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'.
# Do two passes, one to just change these to
# `$object: dependent.h' and one to simply `dependent.h:'.
sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile"
# Some versions of the HPUX 10.20 sed can't process this invocation
# correctly. Breaking it into two sed invocations is a workaround.
sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" |
sed -e 's/$/ :/' >> "$depfile"
rm -f "$tmpdepfile"
;;
tru64)
# The Tru64 compiler uses -MD to generate dependencies as a side
# effect. `cc -MD -o foo.o ...' puts the dependencies into `foo.o.d'.
# At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put
# dependencies in `foo.d' instead, so we check for that too.
# Subdirectories are respected.
dir=`echo "$object" | sed -e 's|/[^/]*$|/|'`
test "x$dir" = "x$object" && dir=
base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'`
if test "$libtool" = yes; then
# Dependencies are output in .lo.d with libtool 1.4.
# They are output in .o.d with libtool 1.5.
tmpdepfile1="$dir.libs/$base.lo.d"
tmpdepfile2="$dir.libs/$base.o.d"
tmpdepfile3="$dir.libs/$base.d"
"$@" -Wc,-MD
else
tmpdepfile1="$dir$base.o.d"
tmpdepfile2="$dir$base.d"
tmpdepfile3="$dir$base.d"
"$@" -MD
fi
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3"
exit $stat
fi
if test -f "$tmpdepfile1"; then
tmpdepfile="$tmpdepfile1"
elif test -f "$tmpdepfile2"; then
tmpdepfile="$tmpdepfile2"
else
tmpdepfile="$tmpdepfile3"
fi
if test -f "$tmpdepfile"; then
sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile"
# That's a tab and a space in the [].
sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile"
else
echo "#dummy" > "$depfile"
fi
rm -f "$tmpdepfile"
;;
#nosideeffect)
# This comment above is used by automake to tell side-effect
# dependency tracking mechanisms from slower ones.
dashmstdout)
# Important note: in order to support this mode, a compiler *must*
# always write the preprocessed file to stdout, regardless of -o.
"$@" || exit $?
# Remove the call to Libtool.
if test "$libtool" = yes; then
while test $1 != '--mode=compile'; do
shift
done
shift
fi
# Remove `-o $object'.
IFS=" "
for arg
do
case $arg in
-o)
shift
;;
$object)
shift
;;
*)
set fnord "$@" "$arg"
shift # fnord
shift # $arg
;;
esac
done
test -z "$dashmflag" && dashmflag=-M
# Require at least two characters before searching for `:'
# in the target name. This is to cope with DOS-style filenames:
# a dependency such as `c:/foo/bar' could be seen as target `c' otherwise.
"$@" $dashmflag |
sed 's:^[ ]*[^: ][^:][^:]*\:[ ]*:'"$object"'\: :' > "$tmpdepfile"
rm -f "$depfile"
cat < "$tmpdepfile" > "$depfile"
tr ' ' '
' < "$tmpdepfile" | \
## Some versions of the HPUX 10.20 sed can't process this invocation
## correctly. Breaking it into two sed invocations is a workaround.
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
rm -f "$tmpdepfile"
;;
dashXmstdout)
# This case only exists to satisfy depend.m4. It is never actually
# run, as this mode is specially recognized in the preamble.
exit 1
;;
makedepend)
"$@" || exit $?
# Remove any Libtool call
if test "$libtool" = yes; then
while test $1 != '--mode=compile'; do
shift
done
shift
fi
# X makedepend
shift
cleared=no
for arg in "$@"; do
case $cleared in
no)
set ""; shift
cleared=yes ;;
esac
case "$arg" in
-D*|-I*)
set fnord "$@" "$arg"; shift ;;
# Strip any option that makedepend may not understand. Remove
# the object too, otherwise makedepend will parse it as a source file.
-*|$object)
;;
*)
set fnord "$@" "$arg"; shift ;;
esac
done
obj_suffix="`echo $object | sed 's/^.*\././'`"
touch "$tmpdepfile"
${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@"
rm -f "$depfile"
cat < "$tmpdepfile" > "$depfile"
sed '1,2d' "$tmpdepfile" | tr ' ' '
' | \
## Some versions of the HPUX 10.20 sed can't process this invocation
## correctly. Breaking it into two sed invocations is a workaround.
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
rm -f "$tmpdepfile" "$tmpdepfile".bak
;;
cpp)
# Important note: in order to support this mode, a compiler *must*
# always write the preprocessed file to stdout.
"$@" || exit $?
# Remove the call to Libtool.
if test "$libtool" = yes; then
while test $1 != '--mode=compile'; do
shift
done
shift
fi
# Remove `-o $object'.
IFS=" "
for arg
do
case $arg in
-o)
shift
;;
$object)
shift
;;
*)
set fnord "$@" "$arg"
shift # fnord
shift # $arg
;;
esac
done
"$@" -E |
sed -n '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' |
sed '$ s: \\$::' > "$tmpdepfile"
rm -f "$depfile"
echo "$object : \\" > "$depfile"
cat < "$tmpdepfile" >> "$depfile"
sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile"
rm -f "$tmpdepfile"
;;
msvisualcpp)
# Important note: in order to support this mode, a compiler *must*
# always write the preprocessed file to stdout, regardless of -o,
# because we must use -o when running libtool.
"$@" || exit $?
IFS=" "
for arg
do
case "$arg" in
"-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI")
set fnord "$@"
shift
shift
;;
*)
set fnord "$@" "$arg"
shift
shift
;;
esac
done
"$@" -E |
sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::echo "`cygpath -u \\"\1\\"`":p' | sort | uniq > "$tmpdepfile"
rm -f "$depfile"
echo "$object : \\" > "$depfile"
. "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s:: \1 \\:p' >> "$depfile"
echo " " >> "$depfile"
. "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s::\1\::p' >> "$depfile"
rm -f "$tmpdepfile"
;;
none)
exec "$@"
;;
*)
echo "Unknown depmode $depmode" 1>&2
exit 1
;;
esac
exit 0
# Local Variables:
# mode: shell-script
# sh-indentation: 2
# eval: (add-hook 'write-file-hooks 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-end: "$"
# End:

View File

@ -0,0 +1,65 @@
HTML_RECURSIVE_TARGETS = install-html-recursive
html-am:
@if test -f doc/Doxyfile; then \
echo "cd doc && $(DOXYGEN)"; \
d=`pwd`; cd doc && $(DOXYGEN); cd $$d; \
if test -n "$(POST_DOXYGEN_CLEANFILES)"; then \
cd $(top_srcdir)/html && rm -f $(POST_DOXYGEN_CLEANFILES); \
fi; \
else \
echo "Nothing to be done for \`$@'."; \
fi
clean-html: clean-html-am
clean-html-am:
-rm -rf $(top_srcdir)/html
install-html-am: html-am install-html-generic
install-html: install-html-recursive
install-html-generic:
@$(NORMAL_INSTALL)
@if test -d $(top_srcdir)/html; then \
echo "$(mkinstalldirs) $(DESTDIR)$(htmldir)"; \
$(mkinstalldirs) $(DESTDIR)$(htmldir); \
list="`ls -1 $(top_srcdir)/html`"; \
for p in $$list; do \
if test -f $(top_srcdir)/html/$$p; then \
echo " $(INSTALL_DATA) $(top_srcdir)/html/$$p $(DESTDIR)$(htmldir)/$$p"; \
$(INSTALL_DATA) $(top_srcdir)/html/$$p $(DESTDIR)$(htmldir)/$$p; \
else if test -f $$p; then \
echo " $(INSTALL_DATA) $$p $(DESTDIR)$(htmldir)/$$p"; \
$(INSTALL_DATA) $$p $(DESTDIR)$(htmldir)/$$p; \
fi; fi; \
done; \
fi
uninstall-html:
@$(NORMAL_UNINSTALL)
@list="`ls -1 $(DESTDIR)$(htmldir)`"; for p in $$list; do \
echo " rm -f $(DESTDIR)$(htmldir)/$$p"; \
rm -f $(DESTDIR)$(htmldir)/$$p; \
done
$(HTML_RECURSIVE_TARGETS):
@set fnord $(MAKEFLAGS); amf=$$2; \
dot_seen=no; \
target=`echo $@ | sed s/-recursive//`; \
list='$(HTML_SUBDIRS)'; for subdir in $$list; do \
echo "Making $$target in $$subdir"; \
if test "$$subdir" = "."; then \
dot_seen=yes; \
local_target="$$target-am"; \
else \
local_target="$$target"; \
fi; \
(cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
|| case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
done; \
if test "$$dot_seen" = "no"; then \
$(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
fi; test -z "$$fail"

View File

@ -0,0 +1,325 @@
#!/bin/sh
# install - install a program, script, or datafile
scriptversion=2004-04-01.17
# This originates from X11R5 (mit/util/scripts/install.sh), which was
# later released in X11R6 (xc/config/util/install.sh) with the
# following copyright and license.
#
# Copyright (C) 1994 X Consortium
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to
# deal in the Software without restriction, including without limitation the
# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
# sell copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in
# all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC-
# TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#
# Except as contained in this notice, the name of the X Consortium shall not
# be used in advertising or otherwise to promote the sale, use or other deal-
# ings in this Software without prior written authorization from the X Consor-
# tium.
#
#
# FSF changes to this file are in the public domain.
#
# Calling this script install-sh is preferred over install.sh, to prevent
# `make' implicit rules from creating a file called install from it
# when there is no Makefile.
#
# This script is compatible with the BSD install script, but was written
# from scratch. It can only install one file at a time, a restriction
# shared with many OS's install programs.
# set DOITPROG to echo to test this script
# Don't use :- since 4.3BSD and earlier shells don't like it.
doit="${DOITPROG-}"
# put in absolute paths if you don't have them in your path; or use env. vars.
mvprog="${MVPROG-mv}"
cpprog="${CPPROG-cp}"
chmodprog="${CHMODPROG-chmod}"
chownprog="${CHOWNPROG-chown}"
chgrpprog="${CHGRPPROG-chgrp}"
stripprog="${STRIPPROG-strip}"
rmprog="${RMPROG-rm}"
mkdirprog="${MKDIRPROG-mkdir}"
transformbasename=
transform_arg=
instcmd="$mvprog"
chmodcmd="$chmodprog 0755"
chowncmd=
chgrpcmd=
stripcmd=
rmcmd="$rmprog -f"
mvcmd="$mvprog"
src=
dst=
dir_arg=
usage="Usage: $0 [OPTION]... SRCFILE DSTFILE
or: $0 [OPTION]... SRCFILES... DIRECTORY
or: $0 -d DIRECTORIES...
In the first form, install SRCFILE to DSTFILE, removing SRCFILE by default.
In the second, create the directory path DIR.
Options:
-b=TRANSFORMBASENAME
-c copy source (using $cpprog) instead of moving (using $mvprog).
-d create directories instead of installing files.
-g GROUP $chgrp installed files to GROUP.
-m MODE $chmod installed files to MODE.
-o USER $chown installed files to USER.
-s strip installed files (using $stripprog).
-t=TRANSFORM
--help display this help and exit.
--version display version info and exit.
Environment variables override the default commands:
CHGRPPROG CHMODPROG CHOWNPROG CPPROG MKDIRPROG MVPROG RMPROG STRIPPROG
"
while test -n "$1"; do
case $1 in
-b=*) transformbasename=`echo $1 | sed 's/-b=//'`
shift
continue;;
-c) instcmd=$cpprog
shift
continue;;
-d) dir_arg=true
shift
continue;;
-g) chgrpcmd="$chgrpprog $2"
shift
shift
continue;;
--help) echo "$usage"; exit 0;;
-m) chmodcmd="$chmodprog $2"
shift
shift
continue;;
-o) chowncmd="$chownprog $2"
shift
shift
continue;;
-s) stripcmd=$stripprog
shift
continue;;
-t=*) transformarg=`echo $1 | sed 's/-t=//'`
shift
continue;;
--version) echo "$0 $scriptversion"; exit 0;;
*) # When -d is used, all remaining arguments are directories to create.
test -n "$dir_arg" && break
# Otherwise, the last argument is the destination. Remove it from $@.
for arg
do
if test -n "$dstarg"; then
# $@ is not empty: it contains at least $arg.
set fnord "$@" "$dstarg"
shift # fnord
fi
shift # arg
dstarg=$arg
done
break;;
esac
done
if test -z "$1"; then
if test -z "$dir_arg"; then
echo "$0: no input file specified." >&2
exit 1
fi
# It's OK to call `install-sh -d' without argument.
# This can happen when creating conditional directories.
exit 0
fi
for src
do
# Protect names starting with `-'.
case $src in
-*) src=./$src ;;
esac
if test -n "$dir_arg"; then
dst=$src
src=
if test -d "$dst"; then
instcmd=:
chmodcmd=
else
instcmd=$mkdirprog
fi
else
# Waiting for this to be detected by the "$instcmd $src $dsttmp" command
# might cause directories to be created, which would be especially bad
# if $src (and thus $dsttmp) contains '*'.
if test ! -f "$src" && test ! -d "$src"; then
echo "$0: $src does not exist." >&2
exit 1
fi
if test -z "$dstarg"; then
echo "$0: no destination specified." >&2
exit 1
fi
dst=$dstarg
# Protect names starting with `-'.
case $dst in
-*) dst=./$dst ;;
esac
# If destination is a directory, append the input filename; won't work
# if double slashes aren't ignored.
if test -d "$dst"; then
dst=$dst/`basename "$src"`
fi
fi
# This sed command emulates the dirname command.
dstdir=`echo "$dst" | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'`
# Make sure that the destination directory exists.
# Skip lots of stat calls in the usual case.
if test ! -d "$dstdir"; then
defaultIFS='
'
IFS="${IFS-$defaultIFS}"
oIFS=$IFS
# Some sh's can't handle IFS=/ for some reason.
IFS='%'
set - `echo "$dstdir" | sed -e 's@/@%@g' -e 's@^%@/@'`
IFS=$oIFS
pathcomp=
while test $# -ne 0 ; do
pathcomp=$pathcomp$1
shift
if test ! -d "$pathcomp"; then
$mkdirprog "$pathcomp" || lasterr=$?
# mkdir can fail with a `File exist' error in case several
# install-sh are creating the directory concurrently. This
# is OK.
test ! -d "$pathcomp" && { (exit ${lasterr-1}); exit; }
fi
pathcomp=$pathcomp/
done
fi
if test -n "$dir_arg"; then
$doit $instcmd "$dst" \
&& { test -z "$chowncmd" || $doit $chowncmd "$dst"; } \
&& { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } \
&& { test -z "$stripcmd" || $doit $stripcmd "$dst"; } \
&& { test -z "$chmodcmd" || $doit $chmodcmd "$dst"; }
else
# If we're going to rename the final executable, determine the name now.
if test -z "$transformarg"; then
dstfile=`basename "$dst"`
else
dstfile=`basename "$dst" $transformbasename \
| sed $transformarg`$transformbasename
fi
# don't allow the sed command to completely eliminate the filename.
test -z "$dstfile" && dstfile=`basename "$dst"`
# Make a couple of temp file names in the proper directory.
dsttmp=$dstdir/_inst.$$_
rmtmp=$dstdir/_rm.$$_
# Trap to clean up those temp files at exit.
trap 'status=$?; rm -f "$dsttmp" "$rmtmp" && exit $status' 0
trap '(exit $?); exit' 1 2 13 15
# Move or copy the file name to the temp name
$doit $instcmd "$src" "$dsttmp" &&
# and set any options; do chmod last to preserve setuid bits.
#
# If any of these fail, we abort the whole thing. If we want to
# ignore errors from any of these, just make sure not to ignore
# errors from the above "$doit $instcmd $src $dsttmp" command.
#
{ test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } \
&& { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } \
&& { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } \
&& { test -z "$chmodcmd" || $doit $chmodcmd "$dsttmp"; } &&
# Now rename the file to the real destination.
{ $doit $mvcmd -f "$dsttmp" "$dstdir/$dstfile" 2>/dev/null \
|| {
# The rename failed, perhaps because mv can't rename something else
# to itself, or perhaps because mv is so ancient that it does not
# support -f.
# Now remove or move aside any old file at destination location.
# We try this two ways since rm can't unlink itself on some
# systems and the destination file might be busy for other
# reasons. In this case, the final cleanup might fail but the new
# file should still install successfully.
{
if test -f "$dstdir/$dstfile"; then
$doit $rmcmd -f "$dstdir/$dstfile" 2>/dev/null \
|| $doit $mvcmd -f "$dstdir/$dstfile" "$rmtmp" 2>/dev/null \
|| {
echo "$0: cannot unlink or rename $dstdir/$dstfile" >&2
(exit 1); exit
}
else
:
fi
} &&
# Now rename the file to the real destination.
$doit $mvcmd "$dsttmp" "$dstdir/$dstfile"
}
}
fi || { (exit 1); exit; }
done
# The final little trick to "correctly" pass the exit status to the exit trap.
{
(exit 0); exit
}
# Local variables:
# eval: (add-hook 'write-file-hooks 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-end: "$"
# End:

6422
qfits/admin/ltmain.sh 100644

File diff suppressed because it is too large Load Diff

360
qfits/admin/missing 100755
View File

@ -0,0 +1,360 @@
#! /bin/sh
# Common stub for a few missing GNU programs while installing.
scriptversion=2003-09-02.23
# Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003
# Free Software Foundation, Inc.
# Originally by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
# This program 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 General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
# 02111-1307, USA.
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
if test $# -eq 0; then
echo 1>&2 "Try \`$0 --help' for more information"
exit 1
fi
run=:
# In the cases where this matters, `missing' is being run in the
# srcdir already.
if test -f configure.ac; then
configure_ac=configure.ac
else
configure_ac=configure.in
fi
msg="missing on your system"
case "$1" in
--run)
# Try to run requested program, and just exit if it succeeds.
run=
shift
"$@" && exit 0
# Exit code 63 means version mismatch. This often happens
# when the user try to use an ancient version of a tool on
# a file that requires a minimum version. In this case we
# we should proceed has if the program had been absent, or
# if --run hadn't been passed.
if test $? = 63; then
run=:
msg="probably too old"
fi
;;
esac
# If it does not exist, or fails to run (possibly an outdated version),
# try to emulate it.
case "$1" in
-h|--h|--he|--hel|--help)
echo "\
$0 [OPTION]... PROGRAM [ARGUMENT]...
Handle \`PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an
error status if there is no known handling for PROGRAM.
Options:
-h, --help display this help and exit
-v, --version output version information and exit
--run try to run the given command, and emulate it if it fails
Supported PROGRAM values:
aclocal touch file \`aclocal.m4'
autoconf touch file \`configure'
autoheader touch file \`config.h.in'
automake touch all \`Makefile.in' files
bison create \`y.tab.[ch]', if possible, from existing .[ch]
flex create \`lex.yy.c', if possible, from existing .c
help2man touch the output file
lex create \`lex.yy.c', if possible, from existing .c
makeinfo touch the output file
tar try tar, gnutar, gtar, then tar without non-portable flags
yacc create \`y.tab.[ch]', if possible, from existing .[ch]
Send bug reports to <bug-automake@gnu.org>."
;;
-v|--v|--ve|--ver|--vers|--versi|--versio|--version)
echo "missing $scriptversion (GNU Automake)"
;;
-*)
echo 1>&2 "$0: Unknown \`$1' option"
echo 1>&2 "Try \`$0 --help' for more information"
exit 1
;;
aclocal*)
if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
# We have it, but it failed.
exit 1
fi
echo 1>&2 "\
WARNING: \`$1' is $msg. You should only need it if
you modified \`acinclude.m4' or \`${configure_ac}'. You might want
to install the \`Automake' and \`Perl' packages. Grab them from
any GNU archive site."
touch aclocal.m4
;;
autoconf)
if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
# We have it, but it failed.
exit 1
fi
echo 1>&2 "\
WARNING: \`$1' is $msg. You should only need it if
you modified \`${configure_ac}'. You might want to install the
\`Autoconf' and \`GNU m4' packages. Grab them from any GNU
archive site."
touch configure
;;
autoheader)
if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
# We have it, but it failed.
exit 1
fi
echo 1>&2 "\
WARNING: \`$1' is $msg. You should only need it if
you modified \`acconfig.h' or \`${configure_ac}'. You might want
to install the \`Autoconf' and \`GNU m4' packages. Grab them
from any GNU archive site."
files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}`
test -z "$files" && files="config.h"
touch_files=
for f in $files; do
case "$f" in
*:*) touch_files="$touch_files "`echo "$f" |
sed -e 's/^[^:]*://' -e 's/:.*//'`;;
*) touch_files="$touch_files $f.in";;
esac
done
touch $touch_files
;;
automake*)
if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
# We have it, but it failed.
exit 1
fi
echo 1>&2 "\
WARNING: \`$1' is $msg. You should only need it if
you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'.
You might want to install the \`Automake' and \`Perl' packages.
Grab them from any GNU archive site."
find . -type f -name Makefile.am -print |
sed 's/\.am$/.in/' |
while read f; do touch "$f"; done
;;
autom4te)
if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
# We have it, but it failed.
exit 1
fi
echo 1>&2 "\
WARNING: \`$1' is needed, but is $msg.
You might have modified some files without having the
proper tools for further handling them.
You can get \`$1' as part of \`Autoconf' from any GNU
archive site."
file=`echo "$*" | sed -n 's/.*--output[ =]*\([^ ]*\).*/\1/p'`
test -z "$file" && file=`echo "$*" | sed -n 's/.*-o[ ]*\([^ ]*\).*/\1/p'`
if test -f "$file"; then
touch $file
else
test -z "$file" || exec >$file
echo "#! /bin/sh"
echo "# Created by GNU Automake missing as a replacement of"
echo "# $ $@"
echo "exit 0"
chmod +x $file
exit 1
fi
;;
bison|yacc)
echo 1>&2 "\
WARNING: \`$1' $msg. You should only need it if
you modified a \`.y' file. You may need the \`Bison' package
in order for those modifications to take effect. You can get
\`Bison' from any GNU archive site."
rm -f y.tab.c y.tab.h
if [ $# -ne 1 ]; then
eval LASTARG="\${$#}"
case "$LASTARG" in
*.y)
SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'`
if [ -f "$SRCFILE" ]; then
cp "$SRCFILE" y.tab.c
fi
SRCFILE=`echo "$LASTARG" | sed 's/y$/h/'`
if [ -f "$SRCFILE" ]; then
cp "$SRCFILE" y.tab.h
fi
;;
esac
fi
if [ ! -f y.tab.h ]; then
echo >y.tab.h
fi
if [ ! -f y.tab.c ]; then
echo 'main() { return 0; }' >y.tab.c
fi
;;
lex|flex)
echo 1>&2 "\
WARNING: \`$1' is $msg. You should only need it if
you modified a \`.l' file. You may need the \`Flex' package
in order for those modifications to take effect. You can get
\`Flex' from any GNU archive site."
rm -f lex.yy.c
if [ $# -ne 1 ]; then
eval LASTARG="\${$#}"
case "$LASTARG" in
*.l)
SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'`
if [ -f "$SRCFILE" ]; then
cp "$SRCFILE" lex.yy.c
fi
;;
esac
fi
if [ ! -f lex.yy.c ]; then
echo 'main() { return 0; }' >lex.yy.c
fi
;;
help2man)
if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
# We have it, but it failed.
exit 1
fi
echo 1>&2 "\
WARNING: \`$1' is $msg. You should only need it if
you modified a dependency of a manual page. You may need the
\`Help2man' package in order for those modifications to take
effect. You can get \`Help2man' from any GNU archive site."
file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'`
if test -z "$file"; then
file=`echo "$*" | sed -n 's/.*--output=\([^ ]*\).*/\1/p'`
fi
if [ -f "$file" ]; then
touch $file
else
test -z "$file" || exec >$file
echo ".ab help2man is required to generate this page"
exit 1
fi
;;
makeinfo)
if test -z "$run" && (makeinfo --version) > /dev/null 2>&1; then
# We have makeinfo, but it failed.
exit 1
fi
echo 1>&2 "\
WARNING: \`$1' is $msg. You should only need it if
you modified a \`.texi' or \`.texinfo' file, or any other file
indirectly affecting the aspect of the manual. The spurious
call might also be the consequence of using a buggy \`make' (AIX,
DU, IRIX). You might want to install the \`Texinfo' package or
the \`GNU make' package. Grab either from any GNU archive site."
file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'`
if test -z "$file"; then
file=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'`
file=`sed -n '/^@setfilename/ { s/.* \([^ ]*\) *$/\1/; p; q; }' $file`
fi
touch $file
;;
tar)
shift
if test -n "$run"; then
echo 1>&2 "ERROR: \`tar' requires --run"
exit 1
fi
# We have already tried tar in the generic part.
# Look for gnutar/gtar before invocation to avoid ugly error
# messages.
if (gnutar --version > /dev/null 2>&1); then
gnutar "$@" && exit 0
fi
if (gtar --version > /dev/null 2>&1); then
gtar "$@" && exit 0
fi
firstarg="$1"
if shift; then
case "$firstarg" in
*o*)
firstarg=`echo "$firstarg" | sed s/o//`
tar "$firstarg" "$@" && exit 0
;;
esac
case "$firstarg" in
*h*)
firstarg=`echo "$firstarg" | sed s/h//`
tar "$firstarg" "$@" && exit 0
;;
esac
fi
echo 1>&2 "\
WARNING: I can't seem to be able to run \`tar' with the given arguments.
You may want to install GNU tar or Free paxutils, or check the
command line arguments."
exit 1
;;
*)
echo 1>&2 "\
WARNING: \`$1' is needed, and is $msg.
You might have modified some files without having the
proper tools for further handling them. Check the \`README' file,
it often tells you about the needed prerequisites for installing
this package. You may also peek at any GNU archive site, in case
some other package would contain this missing \`$1' program."
exit 1
;;
esac
exit 0
# Local variables:
# eval: (add-hook 'write-file-hooks 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-end: "$"
# End:

View File

159
qfits/config.h.in 100644
View File

@ -0,0 +1,159 @@
/* config.h.in. Generated from configure.ac by autoheader. */
/* x86 CPU type */
#undef CPU_X86
/* Define to 1 if you have the `atexit' function. */
#undef HAVE_ATEXIT
/* Define to 1 if you have the <dlfcn.h> header file. */
#undef HAVE_DLFCN_H
/* Define to 1 if you don't have `vprintf' but do have `_doprnt.' */
#undef HAVE_DOPRNT
/* Define to 1 if you have the <fcntl.h> header file. */
#undef HAVE_FCNTL_H
/* Define to 1 if you have the `getpagesize' function. */
#undef HAVE_GETPAGESIZE
/* Define to 1 if you have the `gettimeofday' function. */
#undef HAVE_GETTIMEOFDAY
/* Define to 1 if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
/* Define to 1 if you have the `m' library (-lm). */
#undef HAVE_LIBM
/* Define to 1 if your system has a GNU libc compatible `malloc' function, and
to 0 otherwise. */
#undef HAVE_MALLOC
/* Define to 1 if you have the `memchr' function. */
#undef HAVE_MEMCHR
/* Define to 1 if you have the `memmove' function. */
#undef HAVE_MEMMOVE
/* Define to 1 if you have the <memory.h> header file. */
#undef HAVE_MEMORY_H
/* Define to 1 if you have the `memset' function. */
#undef HAVE_MEMSET
/* Define to 1 if you have the `mkdir' function. */
#undef HAVE_MKDIR
/* Define to 1 if you have a working `mmap' system call. */
#undef HAVE_MMAP
/* Define to 1 if you have the `munmap' function. */
#undef HAVE_MUNMAP
/* Define to 1 if your system has a GNU libc compatible `realloc' function,
and to 0 otherwise. */
#undef HAVE_REALLOC
/* Define to 1 if you have the `regcomp' function. */
#undef HAVE_REGCOMP
/* Define to 1 if you have the `rmdir' function. */
#undef HAVE_RMDIR
/* Define to 1 if `stat' has the bug that it succeeds when given the
zero-length file name argument. */
#undef HAVE_STAT_EMPTY_STRING_BUG
/* Define to 1 if you have the <stdint.h> header file. */
#undef HAVE_STDINT_H
/* Define to 1 if you have the <stdlib.h> header file. */
#undef HAVE_STDLIB_H
/* Define to 1 if you have the `strchr' function. */
#undef HAVE_STRCHR
/* Define to 1 if you have the `strdup' function. */
#undef HAVE_STRDUP
/* Define to 1 if you have the <strings.h> header file. */
#undef HAVE_STRINGS_H
/* Define to 1 if you have the <string.h> header file. */
#undef HAVE_STRING_H
/* Define to 1 if you have the `strrchr' function. */
#undef HAVE_STRRCHR
/* Define to 1 if you have the `strstr' function. */
#undef HAVE_STRSTR
/* Define to 1 if you have the <sys/stat.h> header file. */
#undef HAVE_SYS_STAT_H
/* Define to 1 if you have the <sys/time.h> header file. */
#undef HAVE_SYS_TIME_H
/* Define to 1 if you have the <sys/types.h> header file. */
#undef HAVE_SYS_TYPES_H
/* Define to 1 if you have the `uname' function. */
#undef HAVE_UNAME
/* Define to 1 if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
/* Define to 1 if you have the `vprintf' function. */
#undef HAVE_VPRINTF
/* Define to 1 if `lstat' dereferences a symlink specified with a trailing
slash. */
#undef LSTAT_FOLLOWS_SLASHED_SYMLINK
/* Name of package */
#undef PACKAGE
/* Define to the address where bug reports for this package should be sent. */
#undef PACKAGE_BUGREPORT
/* Define to the full name of this package. */
#undef PACKAGE_NAME
/* Define to the full name and version of this package. */
#undef PACKAGE_STRING
/* Define to the one symbol short name of this package. */
#undef PACKAGE_TARNAME
/* Define to the version of this package. */
#undef PACKAGE_VERSION
/* Define to 1 if you have the ANSI C header files. */
#undef STDC_HEADERS
/* Define to 1 if you can safely include both <sys/time.h> and <time.h>. */
#undef TIME_WITH_SYS_TIME
/* Define to 1 if your <sys/time.h> declares `struct tm'. */
#undef TM_IN_SYS_TIME
/* Version number of package */
#undef VERSION
/* Define to 1 if your processor stores words with the most significant byte
first (like Motorola and SPARC, unlike Intel and VAX). */
#undef WORDS_BIGENDIAN
/* Define to empty if `const' does not conform to ANSI C. */
#undef const
/* Define to rpl_malloc if the replacement function should be used. */
#undef malloc
/* Define to rpl_realloc if the replacement function should be used. */
#undef realloc
/* Define to `unsigned' if <sys/types.h> does not define. */
#undef size_t

23031
qfits/configure vendored

File diff suppressed because it is too large Load Diff

81
qfits/configure.ac 100644
View File

@ -0,0 +1,81 @@
# -*- Autoconf -*-
# Process this file with autoconf to produce a configure script.
AC_PREREQ(2.59)
AC_INIT(qfits, 6.2.0, yjung@eso.org)
AC_CONFIG_SRCDIR([Makefile.am])
AC_CONFIG_HEADER([config.h])
AC_CONFIG_AUX_DIR([admin])
AM_INIT_AUTOMAKE
# Checks for programs.
AC_PROG_CC
# AC_PROG_RANLIB for static libraries without Libtool
# AC_PROG_RANLIB
# AC_PROG_LIBTOOL for static and shared libraries with Libtool
AC_PROG_LIBTOOL
AC_ENABLE_STATIC([yes])
AC_ENABLE_SHARED([yes])
AC_SUBST(LIBTOOL_DEPS)
# Doxygen and LAtex
ESO_CHECK_DOCTOOLS
# Libtool versioning. First release 0.0.0
LT_CURRENT=0
LT_REVISION=0
LT_AGE=0
AC_SUBST([LT_CURRENT])
AC_SUBST([LT_REVISION])
AC_SUBST([LT_AGE])
# Checks for libraries.
# FIXME: Replace `main' with a function in `-lm':
AC_CHECK_LIB([m], [main])
# FIXME: Replace `main' with a function in `-lqfits':
# In comments next line created by autscan, we do not want to
# check qfits lib, we want to create it.
#AC_CHECK_LIB([qfits], [main])
# Defined in the m4macros/qfits_memory.m4
QFITS_CHECK_MEMORY
# Checks for header files.
AC_HEADER_STDC
AC_CHECK_HEADERS([fcntl.h stdlib.h string.h sys/time.h unistd.h])
# Checks for typedefs, structures, and compiler characteristics.
AC_C_CONST
AC_TYPE_SIZE_T
AC_HEADER_TIME
AC_STRUCT_TM
# Checks for library functions.
AC_FUNC_MALLOC
AC_FUNC_MMAP
AC_FUNC_REALLOC
AC_FUNC_STAT
AC_FUNC_VPRINTF
AC_CHECK_FUNCS([atexit getpagesize gettimeofday memchr memmove memset mkdir munmap regcomp rmdir strchr strdup strrchr strstr uname])
# CG. Check for the BIG_ENDIAN (needed by qfits sources)
AC_C_BIGENDIAN
case $host_cpu in
i*86)
CPU_X86="`echo $host_cpu | cut -c 2-`"
AC_DEFINE_UNQUOTED([CPU_X86], $CPU_X86, [x86 CPU type])
;;
esac
AC_CONFIG_FILES([Makefile
doc/Doxyfile
src/Makefile
main/Makefile
saft/Makefile
man/Makefile
test/Makefile])
AC_OUTPUT

View File

@ -0,0 +1,126 @@
#---------------------------------------------------------------------------
# General configuration options
#---------------------------------------------------------------------------
PROJECT_NAME = "QFITS Reference Manual"
PROJECT_NUMBER = @VERSION@
OUTPUT_DIRECTORY = ..
OUTPUT_LANGUAGE = English
EXTRACT_ALL = YES
EXTRACT_PRIVATE = NO
EXTRACT_STATIC = NO
HIDE_UNDOC_MEMBERS = NO
BRIEF_MEMBER_DESC = YES
REPEAT_BRIEF = YES
ALWAYS_DETAILED_SEC = NO
FULL_PATH_NAMES = NO
STRIP_FROM_PATH =
INTERNAL_DOCS = NO
SOURCE_BROWSER = NO
INLINE_SOURCES = NO
STRIP_CODE_COMMENTS = YES
CASE_SENSE_NAMES = YES
HIDE_SCOPE_NAMES = NO
VERBATIM_HEADERS = NO
SHOW_INCLUDE_FILES = NO
JAVADOC_AUTOBRIEF = NO
INHERIT_DOCS = YES
INLINE_INFO = YES
SORT_MEMBER_DOCS = YES
DISTRIBUTE_GROUP_DOC = NO
TAB_SIZE = 4
ENABLED_SECTIONS =
GENERATE_TODOLIST = NO
GENERATE_TESTLIST = NO
ALIASES =
MAX_INITIALIZER_LINES = 30
OPTIMIZE_OUTPUT_FOR_C = YES
#---------------------------------------------------------------------------
# configuration options related to warning and progress messages
#---------------------------------------------------------------------------
QUIET = NO
WARNINGS = YES
WARN_IF_UNDOCUMENTED = YES
WARN_FORMAT = "$file:$line: $text"
WARN_LOGFILE =
#---------------------------------------------------------------------------
# configuration options related to the input files
#---------------------------------------------------------------------------
INPUT = qfits.head \
../src/qfits_cache.c \
../src/qfits_filename.c \
../src/qfits_header.c \
../src/qfits_image.c \
../src/qfits_md5.c \
../src/qfits_rw.c \
../src/qfits_table.c \
../src/qfits_time.c \
../src/qfits_tools.c \
../src/qfits_memory.c
FILE_PATTERNS =
RECURSIVE = NO
EXCLUDE =
EXCLUDE_PATTERNS =
EXAMPLE_PATH =
EXAMPLE_PATTERNS =
IMAGE_PATH =
INPUT_FILTER =
FILTER_SOURCE_FILES = NO
#---------------------------------------------------------------------------
# configuration options related to the alphabetical class index
#---------------------------------------------------------------------------
ALPHABETICAL_INDEX = YES
COLS_IN_ALPHA_INDEX = 5
IGNORE_PREFIX =
#---------------------------------------------------------------------------
# configuration options related to the HTML output
#---------------------------------------------------------------------------
GENERATE_HTML = YES
HTML_OUTPUT = html
HTML_HEADER = header.html
HTML_FOOTER = footer.html
HTML_STYLESHEET =
HTML_ALIGN_MEMBERS = YES
GENERATE_HTMLHELP = NO
DISABLE_INDEX = YES
ENUM_VALUES_PER_LINE = 4
GENERATE_TREEVIEW = NO
TREEVIEW_WIDTH = 250
#---------------------------------------------------------------------------
# configuration options related to the LaTeX output
#---------------------------------------------------------------------------
GENERATE_LATEX = YES
LATEX_HEADER = qfitstop.tex
#---------------------------------------------------------------------------
# configuration options related to the RTF output
#---------------------------------------------------------------------------
GENERATE_RTF = NO
#---------------------------------------------------------------------------
# configuration options related to the man page output
#---------------------------------------------------------------------------
GENERATE_MAN = NO
#---------------------------------------------------------------------------
# Configuration options related to the preprocessor
#---------------------------------------------------------------------------
ENABLE_PREPROCESSING = NO
MACRO_EXPANSION = NO
EXPAND_ONLY_PREDEF = NO
SEARCH_INCLUDES = NO
INCLUDE_PATH =
INCLUDE_FILE_PATTERNS =
PREDEFINED =
EXPAND_AS_DEFINED =
#---------------------------------------------------------------------------
# Configuration::addtions related to external references
#---------------------------------------------------------------------------
TAGFILES =
GENERATE_TAGFILE =
ALLEXTERNALS = NO
PERL_PATH = /usr/bin/perl
#---------------------------------------------------------------------------
# Configuration options related to the dot tool
#---------------------------------------------------------------------------
HAVE_DOT = NO
#---------------------------------------------------------------------------
# Configuration::addtions related to the search engine
#---------------------------------------------------------------------------
SEARCHENGINE = NO

View File

@ -1,14 +0,0 @@
all: html
html:
doxygen qfits.dox
rm -f ../html/annotated.html
rm -f ../html/classes.html
rm -f ../html/doxygen.gif
rm -f ../html/files.html
rm -f ../html/functions.html
rm -f ../html/globals.html
rm -f ../html/qfits_8head.html

View File

@ -1,74 +0,0 @@
%
% --------------------------------------------------------------
% File : qfits.tex
% Subject : qfits design document
% Author : N. Devillard
% --------------------------------------------------------------
%
\documentstyle[epsfig,html,rotating]{report}
\newcommand{\qfits}{{\bf qfits}}
\bodytext{TEXT="#000000" BGCOLOR="#FFFFFF"}
\begin{document}
%
% Title
% --------------------------------------------------------------
%
\title{qfits: an ANSI C library to handle FITS files}
\author{N. Devillard}
\date{\today}
\maketitle
\newpage
%
% Change record
% --------------------------------------------------------------
%
\begin{center}
{\bf Change Record}
\vskip 0.5 cm
\begin{tabular}{|c|c|p{3.0cm}|p{6.5cm}|} \hline
Issue/Rev. & Date & Section affected &
Reason and Remarks \\ \hline
1.0 & TODAY & All & Initial release \\
\hline
\end{tabular}
\end{center}
\normalsize
%
% Table of contents
% --------------------------------------------------------------
%
\newpage
\tableofcontents
%
% Text beginning
% --------------------------------------------------------------
\newpage
\pagenumbering{arabic}
\setcounter{page}{1}
% --------------------------------------------------------------
% Introduction
\input qfitsintro.tex
% FITS header handling
\input qfitshead.tex
% Pixel loading - memory handling
\input qfitspix.tex
% Table handling
\input qfitstab.tex
\end{document}

View File

@ -1,79 +0,0 @@
\chapter{Introduction}
\section{Overview}
\subsection{History}
The \qfits library has been developped in 1999 to cover various needs
arising in the pipeline group to handle FITS file from the C level. It
started very modest (3-4 functions) and hopes to remain small and simple
enough to be easily maintainable and usable, although as time goes by the
number of services offered by the library is constantly growing.
The very notion of "programming only what is immediately useful" for a
given project conveys the fact that all the code in this library has been
thoroughly tested under very different circumstances. No function has been
added in the hope that it might be useful. If a function is there, it has
been needed to solve a problem at some point and was proved to correctly
solve it. Additionally, a number of regression tests are delivered together
with the library to ensure that future modifications do not break existing
code.
This leads to very robust code that has been proven in a number of
situations. It is certainly not bug-less but offers a reasonable level of
trust to programmers using it.
\subsection{Features}
This library enables you to probe FITS files to retrieve any kind of
relevant information from them: headers can be loaded, parsed, queried,
modified, saved, whether they are the main header or extension headers,
pixel data can be located and loaded efficiently. A particular emphasis has
been put on the optimization of the code to yield the highest speed
(\qfits stands for "quick FITS"). Important pointers about a file are
cached in memory, file browsing is restricted to the minimum, and pixel
loading makes use of memory-mapping to make the best use out of your hard
disk cache.
The main features of \qfits are:
\begin{itemize}
\item Portability: \qfits runs virtually on any kind of POSIX-compliant
machine. This includes Linux, HPUX, Solaris, BSD, AIX, OSF/1 (Tru64), and
Darwin (i.e. Mac OS X, a BSD derivative).
\item Speed: \qfits offers several mechanisms to speed up data access.
\item Memory handling: \qfits comes bundled with an extended memory
allocator that allows you to handle data sizes beyond the hardware limits
of your machine.
\end{itemize}
\qfits should be enough to handle all you need about FITS files:
whether you need to handle header data or shuffle pixels around.
\section{The FITS format}
The FITS format is defined in the following document:
{\tt FITS standard - NOST 100 - 2.0}
This document is available from
{\tt http://fits.gsfc.nasa.gov}
This format is the preferred data format for all fields related to
astronomy. While this format is certainly not the most efficient in terms
of storage or programmers' convenience, it offers the enormous advantage of
being present everywhere in the astronomical field. It is sufficient to
contain even very complex data structures and until now, has covered all
the needs from radio astronomy to visible and infrared imaging or
spectroscopic instruments.
Basically, the FITS format could be summarized as: data are stored
uncompressed in contiguous form, and ancillary data are provided in ASCII
headers contained in the file. When talking about ancillay data in this
document, we will refer to FITS headers (since this is where they are
stored). Data are stored in "data sections" or "data segments".
\subsection{Services}
A formal description of the services offered by the library.

View File

@ -1,16 +0,0 @@
\chapter{Tables handling}
\section{Reading a table}
\section{Writing a table}

View File

@ -1,3 +0,0 @@
</body>
</html>

View File

@ -1,11 +0,0 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>$projectname $projectnumber</title>
</head>
<body text="#000000" bgcolor="#ffffff">

View File

@ -1,85 +0,0 @@
PROJECT_NAME = qfits
PROJECT_NUMBER = 5.3.1
OUTPUT_DIRECTORY = ..
OUTPUT_LANGUAGE = English
EXTRACT_ALL = YES
EXTRACT_PRIVATE = NO
EXTRACT_STATIC = NO
HIDE_UNDOC_MEMBERS = NO
BRIEF_MEMBER_DESC = YES
REPEAT_BRIEF = YES
ALWAYS_DETAILED_SEC = NO
FULL_PATH_NAMES = NO
STRIP_FROM_PATH =
INTERNAL_DOCS = NO
SOURCE_BROWSER = NO
INLINE_SOURCES = NO
STRIP_CODE_COMMENTS = YES
CASE_SENSE_NAMES = YES
HIDE_SCOPE_NAMES = NO
VERBATIM_HEADERS = NO
SHOW_INCLUDE_FILES = NO
JAVADOC_AUTOBRIEF = NO
INHERIT_DOCS = YES
INLINE_INFO = YES
SORT_MEMBER_DOCS = YES
DISTRIBUTE_GROUP_DOC = NO
TAB_SIZE = 4
ENABLED_SECTIONS =
GENERATE_TODOLIST = NO
GENERATE_TESTLIST = NO
ALIASES =
MAX_INITIALIZER_LINES = 30
OPTIMIZE_OUTPUT_FOR_C = YES
QUIET = NO
WARNINGS = YES
WARN_IF_UNDOCUMENTED = YES
WARN_FORMAT = "$file:$line: $text"
WARN_LOGFILE =
INPUT = qfits.head ../include/qfits.h
FILE_PATTERNS =
RECURSIVE = NO
EXCLUDE = CVS ../src/md5.h ../src/config.h
EXCLUDE_PATTERNS =
EXAMPLE_PATH =
EXAMPLE_PATTERNS =
IMAGE_PATH =
INPUT_FILTER =
FILTER_SOURCE_FILES = NO
ALPHABETICAL_INDEX = YES
COLS_IN_ALPHA_INDEX = 5
IGNORE_PREFIX =
GENERATE_HTML = YES
HTML_OUTPUT = html
HTML_HEADER = header.html
HTML_FOOTER = footer.html
HTML_STYLESHEET =
HTML_ALIGN_MEMBERS = YES
GENERATE_HTMLHELP = NO
DISABLE_INDEX = YES
ENUM_VALUES_PER_LINE = 4
GENERATE_TREEVIEW = NO
TREEVIEW_WIDTH = 250
# Latex options
GENERATE_LATEX = YES
LATEX_HEADER = qfitstop.tex
GENERATE_RTF = NO
GENERATE_MAN = NO
ENABLE_PREPROCESSING = NO
MACRO_EXPANSION = NO
EXPAND_ONLY_PREDEF = NO
SEARCH_INCLUDES = NO
INCLUDE_PATH =
INCLUDE_FILE_PATTERNS =
PREDEFINED =
EXPAND_AS_DEFINED =
TAGFILES =
GENERATE_TAGFILE =
ALLEXTERNALS = NO
PERL_PATH = /usr/bin/perl
HAVE_DOT = NO
SEARCHENGINE = NO

View File

@ -1,748 +0,0 @@
/**
@mainpage qfits Reference manual
<hr size="4">
@section welcome Introduction
@b qfits is a stand-alone library written in C to interact
with files complying with the FITS format. It is fast and
portable over any kind of POSIX-compliant platform.
Rather than going through the FITS format specification and
trying to implement some support for everything that is
described there, this library was built day after day upon
request. This guarantees that all the functions you will find
in the library have been written for some purpose in the VLT
pipeline context, and all of them are used daily in a
production environment.
Functionalities offered by this library are:
- Header queries (get keywords, values).
- Header manipulation (load/modify/save).
- Header/data offset queries.
- Pixel loading/saving to memory.
- Support for files of any dimension (NAXIS).
- Support for FITS extensions, including ASCII and binary
tables.
This library also comes with a limited set of interfaces to
Python to make some of its functionalities usable from this
language. See the compilation instructions to build it as a
Python module. The Qfits.py module contains its own doc.
<hr size="4">
@section history History
@b qfits was born from the need to have a simple but powerful
C library to handle FITS file access. There are already
many libraries on the Net to handle FITS files, but they tend
to be bloated with far too many features and may raise
portability and maintenance issues.
@b qfits was written to take care of all low-level aspects of
the FITS format, and only these. You will find there a wealth
of optimized functions to access everything inside FITS
files, but nothing about what you could do with the data:
this is left to other (e.g. image processing) libraries.
There is no suggested image or cube type, and the table
object only loads the data without trying to interpret them.
The idea is that people wanting to work with FITS might have
different requirements: somebody writing an image viewer
might just want to load a pixel buffer, somebody handling
headers only might want to have easy access to header
information without touching pixel data. @b qfits allows you
to get your hands on what is contained in a FITS file but
does not force you to use any specific high-level data type
to describe your data.
<hr size="4">
@section authors Authors
Nicolas Devillard and Yves Jung, ESO.
<hr size="4">
@section header Header handling
This section gives you an overview of the functionalities
offered to work on FITS headers with @b qfits. For a complete
reference, check out the reference manual: qfits.h.
FITS headers are simply formatted as 80-char lines (@e cards)
containing ancillary data represented in ASCII format like:
keyword = value / comment
If you want to retrieve data from a FITS file header,
you will find various useful query routines to get a
keyword value from main or extension headers. Values are
returned as strings and not coerced to any particular (e.g.
numerical) type. See e.g.
- qfits_query_hdr() to query the main header.
- qfits_query_ext() to query an extension header.
- qfits_query_n_ext() to get the number of extensions.
You may also want to handle file inputs by yourself and have
FITS cards split into their components key/value/comment. See
e.g.
- qfits_getkey() to extract the key from a FITS line.
- qfits_getvalue() to extract the value.
- qfits_getcomment() to extract the comment.
Since all FITS values are returned as strings, you may
need to identify types. See e.g.
- qfits_get_type() to identify a value type
- qfits_is_boolean()
- qfits_is_int()
- qfits_is_float()
- qfits_is_complex()
- qfits_is_string()
Of course, you can use the usual @c atof(), @c atoi() and
@c scanf() functions to convert a string to a numerical type.
You may also want to perform more complex operations on FITS
headers, like loading one, modifying it and saving it back to
a new file. The qfits_header data structure is offered for
that purpose. It comes with utilities like:
- qfits_header_read() to load a header.
- qfits_header_readext() same from an extension.
- qfits_header_dump() to save a header to a file.
- ...
And of course all manipulation tools you can think of:
- qfits_header_add()
- qfits_header_add_after()
- qfits_header_append()
- qfits_header_mod()
- qfits_header_del()
- ...
There are other functions to create new FITS cards, dump a
header to screen for debugging purposes, etc. See the
reference manual (qfits.h) for an exhaustive description.
An important feature of the qfits_header object when loaded
from a file, is that it keeps the memory of the initial
FITS card. The data structure that is carried around for each
FITS card contains:
- Identified keyword
- Identified value
- Possible comment
- Line as read from initial file when applicable.
This feature is fairly useful if you want to perform
header manipulation without getting too intrusive. You can
use this to load a header, modify a couple of cards and dump
all back to disk. The dumped header will only be modified for
the cards you have touched, all others will be forwarded
verbatim as they appeared in the initial file. This
least-modification policy ensures that you will not modify
the lines you do not need to touch.
This feature can be turned off by "touching" all lines in a
header using qfits_header_touchall(), which removes all
initial line information from a qfits_header object. This
is useful to force a reformatting of a FITS header e.g. when
the file header is damaged.
Notice that ESO's @c HIERARCH keywords and DICB ordering are
natively supported by @b qfits, i.e. when you work with
qfits_header objects you can be sure that they will properly
recognize and sort keywords following ESO conventions.
<hr size="4">
@section data Data handling
This section gives you an overview of the functionalities
offered to work on FITS data segments with @b qfits. For a
complete reference, check out the reference manual (qfits.h).
Data segments are quite simply stored: they always contain
data contiguously in uncompressed format, so reading them is
mostly a matter of applying an @c fread() statement at the
right place in the file, with the right size. To find out
about offsets to data and header parts in a FITS file
(possibly containing several extensions), you can make use
of:
- qfits_get_hdrinfo() to return information about a header
position and size (in bytes) in a file.
- qfits_get_datinfo() to return information about a data
segment position and size (in bytes) in a file.
@b qfits includes a caching mechanism to speed up accesses
to large files to an optimal access time (only one parsing of
the file is needed, even with multiple queries on the same
file). This mechanism is internal to this module and
invisible to the programmer using @b qfits. This means that
you can loop on all sections on a huge file to retrieve file
offsets for each extension, and pay the price of file parsing
only at the first call.
If you want to dive further into data loading, you may want
to have a look at table and image handling functionalities.
@subsection table Table handling
A table is stored in a FITS file in an extension. The
extension header contains all needed informations to read the
data (number of columns, the column types, the columns
labels, the columns unit, etc...).
A FITS table is composed by columns. Within one column there
can only be data of one defined type, but you can store
several values by field.
In BINARY tables, you can find 11 different data types, in
ASCII tables, there are 5 different types. All these types
are supported by @b qfits:
- ASCII tables:
- TFITS_ASCII_TYPE_A : Characters (1 byte)
- TFITS_ASCII_TYPE_D : Double (8 bytes)
- TFITS_ASCII_TYPE_E : Float (4 bytes)
- TFITS_ASCII_TYPE_F : Float (4 bytes)
- TFITS_ASCII_TYPE_I : Integer (4 bytes)
- BIN tables:
- TFITS_BIN_TYPE_A : Characters (1 byte)
- TFITS_BIN_TYPE_B : Unsigned byte (1 byte)
- TFITS_BIN_TYPE_C : Float complex (2 * 4 bytes)
- TFITS_BIN_TYPE_D : Double (8 bytes)
- TFITS_BIN_TYPE_E : Float (4 bytes)
- TFITS_BIN_TYPE_I : Short (2 bytes)
- TFITS_BIN_TYPE_J : Integer (4 bytes)
- TFITS_BIN_TYPE_L : Logical (1 byte)
- TFITS_BIN_TYPE_M : Double complex (2 * 8 bytes)
- TFITS_BIN_TYPE_P : Array descriptor (2 * 4 bytes)
- TFITS_BIN_TYPE_X : Bit (1 bit)
The qfits_table object provided by @b qfits contains all
necessary informations to define how the data are stored in
the file: the name of the file it comes from, the table type
(QFITS_BINTABLE or QFITS_ASCIITABLE), the number of columns
and for each column a pointer to a qfits_col object.
Each qfits_col object contains informations defining the
associated column: the type (e.g. TFITS_BIN_TYPE_L), the
number of rows, the number of atoms per field, the label, the
unit, etc...).
This qfits_table object is returned by qfits_table_open() and
should only be destroyed with qfits_table_close().
This qfits_table object does not contain the table data, but
has to be used to load the data with functions like:
- qfits_query_column()
- qfits_query_column_data()
- qfits_query_column_nulls()
qfits_query_column() returns you simply the data (byte
swapped if necessary) as they were read in the file as a byte
array. It is up to the user to interpret the data (e.g. to
try to find out where the NULL values are).
qfits_query_column_data() does the same, but identifies the
NULL values and replaces them by a user-provided value. In
this case, the returned array is an array of data of the
right type. It is returned as a void*, the user just has to
cast it to a double*, a short* or what is needed.
For example, if you require in a table that contains 15 rows
a column where you can find 3 values of type TFITS_BIN_TYPE_M
(double complex), qfits_query_column_data() will return an
array of 15 * 3 * 2 double values.
@b qfits also provides functions to write a table to a FITS
file (qfits_save_table_hdrdump()), or to print out a table
value or a complete table on the screen or in a file
(qfits_table_field_to_string()).
@subsection image Image handling
The qfitsloader and qfitsdumper objects are offered to
simplify the action of reading/writing image data. The
corresponding operators take care of retrieving all necessary
ancillary information (image size, pixel type, buffer
position), perform a memory allocation or mapping and read
the file into memory. See the following functions:
- qfitsloader_init() to initialize a loader object.
- qfits_loadpix() to load pixel data into memory.
- qfits_pixdump() to save pixel data to disk.
As for tables, the idea is that you first launch an analysis
of the file to get back a number of informations about what
is present there. In the case of images, you use
qfitsloader_init() to see if pixel loading could be done,
then use qfits_loadpix() to perform the actual load.
Pixel I/O are taking place in float, int or double format.
See the corresponding functions:
- qfits_pixin_float()
- qfits_pixin_int()
- qfits_pixin_double()
- qfits_pixdump_float()
- qfits_pixdump_int()
- qfits_pixdump_double()
Loading pixels as floats means that whichever pixel format
(BITPIX) is used in your input FITS file, all pixels will be
converted to your local representation of float upon loading.
The 3 offered types basically allow you to work with 3 kinds
of pixels internally, choose the one that best suits your
needs. 'int' is not recommended for loss of precision, and
'double' for memory and performance issues.
Saving pixels can be done with any BITPIX setting. There are
3 pixel dumpers as there are 3 pixel loaders, because there
are 3 possible types for pixel buffers in memory (int, float,
double). All pixels are converted on the fly to the requested
BITPIX setting.
Notice that as soon as you start using pixel loading
functions, you must comply with the @b qfits memory model.
This basically means that you should not only include
@c qfits.h in your program, but also @c xmemory.h to get the
proper definitions for memory allocation functions.
@section utils Other utilities
Some additional functions are offered in @b qfits, they are
useful in the VLT context. See:
- date_now()
- time_now()
- get_date_iso8601()
- get_datetime_iso8601()
<hr size="4">
@section features Features
This section describes various unique features of @b qfits.
@subsection portability Portability
This library has been ported and tested on the following
platforms:
- Linux x86 and alpha
- Solaris 2.5, 2.6 and 2.8
- HPUX 8, 9, 10, 11
- AIX
- BSD compatible, including Darwin (Mac OS X)
- OSF/1 or Tru64
Since @b qfits depends on POSIX system routines, there is
little chance it could compile natively on Windows, except
with the help from GNU porting tools from Cygnus. This has
never been attempted so far.
@subsection speed Speed
The offered routines make use of caching mechanisms and
memory-mapping system calls to enhance FITS file parsing and
speed up the code.
@subsection interfaces Interfaces to C++/Python
You should be able to compile this library with a C++
compiler, the header files include the usual blurb to allow
that without warning from the compiler. You might have
problems due to pointer casts and other various
incompatibilities due to the variety of C++ dialects and
compilers, though. If you really need to hook this library
into C++ code, your best bet is probably to compile the
library as a standard C library and link your C++ code
against it.
A limited set of interfaces to Python is offered.
See the INSTALL file in the main distribution directory for
instructions about installing this library as a Python
module.
@subsection precision Numerical precision
Since FITS headers are stored as strings, numerical precision
is limited by the number of digits used to write a number in
a FITS card, which is in theory larger than what a 32-bit
floating-point can store. Using @b qfits, these values are
available to a C programmer as a string, making sure that
precision has at least not be lost in the reading process.
@subsection conservative Conservative headers
As mentioned above, if you only need to load a header, modify
a card and save it back, you will find out that @e only the
card you touched has been modified, the rest was verbatim
transferred. This is useful to ensure that the library
formatting does not disturb your format.
@subsection hierarch Native HIERARCH support
Native support for ESO's @c HIERARCH keywords, as well as keywords
of any length (up to 80 chars per line).
@subsection dicb ESO/DICB keyword ordering
Native support for DICB (ESO only) ordering of keywords in
the headers. FITS files created with this library will be
DICB compliant with respect to keyword ordering.
@subsection xmemory Memory model
@b qfits does not only offer pixel loading mechanisms, it also
comes bundled with a memory module based on a model optimized
for the handling of very large data segments. In practice,
it means that as soon as you have included @c xmemory.h, your
calls to malloc/calloc/free are re-directed to specific versions
which put your program on steroids. Calls to memory allocators
will yield valid data pointers past the hardware limits of your
machine, up to 2 or 4 Gb on a 32-bit workstation and insanely
high values on 64-bit processors.
This memory module is also distributed as a stand-alone module
which can be downloaded and used without @b qfits. It is mandatory
to use this module when using @b qfits pixel loaders, to get
the advantages of large memory handling.
If you are only interested in header manipulation, you do not
need to include @c xmemory.h.
<hr size="4">
@section install Installation instructions
In the main @b qfits directory, type:
@verbatim
./configure ; make
@endverbatim
To use the library in your programs, add the following line on top
of your module:
@code
#include "qfits.h"
@endcode
And link your program with the @b qfits library by adding
@c -lqfits to the compile line.
If you ever need to make calls to one of the @b qfits pixel
loaders, you need to include the memory model definitions
also with:
@code
#include "xmemory.h"
@endcode
Including this file is needed so that you can safely
@c free() the pointer returned by a pixel loader. See the
documentation about pixel loaders for more information.
To compile @b qfits as a Python module, you need to have
Python installed on your machine and available in your PATH.
Type:
@verbatim
% python setup.py install
@endverbatim
This should build the module and install it in your default library
path. This makes use of the distutils package, standardized since
Python 2.0. This means that you need Python 2.0 at least to
compile and run this module. If you are running Python 1.5 or
1.6, you may want to install the @c distutils package on your
platform, which will handle the @b qfits module installation.
<hr size="4">
@section python Python module documentation
The following documentation has been directly extracted
from the qfits Python module (Qfits.py) by running:
@verbatim
% pydoc Qfits.py
@endverbatim
Once Qfits.py is installed in your Python distribution,
you should also be able to browse this documentation using
@c pydoc.
@verbatim
Python Library Documentation: module Qfits
NAME
Qfits - Qfits.py: a module to read header information from a FITS file.
FILE
Qfits.py
DESCRIPTION
This module offers a function to read all headers in a given
FITS file and return them as a list of strings.
CLASSES
fitsinfo
class fitsinfo
| The fitsinfo class encapsulates queries into a FITS header.
|
| Initialize an instance by giving the name of a file, the following
| fields are then filled in:
|
| - filename - Name of the file
| - n_ext - Number of FITS extensions in file
| - hdrs - List of headers
| - xtnum - Current extension number for get()
|
| The following methods are offered:
|
| * get()
| This method retrieves keyword information in a given instance.
| Provide one or more keywords to look for and this function will
| browse the hdrs list for matching keywords. This method returns a
| string if you requested only 1 keyword or a list of strings if you
| requested several keywords. A failed match returns None.
|
| This method will only search for keywords in the xtnum extension.
|
| get() supports the shortFITS notation, in which A.B.C is transformed
| into HIERARCH ESO A B C before lookup in the FITS header. Notice that
| the given strings are also converted to uppercase before the search
| is launched. See the function expand_keyword() in this module.
|
| Returned string values are always pretty-formatted, i.e. something
| stored into a FITS string as 'o''hara' will be returned as o'hara.
|
| Examples:
|
| q = fitsinfo('vltframe.fits')
| q.get('simple') # returns 'T'
| q.get('simple', 'naxis') # returns ('T', '2')
|
| To search for keywords in the 3rd extension:
|
| q = fitsinfo('wfiframe.fits')
| q.xtnum = 3
| q.get('xtension') # returns 'IMAGE'
| q.get('det.chip3.id', 'bitpix')
| # returns ('ccd52', '16')
|
| * datamd5()
| This method computes the MD5 signature of all the data parts of the
| given FITS file and returns it as a 32-char string containing a
| hexadecimal number on 128 bits.
|
| Methods defined here:
|
| __init__(self, filename)
| Provide a filename to initialize the object.
|
| __repr__(self)
|
| datamd5(self)
|
| get(self, *keywords)
| Get a list of keyword values and return it as a list. If only one
| keyword is requested, the returned value is a single string (or
| None if the keyword was not found). If several keywords are passed,
| the returned value is a list of found values.
|
| The search is only performed in the current extension (xtnum field
| in the class).
|
| ----------------------------------------------------------------------
FUNCTIONS
datamd5(filename)
This function computes the MD5 signature of all data parts in a FITS
file and returns a 32-char string containing the signature as an
hexadecimal number (128 bits). It raises an IOError exception if the
given filename does not correspond to a valid FITS file.
expand_keyword(key)
This function is useful to expand a given keyword into
its FITS equivalent. What it does is simply bring the
word to uppercase, then expand shortFITS words to HIERARCH
ESO notation, like:
simple -> SIMPLE
NaXiS -> NAXIS
det.dit -> HIERARCH ESO DET DIT
get_headers(filename)
This function is the main operator in this module.
Given a file name, it returns all header informations
in a list of lists. The top list contains one element
per found header, i.e. if the given file has 8 extensions,
the top list contains 9 items (1 for the main header,
8 for the extension headers). Each list contains
in turn all informations about the corresponding
headers as a list of tuples like
(key, value, comment)
Example:
The given FITS file contains 1 main header and 2
extension headers given as follows:
--- main header
SIMPLE = T / FITS format
BITPIX = 8 / Bits per pixel
NAXIS = 0 / No data
...
END
--- extension 1
XTENSION = 'IMAGE' / Image extension
BITPIX = 16 / Bits per pixel
...
END
--- extension 2
XTENSION = 'IMAGE' / Image extension
BITPIX = -32 / Bits per pixel
...
END
The returned list contains three items.
The first one is a list corresponding to the
main header, then come the two extension
headers. The first list looks like:
[ ('SIMPLE','T','FITS format'),
('BITPIX', '8', 'Bits per pixel'),
('NAXIS', '0', 'No data'),
...
('END', '', '') ]
The extension lists look like this:
[ ('XTENSION', 'IMAGE', 'Image extension'),
('BITPIX', '16', 'Bits per pixel'),
...
('END', '', '') ]
[ ('XTENSION', 'IMAGE', 'Image extension'),
('BITPIX', '-32', 'Bits per pixel'),
...
('END', '', '') ]
In summary, if you want to get all FITS header informations
from a FITS file, call this function with:
hdr = qfits.get_headers(filename)
This function will raise an IOError exception if the provided
filename does not correspond to a valid file, and None if
the file is not FITS.
If the load succeeded, you can access individual keywords
with the following syntax:
hdr[extension][row][index]
Where:
extension runs from 0 to N_EXT (inclusive)
row is the row number of the card
index is 0 for the keyword, 1 for the value, 2 for the comment.
The number of FITS extensions found in the file is simply:
len(hdr)-1
version()
This function returns the version number of the
underlying qfits module.
@endverbatim
<hr size="4">
@section faq Frequently Asked Questions
@subsection faq1 Where should I start to use qfits?
Try to build the library on your system first. You should
then have a new library file called libqfits.a. To use the
library functionalities in your programs, you must add the
following include in your list of includes:
@verbatim
#include "qfits.h"
@endverbatim
And then compile your program adding the correct flags to
indicate where the @b qfits.h header file is, where the
libqfits.a file is, and that you want to link against
libqfits. Example: if the header file is in /usr/local/include and
the library in /usr/local/lib, you would use:
@verbatim
% cc -o myprog myprog.c -I/usr/local/include -L/usr/local/lib -lqfits
@endverbatim
If you need to use pixel loaders/dumpers, you also need to
include the @b qfits memory-handling module:
@verbatim
#include "xmemory.h"
@endverbatim
Now you are all set. Refer to this documentation for more
information about the offered data structures and associated
methods.
@subsection faq2 What should I know about the cache mechanism?
Parsing FITS files to find extensions is a lengthy process,
because the FITS format does not declare in the main header
where the following extensions are located in the file.
Any access to a FITS file with this library will cache a
number of offset pointers in the file to allow fast access to
extensions. This means that the file is parsed completely
only once, the first time it is accessed through any of the
@b qfits functions.
The cache is implemented (since version 4.2) as a rotating
buffer of modest size: 128 FITS file information structures
can be held simultaneously. If you do need to perform accesses
on a list of more than 128 files and want to use the caching
mechanism at its best, it is recommended to isolate all your
FITS requests to a given file in the same code area.
As a programmer, you do not need to initialize or shutdown the
cache, this is done automatically.
The rotating buffer is a global data structure private to the
cache module. The immediate side-effect is that the library
is thread-unsafe. If you are concerned about writing
multi-threaded applications, you should use a mutex upon
accessing this library. Making a thread-safe compliant
version of this library should not be too hard, but the need
has not been felt yet.
*/

View File

@ -1,248 +0,0 @@
\documentclass[a4paper,11pt,twoside]{report}
\usepackage{a4wide}
\usepackage{makeidx}
\usepackage{fancyhdr}
\usepackage{graphicx}
\usepackage{float}
\usepackage{alltt}
\usepackage{doxygen}
\usepackage{longtable}
\usepackage{verbatim}
\usepackage{epsf}
\makeindex
%
\raggedbottom
\topmargin=-.9cm
\topskip=-3.5cm
\textheight=24.5cm
\textwidth=14.8cm
\oddsidemargin=1cm
\evensidemargin=-0.1cm
\parindent=0mm
\topsep=0.5ex
\itemsep=0.5ex
\marginparwidth=1.5cm
\marginparsep=1.5mm
\def\docno{VLT-MAN-ESO-19500-2722}
\def\docver{4.2}
\def\docdate{\today}
\def\eg{{e.g.~}}
\def\ie{{i.e.~}}
\makeatletter
\def\@listi{\leftmargin\leftmargini
\parsep 1\p@ \@plus0\p@ \@minus0\p@
\topsep 2\p@ \@plus0\p@ \@minus0\p@
\itemsep 1\p@ \@plus0\p@ \@minus0\p@}
\let\@listI\@listi
\@listi
\def\@listii {\leftmargin\leftmarginii
\labelwidth\leftmarginii
\advance\labelwidth-\labelsep
\topsep 2\p@ \@plus0\p@ \@minus0\p@
\parsep 1\p@ \@plus0\p@ \@minus0\p@
\itemsep \parsep}
\def\@listiii{\leftmargin\leftmarginiii
\labelwidth\leftmarginiii
\advance\labelwidth-\labelsep
\topsep 2\p@ \@plus0\p@ \@minus0\p@
\parsep \z@
\partopsep \p@ \@plus0\z@ \@minus0\p@
\itemsep \topsep}
\makeatother
\setlongtables
\def\degr{\hbox{$^\circ$}}
\def\arcmin{\hbox{$^\prime$}}
\def\arcsec{\hbox{$^{\prime\prime}$}}
\newcounter{docref}
\newcommand{\docref}[3]{\refstepcounter{docref}\label{#1}
{\begin{tabular}{p{7mm}p{75mm}l}[\thedocref]& #3 &{\tt #2}\end{tabular}\\}}
\def\thebibliography#1{\section*{}\list
{[\arabic{enumi}]}{\settowidth\labelwidth{[#1]}\leftmargin\labelwidth
\advance\leftmargin\labelsep
\usecounter{enumi}}
\def\newblock{\hskip .11em plus .33em minus .07em}
\sloppy\clubpenalty4000\widowpenalty4000
\sfcode`\.=1000\relax}
\let\endthebibliography=\endlist
\begin{document}
\newcommand{\cm}[1]{\marginpar{\scriptsize #1}}
\pagenumbering{roman}
\pagestyle{empty}
\begin{center}
\bf
\Large
\hspace{-1.4cm} {EUROPEAN SOUTHERN OBSERVATORY}
\vspace{2.7cm}
\Huge
\hspace{-1.7cm} {VERY LARGE TELESCOPE}
\vspace{2.6cm}
\begin{picture}(10,1)(0,0)
\put(-165,0){\line(0,-1){6}}
\put(-165,0){\line(1,0){6}}
\put(126,0){\line(0,-1){6}}
\put(120,0){\line(1,0){6}}
\end{picture}
% **************************************************************************
% DOCUMENT IDENTIFICATION SECTION
%
% Document Title, Up to four lines. The first or the last should be the
% document type (e.g., Statement of Work, Functional Specification, etc.)
%
\large
\hspace{-1.7cm} {\bf qfits Library} % <<<<<<< subject
\hspace{-1.7cm} {\bf Reference Manual}
\normalsize
\vspace{0.5cm}
\hspace{-1.7cm} {Doc. No. \docno} % <<<<<<< Document number
\vspace{0.5cm}
\hspace{-1.7cm} {Issue \docver} % <<<<<<< Issue [/preparation]
\vspace{0.5cm}
\hspace{-1.7cm} {Date \docdate} % <<<<<<< Date
\vspace{0.5cm}
\begin{picture}(10,1)(0,0)
\put(-165,0){\line(0,1){6}}
\put(-165,0){\line(1,0){6}}
\put(126,0){\line(0,1){6}}
\put(120,0){\line(1,0){6}}
\end{picture}
\vspace{1.6cm}
%
% *************************************************************************
% SIGNATURE SECTION
%
% - AUTHOR
%
\normalsize
\hspace{-3.0cm}\makebox[5.5cm][l]{N.~Devillard, Y.~Jung}
\vspace{-0.3cm}
\large
\hspace{-0.7cm} {Prepared \makebox[10.5cm]{\dotfill}}
\footnotesize
\hspace{2.5cm}{Name} \hspace{4cm}{Date} \hspace{2cm}{Signature}
\vspace{1cm}
% - APPROVER
\normalsize
\hspace{-3.0cm}\makebox[5.5cm][l]{M.~Peron}
\vspace{-0.3cm}
\large
\hspace{-0.7cm} {Approved \makebox[10.5cm]{\dotfill}}
\footnotesize
\hspace{2.5cm}{Name} \hspace{4cm}{Date} \hspace{2cm}{Signature}
\vspace{1cm}
% - RELEASER
\normalsize
\hspace{-3.0cm}\makebox[5.5cm][l]{P.~Quinn}
\vspace{-0.3cm}
\large
\hspace{-0.7cm} {Released \makebox[10.5cm]{\dotfill}}
\footnotesize
\hspace{2.5cm}{Name} \hspace{4cm}{Date} \hspace{2cm}{Signature}
\end{center}
% **************************************************************************
% PAGE HEADING SECTION
%
\clearpage
\pagestyle{myheadings}
\markboth
% {} % <<<<<<< uncomment for single side document
{\underline{qfits Reference Manual - \docver \hspace*{2.5cm} \docno}}
{\underline{qfits Reference Manual - \docver \hspace*{2.5cm} \docno}}
% <<<<<<<< comment the following in the case of a single side document
\vspace*{8 cm}
\begin{center}
This page was intentionally left blank
\end{center}
\newpage
% **************************************************************************
% CHANGE RECORD SECTION
%
\normalsize
\begin{center}
{\bf Change Record}
\vskip 0.5 cm
\begin{tabular}{|c|c|p{3.0cm}|p{6.5cm}|} \hline
Issue/Rev. & Date & Section affected &
Reason and Remarks \\ \hline
4.1 & Mar 2002 & All & First version \\ \hline
4.2 & Apr 2002 & All & Updated cache information \\ \hline
\end{tabular}
\end{center}
\normalsize
% <<<<<<<< comment the following in the case of a single side document
\newpage
\vspace*{8 cm}
\begin{center}
This page was intentionally left blank
\end{center}
% ***************************************************************************
% BEGINNING OF TEXT
%
%------------------------------ Introduction -----------------------------
\newpage
\parskip=2mm
\pagenumbering{arabic}
\setcounter{page}{1}
\tableofcontents
\pagenumbering{arabic}
\setcounter{page}{1}
%-------------------------------------------------------------------
\chapter{qfits Description}
\input{index.tex}
\chapter{qfits Reference}
\input{structqfits__col.tex}
\input{structqfits__header.tex}
\input{structqfits__table.tex}
\input{structqfitsdumper.tex}
\input{structqfitsloader.tex}
\input{qfits_8h}
\printindex
\end{document}

View File

@ -1,33 +0,0 @@
#
# Makefile for qfits tutorial modules
#
include ../config.make
RM = rm -f
# Compile rules
SUFFIXES = .o .c .h .a .so .sl
COMPILE.c = @(echo "compiling $@..." ;\
$(CC) $(CFLAGS) $(FTRACE) -L../lib -I../include \
-o $@ $< -lqfits $(LFLAGS) -lm)
.c:
$(COMPILE.c)
default: all
PROGS = is_fits_file \
qfits_header \
qfits_header_manip \
qfits_pixio \
query_fits \
query_fits+ext \
qfits_table
all: $(PROGS)
clean veryclean:
$(RM) $(PROGS)

View File

@ -1,27 +0,0 @@
qfits examples
--------------
This directory contains various programs demonstrating qfits
capabilities. Here is a quick overview:
Header queries
--------------
* is_fits_file.c
Demonstrates how to use the is_fits_file() function.
* qfits_query.c
Demonstrates how to query values in the main FITS header with
just one function call and no need for qfits-specific data
types.
* qfits_query+ext.c
Same as qfits_query.c, but also allows to search extension
headers. Since it contains a call to qfits_query_n_ext, it is
noticeably slower to start on very large files with many
extensions.

View File

@ -1,19 +0,0 @@
/*
* qfits example: is_fits_file()
*/
#include <stdio.h>
#include "qfits.h"
int main(int argc, char * argv[])
{
int i ;
for (i=1 ; i<argc ; i++) {
if (is_fits_file(argv[i])) {
printf("FITS: %s\n", argv[i]);
}
}
return 0 ;
}

View File

@ -1,126 +0,0 @@
/*
* qfits example: querying FITS headers.
*
* In this example, a FITS header is loaded and examined
* using the qfits_header object.
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "qfits.h"
int main(int argc, char * argv[])
{
/*
* Declare a qfits_header object as a pointer.
*/
qfits_header * qh ;
/* The following are for header browsing only */
int i ;
char key[FITS_LINESZ+1] ;
char val[FITS_LINESZ+1] ;
char com[FITS_LINESZ+1] ;
char lin[FITS_LINESZ+1] ;
/* Check command-line arguments. */
if (argc<2) {
printf("use: %s <filename>\n", argv[0]);
return 1 ;
}
/* Check this is indeed a FITS file */
if (is_fits_file(argv[1])!=1) {
printf("%s is not a FITS file\n", argv[1]);
return -1 ;
}
/*
* Load FITS header into qfits_header object.
* This only reads the main header. To read an extension
* header, you could use:
*
* qh = qfits_header_readext(argv[1], xtnum);
* Notice that the following will also read the main header:
* qh = qfits_header_readext(argv[1], 0) ;
*
*/
qh = qfits_header_read(argv[1]);
if (qh==NULL) {
/*
* Something went wrong: bailout
*/
return -1 ;
}
/*
* The loaded header can be dumped to a file using
* qfits_header_dump(), like in:
* qfits_header_dump(qh, stdout);
*/
/* Display all keywords found in header, and their type */
for (i=0 ; i<qh->n ; i++) {
/*
* Get for each card:
* - The keyword name
* - The keyword value
* - Any associated comment
* - The whole initial line as a pointer to 80 chars.
*/
qfits_header_getitem(qh, i, key, val, com, lin);
/*
* Display key name and value for cards that are not
* HISTORY or COMMENT.
*/
if (strcmp(key, "HISTORY") && strcmp(key, "COMMENT")) {
printf("key(%s) value(%s) ", key, val);
/*
* Display the value type. See also the following functions:
* qfits_is_boolean()
* qfits_is_int()
* qfits_is_float()
* qfits_is_complex()
* qfits_is_string()
*/
switch (qfits_get_type(val)) {
case QFITS_BOOLEAN:
printf("type: boolean\n");
break ;
case QFITS_INT:
printf("type: int\n");
break ;
case QFITS_FLOAT:
printf("type: float\n");
break ;
case QFITS_COMPLEX:
printf("type: complex\n");
break ;
case QFITS_STRING:
printf("type: string\n");
break ;
default:
printf("type: unknown\n");
break ;
}
printf("comment(%s)\n", com);
}
}
/* Free header and quit */
qfits_header_destroy(qh);
return 0 ;
}

View File

@ -1,126 +0,0 @@
/*
* qfits example: Manipulating FITS headers.
*
* The following example shows how to create and manipulate a FITS header:
* adding/modifying/removing cards, and shows the header on console as it
* is modified.
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "qfits.h"
/* Dump header with horizontal ruler to make it easier to read */
#define HR "-----------------------------------------------------------\n"
static void hdump(qfits_header * qh)
{
printf(HR);
qfits_header_dump(qh, stdout);
printf(HR);
}
int main(void)
{
/* Declare a FITS header as a pointer */
qfits_header * qh ;
/* Create default FITS header and display it */
printf("Creating default header:\n");
qh = qfits_header_default();
hdump(qh);
/*
* Add some basic keywords and display each time
* Notice that keywords are automatically inserted where they are
* supposed to be placed in the header.
*/
printf("Adding keyword...\n");
qfits_header_add(qh, "NAXIS", "3", "3-dimensional", NULL);
hdump(qh);
printf("Adding keyword...\n");
qfits_header_add(qh, "NAXIS3", "30", "third dimension", NULL);
hdump(qh);
printf("Adding keyword...\n");
qfits_header_add(qh, "NAXIS2", "20", "second dimension", NULL);
hdump(qh);
printf("Adding keyword...\n");
qfits_header_add(qh, "NAXIS1", "10", "first dimension", NULL);
hdump(qh);
printf("Adding several keywords...\n");
/* Add different data types */
qfits_header_add(qh, "section.key1", "one", "string value", NULL);
qfits_header_add(qh, "section.key2", "2", "integer value", NULL);
qfits_header_add(qh, "section.key3", "3.0", "float value", NULL);
qfits_header_add(qh, "section.key4", "T", "boolean value", NULL);
hdump(qh);
printf("Adding keyword between key1 and key2...\n");
qfits_header_add_after(qh, "section.key1", "QFITS", "42",
"no comment", NULL);
hdump(qh);
/*
* Now perform some searches on the header
* using the dedicated qfits_header methods.
*/
printf("Retrieving keyword values as strings...\n");
printf("Keyword Value as string\n"
"\n"
"NAXIS1 \"%s\"\n"
"NAXIS2 \"%s\"\n"
"SECTION.KEY1 \"%s\"\n"
"SECTION.KEY2 \"%s\"\n"
"SECTION.KEY3 \"%s\"\n"
"SECTION.KEY4 \"%s\"\n",
qfits_header_getstr(qh, "naxis1"),
qfits_header_getstr(qh, "naxis2"),
qfits_header_getstr(qh, "section.key1"),
qfits_header_getstr(qh, "section.key2"),
qfits_header_getstr(qh, "section.key3"),
qfits_header_getstr(qh, "section.key4"));
printf(HR);
printf("Retrieving keyword values as typed variables...\n");
printf("\n");
printf("SECTION.KEY1 (string) : %s\n"
"SECTION.KEY2 (int) : %d\n"
"SECTION.KEY3 (float) : %g\n"
"SECTION.KEY4 (boolean): %d\n",
qfits_header_getstr(qh, "section.key1"),
qfits_header_getint(qh, "section.key2", -1),
qfits_header_getdouble(qh, "section.key3", -1.0),
qfits_header_getboolean(qh, "section.key4", -1));
printf(HR);
/*
* Modify the header, delete some cards
*/
printf("Modifying the header...\n");
qfits_header_mod(qh, "section.key1", "42", "no comment");
qfits_header_mod(qh, "section.key2", "42", "no comment");
qfits_header_mod(qh, "section.key3", "42", "no comment");
qfits_header_mod(qh, "section.key4", "42", "no comment");
hdump(qh);
printf("Removing keys...\n");
qfits_header_del(qh, "section.key1");
qfits_header_del(qh, "section.key2");
qfits_header_del(qh, "section.key3");
qfits_header_del(qh, "section.key4");
hdump(qh);
printf("Destroying header...\n");
qfits_header_destroy(qh);
return 0 ;
}

View File

@ -1,146 +0,0 @@
/*
* qfits example: loading pixels
*
* This example shows how to use the qfits pixel loader.
* The procedure consists in:
*
* - Filling up a qfitsloader structure
* - Calling qfitsload_init() on the structure
* - Calling qfits_loadpix() to load the pixels.
*
* This program takes in input the name of a FITS file, optionally an
* extension and plane number, loads the pixels and prints out the
* average pixel value. The pixel buffer is loaded in 3 different
* formats (float, double, int) to demonstrate the pixel loader.
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "qfits.h"
#include "xmemory.h"
int main(int argc, char * argv[])
{
/*
* To load pixels from a FITS image, a 'qfitsloader' object is needed.
* The simplest is to declare it statically rather than malloc() it
* since it is short-lived anyway and only exists for the duration of
* the load.
*/
qfitsloader ql ;
/* Following variables only useful to compute average pixel value */
int i, npix ;
double average ;
if (argc<2) {
printf("use: %s <filename> [plane] [extension]\n", argv[0]);
return 1 ;
}
/* Set load structure */
/* filename must be set */
ql.filename = argv[1] ;
/* Set xtnum and plane num to 0 if none are specified */
ql.xtnum = 0 ;
ql.pnum = 0 ;
/* Set the pixel load type to float for the first load */
ql.ptype = PTYPE_FLOAT ;
/* Get xtnum and pnum if specified on the command-line */
if (argc>2) {
ql.pnum = atoi(argv[2]);
}
if (argc>3) {
ql.xtnum = atoi(argv[3]);
}
printf("Loading pixel buffer as a float array...\n");
/* Try to initialize this load */
if (qfitsloader_init(&ql)!=0) {
/*
* Something went wrong.
* Since the error handler has been left untouched, the function
* must have printed out something on stderr about what happened.
* No need to be more verbose: bail out.
*/
return -1 ;
}
/* Perform actual load */
if (qfits_loadpix(&ql)!=0) {
/*
* Something went wrong: bailout
*/
return -1 ;
}
/*
* The pixel buffer is now loaded. Since the load was requested
* with ptype==PTYPE_FLOAT, the buffer to examine is fbuf (float
* pixel buffer).
*/
/* Compute npix (number of loaded pixels) once */
npix = ql.lx * ql.ly ;
/* Compute the average pixel value */
average=0 ;
for (i=0 ; i<npix ; average += (double)ql.fbuf[i++]) ;
average /= (double)npix ;
/* Pixel buffer not needed any more */
free(ql.fbuf);
printf("Average pixel value (float): %g\n", average);
/*
* Repeat the above steps to load all pixels as a double
* and an int array, and check the results.
*/
printf("Loading pixel buffer as a double array...\n");
/* Set load structure */
ql.ptype = PTYPE_DOUBLE ;
if (qfitsloader_init(&ql)!=0) {
return -1 ;
}
/* Perform load */
if (qfits_loadpix(&ql)!=0) {
return -1 ;
}
/* Compute the average pixel value */
average=0 ;
for (i=0 ; i<npix ; average += ql.dbuf[i++]) ;
average /= (double)npix ;
free(ql.dbuf);
printf("Average pixel value (double): %g\n", average);
printf("Loading pixel buffer as an int array...\n");
/* Set load structure */
ql.ptype = PTYPE_INT ;
if (qfitsloader_init(&ql)!=0) {
return -1 ;
}
/* Perform load */
if (qfits_loadpix(&ql)!=0) {
return -1 ;
}
/* Compute the average pixel value */
average=0 ;
for (i=0 ; i<npix ; average += (double)ql.ibuf[i++]) ;
average /= (double)npix ;
free(ql.ibuf);
printf("Average pixel value (int): %g\n", average);
/* Call xmemory_status to check for memory leaks */
xmemory_status();
return 0 ;
}

View File

@ -1,170 +0,0 @@
/*
* qfits example: Read a value in a table
*
* In this example, a FITS table is loaded and examined
* using the qfits_table object. Than a value is read and displayed
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "qfits.h"
int main(int argc, char * argv[])
{
int table_type ;
qfits_table * th ;
qfits_col * ch ;
void * column ;
unsigned char * uccol ;
char * ccol ;
int * icol ;
short * scol ;
float * fcol ;
double * dcol ;
char ctmp[512];
int raw ;
int col ;
int extension ;
int i ;
/* Initialize */
extension = 1 ;
raw = 0 ;
col = 0 ;
/* Check command-line arguments. */
if (argc<2) {
printf("use: %s <filename>\n", argv[0]);
return -1 ;
}
/* Check if this is indeed a FITS file */
if (is_fits_file(argv[1])!=1) {
printf("%s is not a FITS file\n", argv[1]);
return -1 ;
}
/* Check if the FITS file is a FITS table */
table_type = qfits_is_table(argv[1], extension) ;
if (table_type == QFITS_INVALIDTABLE) {
printf("%s is not a TFITS table\n", argv[1]) ;
return -1 ;
} else if (table_type == QFITS_ASCIITABLE) {
printf("%s is an ASCII table\n", argv[1]) ;
} else if (table_type == QFITS_BINTABLE) {
printf("%s is a BIN table\n", argv[1]) ;
} else return -1 ;
/* Get the positions in the table from the command line or the defaults */
if (argc>3) {
raw = (int)atoi(argv[2]) - 1 ;
col = (int)atoi(argv[3]) - 1 ;
} else printf("Use defaults\n") ;
printf("Get the value of : raw: %d, col: %d\n", raw+1, col+1) ;
/* Load the table informations */
/* The th objects contains all needed infos about the table */
if ((th = qfits_table_open(argv[1], extension)) == NULL) {
printf("cannot get infos from the table\n") ;
return -1 ;
}
/* Test if col and raw are valid */
if ((raw < 0) || (col < 0) || (col+1 > th->nc) || (raw+1 > th->nr)) {
printf("invalid specified raw and col\n") ;
qfits_table_close(th) ;
return -1 ;
}
/* Load the needed column as a void* */
if ((column = qfits_query_column_data(th, col, NULL, NULL)) == NULL) {
printf("Cannot access to the column %d\n", col+1) ;
qfits_table_close(th) ;
return -1 ;
}
/* Set reference to the column */
ch = th->col + col ;
printf("The requested field is: \n") ;
/* column is different for each type */
/* For each type the column has to be casted in the right type */
/* The searched value can than be read */
switch(ch->atom_type) {
case TFITS_BIN_TYPE_A:
case TFITS_ASCII_TYPE_A:
ccol = (char*)column ;
strncpy(ctmp, ccol + ch->atom_nb * raw, ch->atom_nb) ;
ctmp[ch->atom_size*ch->atom_nb] = (char)0 ;
printf("%s", ctmp) ;
break ;
case TFITS_BIN_TYPE_B:
case TFITS_BIN_TYPE_X:
uccol = (unsigned char*)column ;
for (i=0 ; i<ch->atom_nb ; i++) {
printf("%d\t", (int)uccol[ch->atom_nb*raw+i]) ;
}
break ;
case TFITS_BIN_TYPE_D:
case TFITS_BIN_TYPE_M:
dcol = (double*)column ;
for (i=0 ; i<ch->atom_nb ; i++) {
printf("%g\t", dcol[ch->atom_nb*raw+i]) ;
}
break ;
case TFITS_BIN_TYPE_E:
case TFITS_BIN_TYPE_C:
fcol = (float*)column ;
for (i=0 ; i<ch->atom_nb ; i++) {
printf("%f\t", fcol[ch->atom_nb*raw+i]) ;
}
break ;
case TFITS_BIN_TYPE_I:
scol = (short*)column ;
for (i=0 ; i<ch->atom_nb ; i++) {
printf("%d\t", (int)scol[ch->atom_nb*raw+i]) ;
}
break ;
case TFITS_BIN_TYPE_J:
case TFITS_BIN_TYPE_P:
icol = (int*)column ;
for (i=0 ; i<ch->atom_nb ; i++) {
printf("%d\t", icol[ch->atom_nb*raw+i]) ;
}
break ;
case TFITS_BIN_TYPE_L:
ccol = (char*)column ;
for (i=0 ; i<ch->atom_nb ; i++) {
printf("%c\t", ccol[ch->atom_nb*raw+i]) ;
}
break ;
case TFITS_ASCII_TYPE_I:
icol = (int*)column ;
printf("%d", icol[raw]) ;
break ;
case TFITS_ASCII_TYPE_E:
case TFITS_ASCII_TYPE_F:
fcol = (float*)column ;
printf("%f", fcol[raw]) ;
break ;
case TFITS_ASCII_TYPE_D:
dcol = (double*)column ;
printf("%g", dcol[raw]) ;
break ;
default:
printf("Unrecognized type\n") ;
free(column) ;
qfits_table_close(th) ;
return -1 ;
break ;
}
printf("\n") ;
free(column) ;
return 0 ;
}

View File

@ -1,59 +0,0 @@
/*
* qfits example: querying FITS headers, supporting extensions.
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "qfits.h"
int main(int argc, char * argv[])
{
char keyword[FITS_LINESZ+1] ;
char * value ;
int xtnum ;
int n_ext ;
if (argc!=3) {
printf("use: %s <filename> <extension>\n", argv[0]);
return 1 ;
}
/* Check this is indeed a FITS file */
if (is_fits_file(argv[1])!=1) {
printf("%s is not a FITS file\n", argv[1]);
return -1 ;
}
/* Check the requested extension actually exists */
xtnum = atoi(argv[2]);
n_ext = qfits_query_n_ext(argv[1]);
printf("file %s has %d extension(s)\n", argv[1], n_ext);
if (xtnum<0 || xtnum>n_ext) {
printf("extension %d does not exist\n", xtnum);
return -1 ;
}
printf("\n\n");
printf("file %s loaded Ok\n", argv[1]);
printf("provide keywords to look for in extension header %d\n"
"(extension 0 is main header)\n"
"(q to quit)\n"
"\n", xtnum);
while (1) {
printf("-----> keyword? ");
scanf("%s", keyword);
if (!strcmp(keyword, "q"))
return 0 ;
value = qfits_query_ext(argv[1], keyword, xtnum);
if (value) {
printf("found with value: %s\n", value);
} else {
printf("not found in header (%d)\n", xtnum);
}
}
return 0 ;
}

View File

@ -1,48 +0,0 @@
/*
* qfits example: querying FITS headers.
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "qfits.h"
int main(int argc, char * argv[])
{
char keyword[FITS_LINESZ+1] ;
char * value ;
if (argc<2) {
printf("use: %s <filename>\n", argv[0]);
return 1 ;
}
/* Check this is indeed a FITS file */
if (is_fits_file(argv[1])!=1) {
printf("%s is not a FITS file\n", argv[1]);
return -1 ;
}
printf("\n\n");
printf("file %s loaded Ok\n", argv[1]);
printf("provide keywords to look for in the main header\n"
"(q to quit)\n"
"\n");
while (1) {
printf("-----> keyword? ");
scanf("%s", keyword);
if (!strcmp(keyword, "q"))
return 0 ;
value = qfits_query_hdr(argv[1], keyword);
if (value) {
printf("found with value: %s\n", value);
} else {
printf("not found in header\n");
}
}
return 0 ;
}

View File

@ -0,0 +1,19 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>QFITS Reference Manual Data Structures</h1>Here are the data structures with brief descriptions:<table>
<tr><td class="indexkey"><a class="el" href="struct__keytuple__.html">_keytuple_</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="struct__qfits__cache__cell__.html">_qfits_cache_cell_</a></td><td class="indexvalue"></td></tr>
</table>
</body>
</html>

View File

@ -0,0 +1,19 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>QFITS Reference Manual Data Structure Index</h1><p><div class="qindex"><a class="qindex" href="#letter__">_</a></div><p>
<table align="center" width="95%" border="0" cellspacing="0" cellpadding="0">
<tr><td><a name="letter__"></a><table border="0" cellspacing="0" cellpadding="0"><tr><td><div class="ah">&nbsp;&nbsp;_&nbsp;&nbsp;</div></td></tr></table>
</td><td><a class="el" href="struct__keytuple__.html">_keytuple_</a>&nbsp;&nbsp;&nbsp;</td><td><a class="el" href="struct__qfits__cache__cell__.html">_qfits_cache_cell_</a>&nbsp;&nbsp;&nbsp;</td></tr></table><p><div class="qindex"><a class="qindex" href="#letter__">_</a></div><p>
</body>
</html>

View File

@ -2,7 +2,7 @@
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>qfits 5.3.1</title>
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
@ -11,11 +11,29 @@
<!-- Generated by Doxygen 1.4.1 -->
<div class="nav">
<a class="el" href="dir_000000.html">include</a></div>
<h1>include Directory Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<a class="el" href="dir_000000.html">src</a></div>
<h1>src Directory Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Files</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">file &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits_8h.html">qfits.h</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">file &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits__cache_8c.html">qfits_cache.c</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">file &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits__filename_8c.html">qfits_filename.c</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">file &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits__header_8c.html">qfits_header.c</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">file &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits__image_8c.html">qfits_image.c</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">file &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits__md5_8c.html">qfits_md5.c</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">file &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits__memory_8c.html">qfits_memory.c</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">file &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits__rw_8c.html">qfits_rw.c</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">file &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits__table_8c.html">qfits_table.c</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">file &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits__time_8c.html">qfits_time.c</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">file &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits__tools_8c.html">qfits_tools.c</a></td></tr>
</table>

View File

@ -2,7 +2,7 @@
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>qfits 5.3.1</title>
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
@ -10,8 +10,8 @@
<!-- Generated by Doxygen 1.4.1 -->
<h1>qfits Directories</h1>This directory hierarchy is sorted roughly, but not completely, alphabetically:<ul>
<li><a class="el" href="dir_000000.html">include</a>
<h1>QFITS Reference Manual Directories</h1>This directory hierarchy is sorted roughly, but not completely, alphabetically:<ul>
<li><a class="el" href="dir_000000.html">src</a>
</ul>
</body>

View File

@ -0,0 +1,28 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>QFITS Reference Manual File List</h1>Here is a list of all files with brief descriptions:<table>
<tr><td class="indexkey"><a class="el" href="qfits_8head.html">qfits.head</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="qfits__cache_8c.html">qfits_cache.c</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="qfits__filename_8c.html">qfits_filename.c</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="qfits__header_8c.html">qfits_header.c</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="qfits__image_8c.html">qfits_image.c</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="qfits__md5_8c.html">qfits_md5.c</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="qfits__memory_8c.html">qfits_memory.c</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="qfits__rw_8c.html">qfits_rw.c</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="qfits__table_8c.html">qfits_table.c</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="qfits__time_8c.html">qfits_time.c</a></td><td class="indexvalue"></td></tr>
<tr><td class="indexkey"><a class="el" href="qfits__tools_8c.html">qfits_tools.c</a></td><td class="indexvalue"></td></tr>
</table>
</body>
</html>

View File

@ -0,0 +1,38 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<div class="qindex"><a class="qindexHL" href="functions.html">All</a> | <a class="qindex" href="functions_vars.html">Variables</a></div>
<p>
Here is a list of all struct and union fields with links to the structures/unions they belong to:<ul>
<li>com
: <a class="el" href="struct__keytuple__.html#o2">_keytuple_</a><li>ctime
: <a class="el" href="struct__qfits__cache__cell__.html#o4">_qfits_cache_cell_</a><li>data
: <a class="el" href="struct__qfits__cache__cell__.html#o8">_qfits_cache_cell_</a><li>dsiz
: <a class="el" href="struct__qfits__cache__cell__.html#o9">_qfits_cache_cell_</a><li>exts
: <a class="el" href="struct__qfits__cache__cell__.html#o5">_qfits_cache_cell_</a><li>filesize
: <a class="el" href="struct__qfits__cache__cell__.html#o3">_qfits_cache_cell_</a><li>fsize
: <a class="el" href="struct__qfits__cache__cell__.html#o10">_qfits_cache_cell_</a><li>inode
: <a class="el" href="struct__qfits__cache__cell__.html#o1">_qfits_cache_cell_</a><li>key
: <a class="el" href="struct__keytuple__.html#o0">_keytuple_</a><li>lin
: <a class="el" href="struct__keytuple__.html#o3">_keytuple_</a><li>mtime
: <a class="el" href="struct__qfits__cache__cell__.html#o2">_qfits_cache_cell_</a><li>name
: <a class="el" href="struct__qfits__cache__cell__.html#o0">_qfits_cache_cell_</a><li>next
: <a class="el" href="struct__keytuple__.html#o5">_keytuple_</a><li>ohdr
: <a class="el" href="struct__qfits__cache__cell__.html#o6">_qfits_cache_cell_</a><li>prev
: <a class="el" href="struct__keytuple__.html#o6">_keytuple_</a><li>shdr
: <a class="el" href="struct__qfits__cache__cell__.html#o7">_qfits_cache_cell_</a><li>typ
: <a class="el" href="struct__keytuple__.html#o4">_keytuple_</a><li>val
: <a class="el" href="struct__keytuple__.html#o1">_keytuple_</a></ul>
</body>
</html>

View File

@ -2,7 +2,7 @@
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>qfits 5.3.1</title>
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
@ -11,89 +11,28 @@
<!-- Generated by Doxygen 1.4.1 -->
<div class="qindex"><a class="qindex" href="functions.html">All</a> | <a class="qindexHL" href="functions_vars.html">Variables</a></div>
<div class="qindex"><a class="qindex" href="#index__">_</a> | <a class="qindex" href="#index_a">a</a> | <a class="qindex" href="#index_b">b</a> | <a class="qindex" href="#index_c">c</a> | <a class="qindex" href="#index_d">d</a> | <a class="qindex" href="#index_e">e</a> | <a class="qindex" href="#index_f">f</a> | <a class="qindex" href="#index_i">i</a> | <a class="qindex" href="#index_l">l</a> | <a class="qindex" href="#index_m">m</a> | <a class="qindex" href="#index_n">n</a> | <a class="qindex" href="#index_o">o</a> | <a class="qindex" href="#index_p">p</a> | <a class="qindex" href="#index_r">r</a> | <a class="qindex" href="#index_s">s</a> | <a class="qindex" href="#index_t">t</a> | <a class="qindex" href="#index_x">x</a> | <a class="qindex" href="#index_z">z</a></div>
<p>
<p>
<h3><a class="anchor" name="index__">- _ -</a></h3><ul>
<li>_init
: <a class="el" href="structqfitsloader.html#o0">qfitsloader</a></ul>
<h3><a class="anchor" name="index_a">- a -</a></h3><ul>
<li>atom_dec_nb
: <a class="el" href="structqfits__col.html#o1">qfits_col</a><li>atom_nb
: <a class="el" href="structqfits__col.html#o0">qfits_col</a><li>atom_size
: <a class="el" href="structqfits__col.html#o2">qfits_col</a><li>atom_type
: <a class="el" href="structqfits__col.html#o3">qfits_col</a></ul>
<h3><a class="anchor" name="index_b">- b -</a></h3><ul>
<li>bitpix
: <a class="el" href="structqfitsloader.html#o10">qfitsloader</a><li>bscale
: <a class="el" href="structqfitsloader.html#o13">qfitsloader</a><li>bzero
: <a class="el" href="structqfitsloader.html#o14">qfitsloader</a></ul>
<h3><a class="anchor" name="index_c">- c -</a></h3><ul>
<li>col
: <a class="el" href="structqfits__table.html#o5">qfits_table</a></ul>
<h3><a class="anchor" name="index_d">- d -</a></h3><ul>
<li>dbuf
: <a class="el" href="structqfitsdumper.html#o5">qfitsdumper</a>, <a class="el" href="structqfitsloader.html#o17">qfitsloader</a></ul>
<h3><a class="anchor" name="index_e">- e -</a></h3><ul>
<li>exts
: <a class="el" href="structqfitsloader.html#o6">qfitsloader</a></ul>
<h3><a class="anchor" name="index_f">- f -</a></h3><ul>
<li>fbuf
: <a class="el" href="structqfitsdumper.html#o4">qfitsdumper</a>, <a class="el" href="structqfitsloader.html#o16">qfitsloader</a><li>filename
: <a class="el" href="structqfits__table.html#o0">qfits_table</a>, <a class="el" href="structqfitsdumper.html#o0">qfitsdumper</a>, <a class="el" href="structqfitsloader.html#o1">qfitsloader</a><li>first
: <a class="el" href="structqfits__header.html#o0">qfits_header</a></ul>
<h3><a class="anchor" name="index_i">- i -</a></h3><ul>
<li>ibuf
: <a class="el" href="structqfitsdumper.html#o3">qfitsdumper</a>, <a class="el" href="structqfitsloader.html#o15">qfitsloader</a></ul>
<h3><a class="anchor" name="index_l">- l -</a></h3><ul>
<li>last
: <a class="el" href="structqfits__header.html#o1">qfits_header</a><li>lx
: <a class="el" href="structqfitsloader.html#o7">qfitsloader</a><li>ly
: <a class="el" href="structqfitsloader.html#o8">qfitsloader</a></ul>
<h3><a class="anchor" name="index_m">- m -</a></h3><ul>
<li>map
: <a class="el" href="structqfitsloader.html#o5">qfitsloader</a></ul>
<h3><a class="anchor" name="index_n">- n -</a></h3><ul>
<li>n
: <a class="el" href="structqfits__header.html#o2">qfits_header</a><li>nc
: <a class="el" href="structqfits__table.html#o3">qfits_table</a><li>np
: <a class="el" href="structqfitsloader.html#o9">qfitsloader</a><li>npix
: <a class="el" href="structqfitsdumper.html#o1">qfitsdumper</a><li>nr
: <a class="el" href="structqfits__table.html#o4">qfits_table</a><li>nullval
: <a class="el" href="structqfits__col.html#o6">qfits_col</a></ul>
<h3><a class="anchor" name="index_o">- o -</a></h3><ul>
<li>off_beg
: <a class="el" href="structqfits__col.html#o12">qfits_col</a><li>out_ptype
: <a class="el" href="structqfitsdumper.html#o6">qfitsdumper</a></ul>
<h3><a class="anchor" name="index_p">- p -</a></h3><ul>
<li>pnum
: <a class="el" href="structqfitsloader.html#o3">qfitsloader</a><li>ptype
: <a class="el" href="structqfitsdumper.html#o2">qfitsdumper</a>, <a class="el" href="structqfitsloader.html#o4">qfitsloader</a></ul>
<h3><a class="anchor" name="index_r">- r -</a></h3><ul>
<li>readable
: <a class="el" href="structqfits__col.html#o13">qfits_col</a></ul>
<h3><a class="anchor" name="index_s">- s -</a></h3><ul>
<li>scale
: <a class="el" href="structqfits__col.html#o11">qfits_col</a><li>scale_present
: <a class="el" href="structqfits__col.html#o10">qfits_col</a><li>seg_size
: <a class="el" href="structqfitsloader.html#o12">qfitsloader</a><li>seg_start
: <a class="el" href="structqfitsloader.html#o11">qfitsloader</a></ul>
<h3><a class="anchor" name="index_t">- t -</a></h3><ul>
<li>tab_t
: <a class="el" href="structqfits__table.html#o1">qfits_table</a><li>tab_w
: <a class="el" href="structqfits__table.html#o2">qfits_table</a><li>tdisp
: <a class="el" href="structqfits__col.html#o7">qfits_col</a><li>tlabel
: <a class="el" href="structqfits__col.html#o4">qfits_col</a><li>tunit
: <a class="el" href="structqfits__col.html#o5">qfits_col</a></ul>
<h3><a class="anchor" name="index_x">- x -</a></h3><ul>
<li>xtnum
: <a class="el" href="structqfitsloader.html#o2">qfitsloader</a></ul>
<h3><a class="anchor" name="index_z">- z -</a></h3><ul>
<li>zero
: <a class="el" href="structqfits__col.html#o9">qfits_col</a><li>zero_present
: <a class="el" href="structqfits__col.html#o8">qfits_col</a></ul>
<ul>
<li>com
: <a class="el" href="struct__keytuple__.html#o2">_keytuple_</a><li>ctime
: <a class="el" href="struct__qfits__cache__cell__.html#o4">_qfits_cache_cell_</a><li>data
: <a class="el" href="struct__qfits__cache__cell__.html#o8">_qfits_cache_cell_</a><li>dsiz
: <a class="el" href="struct__qfits__cache__cell__.html#o9">_qfits_cache_cell_</a><li>exts
: <a class="el" href="struct__qfits__cache__cell__.html#o5">_qfits_cache_cell_</a><li>filesize
: <a class="el" href="struct__qfits__cache__cell__.html#o3">_qfits_cache_cell_</a><li>fsize
: <a class="el" href="struct__qfits__cache__cell__.html#o10">_qfits_cache_cell_</a><li>inode
: <a class="el" href="struct__qfits__cache__cell__.html#o1">_qfits_cache_cell_</a><li>key
: <a class="el" href="struct__keytuple__.html#o0">_keytuple_</a><li>lin
: <a class="el" href="struct__keytuple__.html#o3">_keytuple_</a><li>mtime
: <a class="el" href="struct__qfits__cache__cell__.html#o2">_qfits_cache_cell_</a><li>name
: <a class="el" href="struct__qfits__cache__cell__.html#o0">_qfits_cache_cell_</a><li>next
: <a class="el" href="struct__keytuple__.html#o5">_keytuple_</a><li>ohdr
: <a class="el" href="struct__qfits__cache__cell__.html#o6">_qfits_cache_cell_</a><li>prev
: <a class="el" href="struct__keytuple__.html#o6">_keytuple_</a><li>shdr
: <a class="el" href="struct__qfits__cache__cell__.html#o7">_qfits_cache_cell_</a><li>typ
: <a class="el" href="struct__keytuple__.html#o4">_keytuple_</a><li>val
: <a class="el" href="struct__keytuple__.html#o1">_keytuple_</a></ul>
</body>
</html>

View File

@ -0,0 +1,165 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<div class="qindex"><a class="qindexHL" href="globals.html">All</a> | <a class="qindex" href="globals_func.html">Functions</a> | <a class="qindex" href="globals_vars.html">Variables</a> | <a class="qindex" href="globals_type.html">Typedefs</a> | <a class="qindex" href="globals_enum.html">Enumerations</a> | <a class="qindex" href="globals_eval.html">Enumeration&nbsp;values</a></div>
<div class="qindex"><a class="qindex" href="#index__">_</a> | <a class="qindex" href="#index_a">a</a> | <a class="qindex" href="#index_f">f</a> | <a class="qindex" href="#index_k">k</a> | <a class="qindex" href="#index_m">m</a> | <a class="qindex" href="#index_n">n</a> | <a class="qindex" href="#index_p">p</a> | <a class="qindex" href="#index_q">q</a> | <a class="qindex" href="#index_r">r</a></div>
<p>
<p>
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:<h3><a class="anchor" name="index__">- _ -</a></h3><ul>
<li>_keytype_
: <a class="el" href="qfits__header_8c.html#a56">qfits_header.c</a></ul>
<h3><a class="anchor" name="index_a">- a -</a></h3><ul>
<li>alloc_max
: <a class="el" href="qfits__memory_8c.html#a6">qfits_memory.c</a><li>alloc_ram
: <a class="el" href="qfits__memory_8c.html#a4">qfits_memory.c</a><li>alloc_swap
: <a class="el" href="qfits__memory_8c.html#a5">qfits_memory.c</a><li>alloc_total
: <a class="el" href="qfits__memory_8c.html#a3">qfits_memory.c</a></ul>
<h3><a class="anchor" name="index_f">- f -</a></h3><ul>
<li>file_reg
: <a class="el" href="qfits__memory_8c.html#a9">qfits_memory.c</a></ul>
<h3><a class="anchor" name="index_k">- k -</a></h3><ul>
<li>keytuple
: <a class="el" href="qfits__header_8c.html#a0">qfits_header.c</a><li>keytype
: <a class="el" href="qfits__header_8c.html#a1">qfits_header.c</a><li>keytype_bitpix
: <a class="el" href="qfits__header_8c.html#a56a4">qfits_header.c</a><li>keytype_bscale
: <a class="el" href="qfits__header_8c.html#a56a15">qfits_header.c</a><li>keytype_bzero
: <a class="el" href="qfits__header_8c.html#a56a16">qfits_header.c</a><li>keytype_comment
: <a class="el" href="qfits__header_8c.html#a56a32">qfits_header.c</a><li>keytype_end
: <a class="el" href="qfits__header_8c.html#a56a33">qfits_header.c</a><li>keytype_extend
: <a class="el" href="qfits__header_8c.html#a56a14">qfits_header.c</a><li>keytype_gcount
: <a class="el" href="qfits__header_8c.html#a56a13">qfits_header.c</a><li>keytype_group
: <a class="el" href="qfits__header_8c.html#a56a11">qfits_header.c</a><li>keytype_hierarch
: <a class="el" href="qfits__header_8c.html#a56a30">qfits_header.c</a><li>keytype_hierarch_det
: <a class="el" href="qfits__header_8c.html#a56a27">qfits_header.c</a><li>keytype_hierarch_dpr
: <a class="el" href="qfits__header_8c.html#a56a21">qfits_header.c</a><li>keytype_hierarch_gen
: <a class="el" href="qfits__header_8c.html#a56a24">qfits_header.c</a><li>keytype_hierarch_ins
: <a class="el" href="qfits__header_8c.html#a56a26">qfits_header.c</a><li>keytype_hierarch_log
: <a class="el" href="qfits__header_8c.html#a56a28">qfits_header.c</a><li>keytype_hierarch_obs
: <a class="el" href="qfits__header_8c.html#a56a22">qfits_header.c</a><li>keytype_hierarch_pro
: <a class="el" href="qfits__header_8c.html#a56a29">qfits_header.c</a><li>keytype_hierarch_tel
: <a class="el" href="qfits__header_8c.html#a56a25">qfits_header.c</a><li>keytype_hierarch_tpl
: <a class="el" href="qfits__header_8c.html#a56a23">qfits_header.c</a><li>keytype_history
: <a class="el" href="qfits__header_8c.html#a56a31">qfits_header.c</a><li>keytype_naxis
: <a class="el" href="qfits__header_8c.html#a56a5">qfits_header.c</a><li>keytype_naxis1
: <a class="el" href="qfits__header_8c.html#a56a6">qfits_header.c</a><li>keytype_naxis2
: <a class="el" href="qfits__header_8c.html#a56a7">qfits_header.c</a><li>keytype_naxis3
: <a class="el" href="qfits__header_8c.html#a56a8">qfits_header.c</a><li>keytype_naxis4
: <a class="el" href="qfits__header_8c.html#a56a9">qfits_header.c</a><li>keytype_naxisi
: <a class="el" href="qfits__header_8c.html#a56a10">qfits_header.c</a><li>keytype_pcount
: <a class="el" href="qfits__header_8c.html#a56a12">qfits_header.c</a><li>keytype_primary
: <a class="el" href="qfits__header_8c.html#a56a20">qfits_header.c</a><li>keytype_tbcoli
: <a class="el" href="qfits__header_8c.html#a56a18">qfits_header.c</a><li>keytype_tfields
: <a class="el" href="qfits__header_8c.html#a56a17">qfits_header.c</a><li>keytype_tformi
: <a class="el" href="qfits__header_8c.html#a56a19">qfits_header.c</a><li>keytype_top
: <a class="el" href="qfits__header_8c.html#a56a3">qfits_header.c</a><li>keytype_undef
: <a class="el" href="qfits__header_8c.html#a56a2">qfits_header.c</a></ul>
<h3><a class="anchor" name="index_m">- m -</a></h3><ul>
<li>main()
: <a class="el" href="qfits__image_8c.html#a11">qfits_image.c</a><li>max_cells
: <a class="el" href="qfits__memory_8c.html#a7">qfits_memory.c</a></ul>
<h3><a class="anchor" name="index_n">- n -</a></h3><ul>
<li>n_mm_files
: <a class="el" href="qfits__memory_8c.html#a10">qfits_memory.c</a><li>n_mm_mappings
: <a class="el" href="qfits__memory_8c.html#a11">qfits_memory.c</a><li>ncells
: <a class="el" href="qfits__memory_8c.html#a2">qfits_memory.c</a><li>nswapfiles
: <a class="el" href="qfits__memory_8c.html#a8">qfits_memory.c</a></ul>
<h3><a class="anchor" name="index_p">- p -</a></h3><ul>
<li>pagesize
: <a class="el" href="qfits__memory_8c.html#a12">qfits_memory.c</a></ul>
<h3><a class="anchor" name="index_q">- q -</a></h3><ul>
<li>qfits_cache_cell
: <a class="el" href="qfits__cache_8c.html#a0">qfits_cache.c</a><li>qfits_cache_purge()
: <a class="el" href="group__qfits__cache.html#ga0">qfits_cache.c</a><li>qfits_col_fill()
: <a class="el" href="group__qfits__table.html#ga4">qfits_table.c</a><li>qfits_datamd5()
: <a class="el" href="group__qfits__md5.html#ga0">qfits_md5.c</a><li>qfits_get_base_name()
: <a class="el" href="group__qfits__filename.html#ga1">qfits_filename.c</a><li>qfits_get_datetime_iso8601()
: <a class="el" href="group__qfits__time.html#ga0">qfits_time.c</a><li>qfits_get_datinfo()
: <a class="el" href="group__qfits__rw.html#ga7">qfits_rw.c</a><li>qfits_get_dir_name()
: <a class="el" href="group__qfits__filename.html#ga0">qfits_filename.c</a><li>qfits_get_ext_name()
: <a class="el" href="group__qfits__filename.html#ga3">qfits_filename.c</a><li>qfits_get_hdrinfo()
: <a class="el" href="group__qfits__rw.html#ga6">qfits_rw.c</a><li>qfits_get_root_name()
: <a class="el" href="group__qfits__filename.html#ga2">qfits_filename.c</a><li>qfits_get_type()
: <a class="el" href="group__qfits__tools.html#ga10">qfits_tools.c</a><li>qfits_header_add()
: <a class="el" href="group__qfits__header.html#ga2">qfits_header.c</a><li>qfits_header_add_after()
: <a class="el" href="group__qfits__header.html#ga3">qfits_header.c</a><li>qfits_header_append()
: <a class="el" href="group__qfits__header.html#ga4">qfits_header.c</a><li>qfits_header_copy()
: <a class="el" href="group__qfits__header.html#ga8">qfits_header.c</a><li>qfits_header_default()
: <a class="el" href="group__qfits__header.html#ga1">qfits_header.c</a><li>qfits_header_del()
: <a class="el" href="group__qfits__header.html#ga5">qfits_header.c</a><li>qfits_header_destroy()
: <a class="el" href="group__qfits__header.html#ga9">qfits_header.c</a><li>qfits_header_dump()
: <a class="el" href="group__qfits__header.html#ga16">qfits_header.c</a><li>qfits_header_getboolean()
: <a class="el" href="group__qfits__header.html#ga15">qfits_header.c</a><li>qfits_header_getcom()
: <a class="el" href="group__qfits__header.html#ga12">qfits_header.c</a><li>qfits_header_getdouble()
: <a class="el" href="group__qfits__header.html#ga14">qfits_header.c</a><li>qfits_header_getint()
: <a class="el" href="group__qfits__header.html#ga13">qfits_header.c</a><li>qfits_header_getitem()
: <a class="el" href="group__qfits__header.html#ga11">qfits_header.c</a><li>qfits_header_getstr()
: <a class="el" href="group__qfits__header.html#ga10">qfits_header.c</a><li>qfits_header_mod()
: <a class="el" href="group__qfits__header.html#ga6">qfits_header.c</a><li>qfits_header_new()
: <a class="el" href="group__qfits__header.html#ga0">qfits_header.c</a><li>qfits_header_read()
: <a class="el" href="group__qfits__rw.html#ga0">qfits_rw.c</a><li>qfits_header_read_hdr()
: <a class="el" href="group__qfits__rw.html#ga1">qfits_rw.c</a><li>qfits_header_read_hdr_string()
: <a class="el" href="group__qfits__rw.html#ga2">qfits_rw.c</a><li>qfits_header_readext()
: <a class="el" href="group__qfits__rw.html#ga3">qfits_rw.c</a><li>qfits_header_sort()
: <a class="el" href="group__qfits__header.html#ga7">qfits_header.c</a><li>qfits_is_boolean()
: <a class="el" href="group__qfits__tools.html#ga5">qfits_tools.c</a><li>qfits_is_complex()
: <a class="el" href="group__qfits__tools.html#ga8">qfits_tools.c</a><li>qfits_is_fits()
: <a class="el" href="group__qfits__rw.html#ga5">qfits_rw.c</a><li>qfits_is_float()
: <a class="el" href="group__qfits__tools.html#ga7">qfits_tools.c</a><li>qfits_is_int()
: <a class="el" href="group__qfits__tools.html#ga6">qfits_tools.c</a><li>qfits_is_string()
: <a class="el" href="group__qfits__tools.html#ga9">qfits_tools.c</a><li>qfits_is_table()
: <a class="el" href="group__qfits__table.html#ga0">qfits_table.c</a><li>qfits_loadpix()
: <a class="el" href="group__qfits__image.html#ga1">qfits_image.c</a><li>qfits_loadpix_window()
: <a class="el" href="group__qfits__image.html#ga2">qfits_image.c</a><li>qfits_memory_calloc()
: <a class="el" href="group__qfits__memory.html#ga1">qfits_memory.c</a><li>qfits_memory_falloc()
: <a class="el" href="group__qfits__memory.html#ga2">qfits_memory.c</a><li>qfits_memory_fdealloc()
: <a class="el" href="group__qfits__memory.html#ga3">qfits_memory.c</a><li>qfits_memory_free()
: <a class="el" href="group__qfits__memory.html#ga4">qfits_memory.c</a><li>qfits_memory_is_empty()
: <a class="el" href="group__qfits__memory.html#ga8">qfits_memory.c</a><li>qfits_memory_malloc()
: <a class="el" href="group__qfits__memory.html#ga0">qfits_memory.c</a><li>qfits_memory_realloc()
: <a class="el" href="group__qfits__memory.html#ga5">qfits_memory.c</a><li>qfits_memory_status()
: <a class="el" href="group__qfits__memory.html#ga7">qfits_memory.c</a><li>qfits_memory_status_()
: <a class="el" href="qfits__memory_8c.html#a33">qfits_memory.c</a><li>qfits_memory_strdup()
: <a class="el" href="group__qfits__memory.html#ga6">qfits_memory.c</a><li>qfits_pixdump()
: <a class="el" href="group__qfits__image.html#ga3">qfits_image.c</a><li>qfits_pretty_string()
: <a class="el" href="group__qfits__tools.html#ga4">qfits_tools.c</a><li>qfits_query()
: <a class="el" href="group__qfits__cache.html#ga1">qfits_cache.c</a><li>qfits_query_card()
: <a class="el" href="group__qfits__tools.html#ga11">qfits_tools.c</a><li>qfits_query_column()
: <a class="el" href="group__qfits__table.html#ga7">qfits_table.c</a><li>qfits_query_column_data()
: <a class="el" href="group__qfits__table.html#ga9">qfits_table.c</a><li>qfits_query_column_nulls()
: <a class="el" href="group__qfits__table.html#ga11">qfits_table.c</a><li>qfits_query_column_seq()
: <a class="el" href="group__qfits__table.html#ga8">qfits_table.c</a><li>qfits_query_column_seq_data()
: <a class="el" href="group__qfits__table.html#ga10">qfits_table.c</a><li>qfits_query_ext()
: <a class="el" href="group__qfits__tools.html#ga1">qfits_tools.c</a><li>qfits_query_hdr()
: <a class="el" href="group__qfits__tools.html#ga0">qfits_tools.c</a><li>qfits_query_n_ext()
: <a class="el" href="group__qfits__tools.html#ga2">qfits_tools.c</a><li>qfits_query_nplanes()
: <a class="el" href="group__qfits__tools.html#ga3">qfits_tools.c</a><li>qfits_replace_card()
: <a class="el" href="group__qfits__tools.html#ga12">qfits_tools.c</a><li>qfits_save_table_hdrdump()
: <a class="el" href="group__qfits__table.html#ga12">qfits_table.c</a><li>qfits_table_append_xtension()
: <a class="el" href="group__qfits__table.html#ga13">qfits_table.c</a><li>qfits_table_append_xtension_hdr()
: <a class="el" href="group__qfits__table.html#ga14">qfits_table.c</a><li>qfits_table_close()
: <a class="el" href="group__qfits__table.html#ga6">qfits_table.c</a><li>qfits_table_ext_header_default()
: <a class="el" href="group__qfits__table.html#ga2">qfits_table.c</a><li>qfits_table_field_to_string()
: <a class="el" href="group__qfits__table.html#ga15">qfits_table.c</a><li>qfits_table_new()
: <a class="el" href="group__qfits__table.html#ga3">qfits_table.c</a><li>qfits_table_open()
: <a class="el" href="group__qfits__table.html#ga5">qfits_table.c</a><li>qfits_table_prim_header_default()
: <a class="el" href="group__qfits__table.html#ga1">qfits_table.c</a><li>qfits_version()
: <a class="el" href="group__qfits__tools.html#ga13">qfits_tools.c</a><li>qfits_zeropad()
: <a class="el" href="group__qfits__rw.html#ga4">qfits_rw.c</a><li>qfitsloader_init()
: <a class="el" href="group__qfits__image.html#ga0">qfits_image.c</a></ul>
<h3><a class="anchor" name="index_r">- r -</a></h3><ul>
<li>rlimit_data
: <a class="el" href="qfits__memory_8c.html#a13">qfits_memory.c</a></ul>
</body>
</html>

View File

@ -2,7 +2,7 @@
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>qfits 5.3.1</title>
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
@ -10,12 +10,12 @@
<!-- Generated by Doxygen 1.4.1 -->
<div class="qindex"><a class="qindex" href="globals.html">All</a> | <a class="qindex" href="globals_func.html">Functions</a> | <a class="qindex" href="globals_type.html">Typedefs</a> | <a class="qindexHL" href="globals_enum.html">Enumerations</a> | <a class="qindex" href="globals_eval.html">Enumeration&nbsp;values</a></div>
<div class="qindex"><a class="qindex" href="globals.html">All</a> | <a class="qindex" href="globals_func.html">Functions</a> | <a class="qindex" href="globals_vars.html">Variables</a> | <a class="qindex" href="globals_type.html">Typedefs</a> | <a class="qindexHL" href="globals_enum.html">Enumerations</a> | <a class="qindex" href="globals_eval.html">Enumeration&nbsp;values</a></div>
<p>
<ul>
<li>_TFITS_DATA_TYPE_
: <a class="el" href="qfits_8h.html#a121">qfits.h</a></ul>
<li>_keytype_
: <a class="el" href="qfits__header_8c.html#a56">qfits_header.c</a></ul>
</body>
</html>

View File

@ -2,7 +2,7 @@
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>qfits 5.3.1</title>
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
@ -10,28 +10,46 @@
<!-- Generated by Doxygen 1.4.1 -->
<div class="qindex"><a class="qindex" href="globals.html">All</a> | <a class="qindex" href="globals_func.html">Functions</a> | <a class="qindex" href="globals_type.html">Typedefs</a> | <a class="qindex" href="globals_enum.html">Enumerations</a> | <a class="qindexHL" href="globals_eval.html">Enumeration&nbsp;values</a></div>
<div class="qindex"><a class="qindex" href="globals.html">All</a> | <a class="qindex" href="globals_func.html">Functions</a> | <a class="qindex" href="globals_vars.html">Variables</a> | <a class="qindex" href="globals_type.html">Typedefs</a> | <a class="qindex" href="globals_enum.html">Enumerations</a> | <a class="qindexHL" href="globals_eval.html">Enumeration&nbsp;values</a></div>
<div class="qindex"><a class="qindex" href="#index_k">k</a></div>
<p>
<ul>
<li>TFITS_ASCII_TYPE_A
: <a class="el" href="qfits_8h.html#a121a7">qfits.h</a><li>TFITS_ASCII_TYPE_D
: <a class="el" href="qfits_8h.html#a121a8">qfits.h</a><li>TFITS_ASCII_TYPE_E
: <a class="el" href="qfits_8h.html#a121a9">qfits.h</a><li>TFITS_ASCII_TYPE_F
: <a class="el" href="qfits_8h.html#a121a10">qfits.h</a><li>TFITS_ASCII_TYPE_I
: <a class="el" href="qfits_8h.html#a121a11">qfits.h</a><li>TFITS_BIN_TYPE_A
: <a class="el" href="qfits_8h.html#a121a12">qfits.h</a><li>TFITS_BIN_TYPE_B
: <a class="el" href="qfits_8h.html#a121a13">qfits.h</a><li>TFITS_BIN_TYPE_C
: <a class="el" href="qfits_8h.html#a121a14">qfits.h</a><li>TFITS_BIN_TYPE_D
: <a class="el" href="qfits_8h.html#a121a15">qfits.h</a><li>TFITS_BIN_TYPE_E
: <a class="el" href="qfits_8h.html#a121a16">qfits.h</a><li>TFITS_BIN_TYPE_I
: <a class="el" href="qfits_8h.html#a121a17">qfits.h</a><li>TFITS_BIN_TYPE_J
: <a class="el" href="qfits_8h.html#a121a18">qfits.h</a><li>TFITS_BIN_TYPE_L
: <a class="el" href="qfits_8h.html#a121a19">qfits.h</a><li>TFITS_BIN_TYPE_M
: <a class="el" href="qfits_8h.html#a121a20">qfits.h</a><li>TFITS_BIN_TYPE_P
: <a class="el" href="qfits_8h.html#a121a21">qfits.h</a><li>TFITS_BIN_TYPE_UNKNOWN
: <a class="el" href="qfits_8h.html#a121a23">qfits.h</a><li>TFITS_BIN_TYPE_X
: <a class="el" href="qfits_8h.html#a121a22">qfits.h</a></ul>
<p>
<h3><a class="anchor" name="index_k">- k -</a></h3><ul>
<li>keytype_bitpix
: <a class="el" href="qfits__header_8c.html#a56a4">qfits_header.c</a><li>keytype_bscale
: <a class="el" href="qfits__header_8c.html#a56a15">qfits_header.c</a><li>keytype_bzero
: <a class="el" href="qfits__header_8c.html#a56a16">qfits_header.c</a><li>keytype_comment
: <a class="el" href="qfits__header_8c.html#a56a32">qfits_header.c</a><li>keytype_end
: <a class="el" href="qfits__header_8c.html#a56a33">qfits_header.c</a><li>keytype_extend
: <a class="el" href="qfits__header_8c.html#a56a14">qfits_header.c</a><li>keytype_gcount
: <a class="el" href="qfits__header_8c.html#a56a13">qfits_header.c</a><li>keytype_group
: <a class="el" href="qfits__header_8c.html#a56a11">qfits_header.c</a><li>keytype_hierarch
: <a class="el" href="qfits__header_8c.html#a56a30">qfits_header.c</a><li>keytype_hierarch_det
: <a class="el" href="qfits__header_8c.html#a56a27">qfits_header.c</a><li>keytype_hierarch_dpr
: <a class="el" href="qfits__header_8c.html#a56a21">qfits_header.c</a><li>keytype_hierarch_gen
: <a class="el" href="qfits__header_8c.html#a56a24">qfits_header.c</a><li>keytype_hierarch_ins
: <a class="el" href="qfits__header_8c.html#a56a26">qfits_header.c</a><li>keytype_hierarch_log
: <a class="el" href="qfits__header_8c.html#a56a28">qfits_header.c</a><li>keytype_hierarch_obs
: <a class="el" href="qfits__header_8c.html#a56a22">qfits_header.c</a><li>keytype_hierarch_pro
: <a class="el" href="qfits__header_8c.html#a56a29">qfits_header.c</a><li>keytype_hierarch_tel
: <a class="el" href="qfits__header_8c.html#a56a25">qfits_header.c</a><li>keytype_hierarch_tpl
: <a class="el" href="qfits__header_8c.html#a56a23">qfits_header.c</a><li>keytype_history
: <a class="el" href="qfits__header_8c.html#a56a31">qfits_header.c</a><li>keytype_naxis
: <a class="el" href="qfits__header_8c.html#a56a5">qfits_header.c</a><li>keytype_naxis1
: <a class="el" href="qfits__header_8c.html#a56a6">qfits_header.c</a><li>keytype_naxis2
: <a class="el" href="qfits__header_8c.html#a56a7">qfits_header.c</a><li>keytype_naxis3
: <a class="el" href="qfits__header_8c.html#a56a8">qfits_header.c</a><li>keytype_naxis4
: <a class="el" href="qfits__header_8c.html#a56a9">qfits_header.c</a><li>keytype_naxisi
: <a class="el" href="qfits__header_8c.html#a56a10">qfits_header.c</a><li>keytype_pcount
: <a class="el" href="qfits__header_8c.html#a56a12">qfits_header.c</a><li>keytype_primary
: <a class="el" href="qfits__header_8c.html#a56a20">qfits_header.c</a><li>keytype_tbcoli
: <a class="el" href="qfits__header_8c.html#a56a18">qfits_header.c</a><li>keytype_tfields
: <a class="el" href="qfits__header_8c.html#a56a17">qfits_header.c</a><li>keytype_tformi
: <a class="el" href="qfits__header_8c.html#a56a19">qfits_header.c</a><li>keytype_top
: <a class="el" href="qfits__header_8c.html#a56a3">qfits_header.c</a><li>keytype_undef
: <a class="el" href="qfits__header_8c.html#a56a2">qfits_header.c</a></ul>
</body>
</html>

View File

@ -2,7 +2,7 @@
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>qfits 5.3.1</title>
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
@ -10,117 +10,94 @@
<!-- Generated by Doxygen 1.4.1 -->
<div class="qindex"><a class="qindex" href="globals.html">All</a> | <a class="qindexHL" href="globals_func.html">Functions</a> | <a class="qindex" href="globals_type.html">Typedefs</a> | <a class="qindex" href="globals_enum.html">Enumerations</a> | <a class="qindex" href="globals_eval.html">Enumeration&nbsp;values</a></div>
<div class="qindex"><a class="qindex" href="#index__">_</a> | <a class="qindex" href="#index_i">i</a> | <a class="qindex" href="#index_k">k</a> | <a class="qindex" href="#index_q">q</a></div>
<div class="qindex"><a class="qindex" href="globals.html">All</a> | <a class="qindexHL" href="globals_func.html">Functions</a> | <a class="qindex" href="globals_vars.html">Variables</a> | <a class="qindex" href="globals_type.html">Typedefs</a> | <a class="qindex" href="globals_enum.html">Enumerations</a> | <a class="qindex" href="globals_eval.html">Enumeration&nbsp;values</a></div>
<div class="qindex"><a class="qindex" href="#index_m">m</a> | <a class="qindex" href="#index_q">q</a></div>
<p>
<p>
<h3><a class="anchor" name="index__">- _ -</a></h3><ul>
<li>_qfits_isinfd()
: <a class="el" href="qfits_8h.html#a69">qfits.h</a><li>_qfits_isinff()
: <a class="el" href="qfits_8h.html#a67">qfits.h</a><li>_qfits_isnand()
: <a class="el" href="qfits_8h.html#a68">qfits.h</a><li>_qfits_isnanf()
: <a class="el" href="qfits_8h.html#a66">qfits.h</a></ul>
<h3><a class="anchor" name="index_i">- i -</a></h3><ul>
<li>is_fits_file()
: <a class="el" href="qfits_8h.html#a60">qfits.h</a></ul>
<h3><a class="anchor" name="index_k">- k -</a></h3><ul>
<li>keytuple2str()
: <a class="el" href="qfits_8h.html#a47">qfits.h</a></ul>
<h3><a class="anchor" name="index_m">- m -</a></h3><ul>
<li>main()
: <a class="el" href="qfits__image_8c.html#a11">qfits_image.c</a></ul>
<h3><a class="anchor" name="index_q">- q -</a></h3><ul>
<li>qfits_cache_purge()
: <a class="el" href="qfits_8h.html#a25">qfits.h</a><li>qfits_col_fill()
: <a class="el" href="qfits_8h.html#a108">qfits.h</a><li>qfits_compute_table_width()
: <a class="el" href="qfits_8h.html#a113">qfits.h</a><li>qfits_datamd5()
: <a class="el" href="qfits_8h.html#a51">qfits.h</a><li>qfits_date_now()
: <a class="el" href="qfits_8h.html#a100">qfits.h</a><li>qfits_err_register()
: <a class="el" href="qfits_8h.html#a84">qfits.h</a><li>qfits_err_statget()
: <a class="el" href="qfits_8h.html#a82">qfits.h</a><li>qfits_err_statset()
: <a class="el" href="qfits_8h.html#a83">qfits.h</a><li>qfits_expand_keyword()
: <a class="el" href="qfits_8h.html#a26">qfits.h</a><li>qfits_get_base_name()
: <a class="el" href="qfits_8h.html#a62">qfits.h</a><li>qfits_get_date_iso8601()
: <a class="el" href="qfits_8h.html#a102">qfits.h</a><li>qfits_get_datetime_iso8601()
: <a class="el" href="qfits_8h.html#a103">qfits.h</a><li>qfits_get_datinfo()
: <a class="el" href="qfits_8h.html#a97">qfits.h</a><li>qfits_get_dir_name()
: <a class="el" href="qfits_8h.html#a61">qfits.h</a><li>qfits_get_ext_name()
: <a class="el" href="qfits_8h.html#a64">qfits.h</a><li>qfits_get_hdrinfo()
: <a class="el" href="qfits_8h.html#a96">qfits.h</a><li>qfits_get_login_name()
: <a class="el" href="qfits_8h.html#a65">qfits.h</a><li>qfits_get_root_name()
: <a class="el" href="qfits_8h.html#a63">qfits.h</a><li>qfits_get_type()
: <a class="el" href="qfits_8h.html#a95">qfits.h</a><li>qfits_getcomment()
: <a class="el" href="qfits_8h.html#a54">qfits.h</a><li>qfits_getkey()
: <a class="el" href="qfits_8h.html#a52">qfits.h</a><li>qfits_getvalue()
: <a class="el" href="qfits_8h.html#a53">qfits.h</a><li>qfits_header_add()
: <a class="el" href="qfits_8h.html#a29">qfits.h</a><li>qfits_header_add_after()
: <a class="el" href="qfits_8h.html#a30">qfits.h</a><li>qfits_header_append()
: <a class="el" href="qfits_8h.html#a31">qfits.h</a><li>qfits_header_consoledump()
: <a class="el" href="qfits_8h.html#a37">qfits.h</a><li>qfits_header_copy()
: <a class="el" href="qfits_8h.html#a35">qfits.h</a><li>qfits_header_default()
: <a class="el" href="qfits_8h.html#a28">qfits.h</a><li>qfits_header_del()
: <a class="el" href="qfits_8h.html#a32">qfits.h</a><li>qfits_header_destroy()
: <a class="el" href="qfits_8h.html#a38">qfits.h</a><li>qfits_header_dump()
: <a class="el" href="qfits_8h.html#a48">qfits.h</a><li>qfits_header_dump_hdr()
: <a class="el" href="qfits_8h.html#a49">qfits.h</a><li>qfits_header_findmatch()
: <a class="el" href="qfits_8h.html#a40">qfits.h</a><li>qfits_header_getboolean()
: <a class="el" href="qfits_8h.html#a46">qfits.h</a><li>qfits_header_getcom()
: <a class="el" href="qfits_8h.html#a43">qfits.h</a><li>qfits_header_getdouble()
: <a class="el" href="qfits_8h.html#a45">qfits.h</a><li>qfits_header_getint()
: <a class="el" href="qfits_8h.html#a44">qfits.h</a><li>qfits_header_getitem()
: <a class="el" href="qfits_8h.html#a41">qfits.h</a><li>qfits_header_getline()
: <a class="el" href="qfits_8h.html#a42">qfits.h</a><li>qfits_header_getstr()
: <a class="el" href="qfits_8h.html#a39">qfits.h</a><li>qfits_header_mod()
: <a class="el" href="qfits_8h.html#a33">qfits.h</a><li>qfits_header_new()
: <a class="el" href="qfits_8h.html#a27">qfits.h</a><li>qfits_header_read()
: <a class="el" href="qfits_8h.html#a55">qfits.h</a><li>qfits_header_read_hdr()
: <a class="el" href="qfits_8h.html#a56">qfits.h</a><li>qfits_header_read_hdr_string()
: <a class="el" href="qfits_8h.html#a57">qfits.h</a><li>qfits_header_readext()
: <a class="el" href="qfits_8h.html#a58">qfits.h</a><li>qfits_header_sort()
: <a class="el" href="qfits_8h.html#a34">qfits.h</a><li>qfits_header_to_memblock()
: <a class="el" href="qfits_8h.html#a50">qfits.h</a><li>qfits_header_touchall()
: <a class="el" href="qfits_8h.html#a36">qfits.h</a><li>qfits_is_boolean()
: <a class="el" href="qfits_8h.html#a90">qfits.h</a><li>qfits_is_complex()
: <a class="el" href="qfits_8h.html#a93">qfits.h</a><li>qfits_is_float()
: <a class="el" href="qfits_8h.html#a92">qfits.h</a><li>qfits_is_int()
: <a class="el" href="qfits_8h.html#a91">qfits.h</a><li>qfits_is_paf_file()
: <a class="el" href="qfits_8h.html#a72">qfits.h</a><li>qfits_is_string()
: <a class="el" href="qfits_8h.html#a94">qfits.h</a><li>qfits_is_table()
: <a class="el" href="qfits_8h.html#a104">qfits.h</a><li>qfits_loadpix()
: <a class="el" href="qfits_8h.html#a74">qfits.h</a><li>qfits_paf_print_header()
: <a class="el" href="qfits_8h.html#a70">qfits.h</a><li>qfits_paf_query()
: <a class="el" href="qfits_8h.html#a71">qfits.h</a><li>qfits_pixdump()
: <a class="el" href="qfits_8h.html#a78">qfits.h</a><li>qfits_pixdump_double()
: <a class="el" href="qfits_8h.html#a81">qfits.h</a><li>qfits_pixdump_float()
: <a class="el" href="qfits_8h.html#a79">qfits.h</a><li>qfits_pixdump_int()
: <a class="el" href="qfits_8h.html#a80">qfits.h</a><li>qfits_pixin_double()
: <a class="el" href="qfits_8h.html#a77">qfits.h</a><li>qfits_pixin_float()
: <a class="el" href="qfits_8h.html#a75">qfits.h</a><li>qfits_pixin_int()
: <a class="el" href="qfits_8h.html#a76">qfits.h</a><li>qfits_pretty_string()
: <a class="el" href="qfits_8h.html#a89">qfits.h</a><li>qfits_query_card()
: <a class="el" href="qfits_8h.html#a98">qfits.h</a><li>qfits_query_column()
: <a class="el" href="qfits_8h.html#a111">qfits.h</a><li>qfits_query_column_data()
: <a class="el" href="qfits_8h.html#a114">qfits.h</a><li>qfits_query_column_nulls()
: <a class="el" href="qfits_8h.html#a116">qfits.h</a><li>qfits_query_column_seq()
: <a class="el" href="qfits_8h.html#a112">qfits.h</a><li>qfits_query_column_seq_data()
: <a class="el" href="qfits_8h.html#a115">qfits.h</a><li>qfits_query_ext()
: <a class="el" href="qfits_8h.html#a86">qfits.h</a><li>qfits_query_hdr()
: <a class="el" href="qfits_8h.html#a85">qfits.h</a><li>qfits_query_n_ext()
: <a class="el" href="qfits_8h.html#a87">qfits.h</a><li>qfits_query_nplanes()
: <a class="el" href="qfits_8h.html#a88">qfits.h</a><li>qfits_replace_card()
: <a class="el" href="qfits_8h.html#a99">qfits.h</a><li>qfits_save_table_hdrdump()
: <a class="el" href="qfits_8h.html#a117">qfits.h</a><li>qfits_table_append_xtension()
: <a class="el" href="qfits_8h.html#a118">qfits.h</a><li>qfits_table_append_xtension_hdr()
: <a class="el" href="qfits_8h.html#a119">qfits.h</a><li>qfits_table_close()
: <a class="el" href="qfits_8h.html#a110">qfits.h</a><li>qfits_table_ext_header_default()
: <a class="el" href="qfits_8h.html#a106">qfits.h</a><li>qfits_table_field_to_string()
: <a class="el" href="qfits_8h.html#a120">qfits.h</a><li>qfits_table_new()
: <a class="el" href="qfits_8h.html#a107">qfits.h</a><li>qfits_table_open()
: <a class="el" href="qfits_8h.html#a109">qfits.h</a><li>qfits_table_prim_header_default()
: <a class="el" href="qfits_8h.html#a105">qfits.h</a><li>qfits_time_now()
: <a class="el" href="qfits_8h.html#a101">qfits.h</a><li>qfits_version()
: <a class="el" href="qfits_8h.html#a24">qfits.h</a><li>qfits_zeropad()
: <a class="el" href="qfits_8h.html#a59">qfits.h</a><li>qfitsloader_init()
: <a class="el" href="qfits_8h.html#a73">qfits.h</a></ul>
: <a class="el" href="group__qfits__cache.html#ga0">qfits_cache.c</a><li>qfits_col_fill()
: <a class="el" href="group__qfits__table.html#ga4">qfits_table.c</a><li>qfits_datamd5()
: <a class="el" href="group__qfits__md5.html#ga0">qfits_md5.c</a><li>qfits_get_base_name()
: <a class="el" href="group__qfits__filename.html#ga1">qfits_filename.c</a><li>qfits_get_datetime_iso8601()
: <a class="el" href="group__qfits__time.html#ga0">qfits_time.c</a><li>qfits_get_datinfo()
: <a class="el" href="group__qfits__rw.html#ga7">qfits_rw.c</a><li>qfits_get_dir_name()
: <a class="el" href="group__qfits__filename.html#ga0">qfits_filename.c</a><li>qfits_get_ext_name()
: <a class="el" href="group__qfits__filename.html#ga3">qfits_filename.c</a><li>qfits_get_hdrinfo()
: <a class="el" href="group__qfits__rw.html#ga6">qfits_rw.c</a><li>qfits_get_root_name()
: <a class="el" href="group__qfits__filename.html#ga2">qfits_filename.c</a><li>qfits_get_type()
: <a class="el" href="group__qfits__tools.html#ga10">qfits_tools.c</a><li>qfits_header_add()
: <a class="el" href="group__qfits__header.html#ga2">qfits_header.c</a><li>qfits_header_add_after()
: <a class="el" href="group__qfits__header.html#ga3">qfits_header.c</a><li>qfits_header_append()
: <a class="el" href="group__qfits__header.html#ga4">qfits_header.c</a><li>qfits_header_copy()
: <a class="el" href="group__qfits__header.html#ga8">qfits_header.c</a><li>qfits_header_default()
: <a class="el" href="group__qfits__header.html#ga1">qfits_header.c</a><li>qfits_header_del()
: <a class="el" href="group__qfits__header.html#ga5">qfits_header.c</a><li>qfits_header_destroy()
: <a class="el" href="group__qfits__header.html#ga9">qfits_header.c</a><li>qfits_header_dump()
: <a class="el" href="group__qfits__header.html#ga16">qfits_header.c</a><li>qfits_header_getboolean()
: <a class="el" href="group__qfits__header.html#ga15">qfits_header.c</a><li>qfits_header_getcom()
: <a class="el" href="group__qfits__header.html#ga12">qfits_header.c</a><li>qfits_header_getdouble()
: <a class="el" href="group__qfits__header.html#ga14">qfits_header.c</a><li>qfits_header_getint()
: <a class="el" href="group__qfits__header.html#ga13">qfits_header.c</a><li>qfits_header_getitem()
: <a class="el" href="group__qfits__header.html#ga11">qfits_header.c</a><li>qfits_header_getstr()
: <a class="el" href="group__qfits__header.html#ga10">qfits_header.c</a><li>qfits_header_mod()
: <a class="el" href="group__qfits__header.html#ga6">qfits_header.c</a><li>qfits_header_new()
: <a class="el" href="group__qfits__header.html#ga0">qfits_header.c</a><li>qfits_header_read()
: <a class="el" href="group__qfits__rw.html#ga0">qfits_rw.c</a><li>qfits_header_read_hdr()
: <a class="el" href="group__qfits__rw.html#ga1">qfits_rw.c</a><li>qfits_header_read_hdr_string()
: <a class="el" href="group__qfits__rw.html#ga2">qfits_rw.c</a><li>qfits_header_readext()
: <a class="el" href="group__qfits__rw.html#ga3">qfits_rw.c</a><li>qfits_header_sort()
: <a class="el" href="group__qfits__header.html#ga7">qfits_header.c</a><li>qfits_is_boolean()
: <a class="el" href="group__qfits__tools.html#ga5">qfits_tools.c</a><li>qfits_is_complex()
: <a class="el" href="group__qfits__tools.html#ga8">qfits_tools.c</a><li>qfits_is_fits()
: <a class="el" href="group__qfits__rw.html#ga5">qfits_rw.c</a><li>qfits_is_float()
: <a class="el" href="group__qfits__tools.html#ga7">qfits_tools.c</a><li>qfits_is_int()
: <a class="el" href="group__qfits__tools.html#ga6">qfits_tools.c</a><li>qfits_is_string()
: <a class="el" href="group__qfits__tools.html#ga9">qfits_tools.c</a><li>qfits_is_table()
: <a class="el" href="group__qfits__table.html#ga0">qfits_table.c</a><li>qfits_loadpix()
: <a class="el" href="group__qfits__image.html#ga1">qfits_image.c</a><li>qfits_loadpix_window()
: <a class="el" href="group__qfits__image.html#ga2">qfits_image.c</a><li>qfits_memory_calloc()
: <a class="el" href="group__qfits__memory.html#ga1">qfits_memory.c</a><li>qfits_memory_falloc()
: <a class="el" href="group__qfits__memory.html#ga2">qfits_memory.c</a><li>qfits_memory_fdealloc()
: <a class="el" href="group__qfits__memory.html#ga3">qfits_memory.c</a><li>qfits_memory_free()
: <a class="el" href="group__qfits__memory.html#ga4">qfits_memory.c</a><li>qfits_memory_is_empty()
: <a class="el" href="group__qfits__memory.html#ga8">qfits_memory.c</a><li>qfits_memory_malloc()
: <a class="el" href="group__qfits__memory.html#ga0">qfits_memory.c</a><li>qfits_memory_realloc()
: <a class="el" href="group__qfits__memory.html#ga5">qfits_memory.c</a><li>qfits_memory_status()
: <a class="el" href="group__qfits__memory.html#ga7">qfits_memory.c</a><li>qfits_memory_status_()
: <a class="el" href="qfits__memory_8c.html#a33">qfits_memory.c</a><li>qfits_memory_strdup()
: <a class="el" href="group__qfits__memory.html#ga6">qfits_memory.c</a><li>qfits_pixdump()
: <a class="el" href="group__qfits__image.html#ga3">qfits_image.c</a><li>qfits_pretty_string()
: <a class="el" href="group__qfits__tools.html#ga4">qfits_tools.c</a><li>qfits_query()
: <a class="el" href="group__qfits__cache.html#ga1">qfits_cache.c</a><li>qfits_query_card()
: <a class="el" href="group__qfits__tools.html#ga11">qfits_tools.c</a><li>qfits_query_column()
: <a class="el" href="group__qfits__table.html#ga7">qfits_table.c</a><li>qfits_query_column_data()
: <a class="el" href="group__qfits__table.html#ga9">qfits_table.c</a><li>qfits_query_column_nulls()
: <a class="el" href="group__qfits__table.html#ga11">qfits_table.c</a><li>qfits_query_column_seq()
: <a class="el" href="group__qfits__table.html#ga8">qfits_table.c</a><li>qfits_query_column_seq_data()
: <a class="el" href="group__qfits__table.html#ga10">qfits_table.c</a><li>qfits_query_ext()
: <a class="el" href="group__qfits__tools.html#ga1">qfits_tools.c</a><li>qfits_query_hdr()
: <a class="el" href="group__qfits__tools.html#ga0">qfits_tools.c</a><li>qfits_query_n_ext()
: <a class="el" href="group__qfits__tools.html#ga2">qfits_tools.c</a><li>qfits_query_nplanes()
: <a class="el" href="group__qfits__tools.html#ga3">qfits_tools.c</a><li>qfits_replace_card()
: <a class="el" href="group__qfits__tools.html#ga12">qfits_tools.c</a><li>qfits_save_table_hdrdump()
: <a class="el" href="group__qfits__table.html#ga12">qfits_table.c</a><li>qfits_table_append_xtension()
: <a class="el" href="group__qfits__table.html#ga13">qfits_table.c</a><li>qfits_table_append_xtension_hdr()
: <a class="el" href="group__qfits__table.html#ga14">qfits_table.c</a><li>qfits_table_close()
: <a class="el" href="group__qfits__table.html#ga6">qfits_table.c</a><li>qfits_table_ext_header_default()
: <a class="el" href="group__qfits__table.html#ga2">qfits_table.c</a><li>qfits_table_field_to_string()
: <a class="el" href="group__qfits__table.html#ga15">qfits_table.c</a><li>qfits_table_new()
: <a class="el" href="group__qfits__table.html#ga3">qfits_table.c</a><li>qfits_table_open()
: <a class="el" href="group__qfits__table.html#ga5">qfits_table.c</a><li>qfits_table_prim_header_default()
: <a class="el" href="group__qfits__table.html#ga1">qfits_table.c</a><li>qfits_version()
: <a class="el" href="group__qfits__tools.html#ga13">qfits_tools.c</a><li>qfits_zeropad()
: <a class="el" href="group__qfits__rw.html#ga4">qfits_rw.c</a><li>qfitsloader_init()
: <a class="el" href="group__qfits__image.html#ga0">qfits_image.c</a></ul>
</body>
</html>

View File

@ -2,7 +2,7 @@
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>qfits 5.3.1</title>
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
@ -10,18 +10,14 @@
<!-- Generated by Doxygen 1.4.1 -->
<div class="qindex"><a class="qindex" href="globals.html">All</a> | <a class="qindex" href="globals_func.html">Functions</a> | <a class="qindexHL" href="globals_type.html">Typedefs</a> | <a class="qindex" href="globals_enum.html">Enumerations</a> | <a class="qindex" href="globals_eval.html">Enumeration&nbsp;values</a></div>
<div class="qindex"><a class="qindex" href="globals.html">All</a> | <a class="qindex" href="globals_func.html">Functions</a> | <a class="qindex" href="globals_vars.html">Variables</a> | <a class="qindexHL" href="globals_type.html">Typedefs</a> | <a class="qindex" href="globals_enum.html">Enumerations</a> | <a class="qindex" href="globals_eval.html">Enumeration&nbsp;values</a></div>
<p>
<ul>
<li>byte
: <a class="el" href="qfits_8h.html#a1">qfits.h</a><li>qfits_col
: <a class="el" href="qfits_8h.html#a5">qfits.h</a><li>qfits_header
: <a class="el" href="qfits_8h.html#a0">qfits.h</a><li>qfits_table
: <a class="el" href="qfits_8h.html#a6">qfits.h</a><li>qfitsdumper
: <a class="el" href="qfits_8h.html#a3">qfits.h</a><li>qfitsloader
: <a class="el" href="qfits_8h.html#a2">qfits.h</a><li>tfits_type
: <a class="el" href="qfits_8h.html#a4">qfits.h</a></ul>
<li>keytuple
: <a class="el" href="qfits__header_8c.html#a0">qfits_header.c</a><li>keytype
: <a class="el" href="qfits__header_8c.html#a1">qfits_header.c</a><li>qfits_cache_cell
: <a class="el" href="qfits__cache_8c.html#a0">qfits_cache.c</a></ul>
</body>
</html>

View File

@ -0,0 +1,32 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<div class="qindex"><a class="qindex" href="globals.html">All</a> | <a class="qindex" href="globals_func.html">Functions</a> | <a class="qindexHL" href="globals_vars.html">Variables</a> | <a class="qindex" href="globals_type.html">Typedefs</a> | <a class="qindex" href="globals_enum.html">Enumerations</a> | <a class="qindex" href="globals_eval.html">Enumeration&nbsp;values</a></div>
<p>
<ul>
<li>alloc_max
: <a class="el" href="qfits__memory_8c.html#a6">qfits_memory.c</a><li>alloc_ram
: <a class="el" href="qfits__memory_8c.html#a4">qfits_memory.c</a><li>alloc_swap
: <a class="el" href="qfits__memory_8c.html#a5">qfits_memory.c</a><li>alloc_total
: <a class="el" href="qfits__memory_8c.html#a3">qfits_memory.c</a><li>file_reg
: <a class="el" href="qfits__memory_8c.html#a9">qfits_memory.c</a><li>max_cells
: <a class="el" href="qfits__memory_8c.html#a7">qfits_memory.c</a><li>n_mm_files
: <a class="el" href="qfits__memory_8c.html#a10">qfits_memory.c</a><li>n_mm_mappings
: <a class="el" href="qfits__memory_8c.html#a11">qfits_memory.c</a><li>ncells
: <a class="el" href="qfits__memory_8c.html#a2">qfits_memory.c</a><li>nswapfiles
: <a class="el" href="qfits__memory_8c.html#a8">qfits_memory.c</a><li>pagesize
: <a class="el" href="qfits__memory_8c.html#a12">qfits_memory.c</a><li>rlimit_data
: <a class="el" href="qfits__memory_8c.html#a13">qfits_memory.c</a></ul>
</body>
</html>

View File

@ -0,0 +1,119 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>FITS caching capabilities</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__cache.html#ga0">qfits_cache_purge</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Purge the qfits cache. <a href="#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__cache.html#ga1">qfits_query</a> (const char *filename, int what)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Query a FITS file offset from the cache. <a href="#ga1"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
This modules implements a cache for FITS access routines. The first time a FITS file is seen by the library, all corresponding pointers are cached here. This speeds up multiple accesses to large files by magnitudes. <hr><h2>Function Documentation</h2>
<a class="anchor" name="ga0" doxytag="qfits_cache.c::qfits_cache_purge"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void qfits_cache_purge </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">void&nbsp;</td>
<td class="mdname1" valign="top" nowrap> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Purge the qfits cache.
<p>
<dl compact><dt><b>Returns:</b></dt><dd>void</dd></dl>
This function is useful for programs running for a long period, to clean up the cache. Ideally in a daemon, it should be called by a timer at regular intervals. Notice that since the cache is fairly small, you should not need to care too much about this. </td>
</tr>
</table>
<a class="anchor" name="ga1" doxytag="qfits_cache.c::qfits_query"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_query </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>what</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Query a FITS file offset from the cache.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the file to examine. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>what</em>&nbsp;</td><td>What should be queried (see below). </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>an integer offset, or -1 if an error occurred.</dd></dl>
This function queries the cache for FITS offset information. If the requested file name has never been seen before, it is completely parsed to extract all offset informations, which are then stored in the cache. The next query will get the informations from the cache, avoiding a complete re-parsing of the file. This is especially useful for large FITS files with lots of extensions, because querying the extensions is an expensive operation.<p>
This operation has side-effects: the cache is an automatically allocated structure in memory, that can only grow. Every request on a new FITS file will make it grow. The structure is pretty light-weight in memory, but nonetheless this is an issue for daemon-type programs which must run over long periods. The solution is to clean the cache using <a class="el" href="group__qfits__cache.html#ga0">qfits_cache_purge()</a> at regular intervals. This is left to the user of this library.<p>
To request information about a FITS file, you must pass an integer built from the following symbols:<p>
<ul>
<li><code>QFITS_QUERY_N_EXT</code> </li><li><code>QFITS_QUERY_HDR_START</code> </li><li><code>QFITS_QUERY_DAT_START</code> </li><li><code>QFITS_QUERY_HDR_SIZE</code> </li><li><code>QFITS_QUERY_DAT_SIZE</code> </li></ul>
<p>
Querying the number of extensions present in a file is done simply with:<p>
<div class="fragment"><pre class="fragment"> next = <a class="code" href="group__qfits__cache.html#ga1">qfits_query</a>(filename, QFITS_QUERY_N_EXT);
</pre></div><p>
Querying the offset to the i-th extension header is done with:<p>
<div class="fragment"><pre class="fragment"> off = <a class="code" href="group__qfits__cache.html#ga1">qfits_query</a>(filename, QFITS_QUERY_HDR_START | i);
</pre></div><p>
i.e. you must OR (|) the extension number with the <code>QFITS_QUERY_HDR_START</code> symbol. Requesting offsets to extension data is done in the same way:<p>
<div class="fragment"><pre class="fragment"> off = <a class="code" href="group__qfits__cache.html#ga1">qfits_query</a>(filename, QFITS_QUERY_DAT_START | i);
</pre></div><p>
Notice that extension 0 is the main header and main data part of the FITS file. </td>
</tr>
</table>
</body>
</html>

View File

@ -0,0 +1,218 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>Get various names (filenames, dir names,...)</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__filename.html#ga0">qfits_get_dir_name</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Find the directory name in the given string. <a href="#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__filename.html#ga1">qfits_get_base_name</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Find out the base name of a file (i.e. without prefix path). <a href="#ga1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__filename.html#ga2">qfits_get_root_name</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Find out the root part of a basename (name without extension). <a href="#ga2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__filename.html#ga3">qfits_get_ext_name</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Find out the extension of a file name. <a href="#ga3"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
The following functions are useful to cut out a filename into its components. All functions work with statically allocated memory, i.e. the pointers they return are not permanent but likely to be overwritten at each function call. If you need a returned value later on, you should store it into a local variable.<p>
Example:<p>
<div class="fragment"><pre class="fragment"> <span class="keywordtype">char</span> * s ;
s = <a class="code" href="group__qfits__filename.html#ga0">qfits_get_dir_name</a>(<span class="stringliteral">"/mnt/cdrom/data/image.fits"</span>)
</pre></div><p>
s contains now "/mnt/cdrom/data" but will loose these contents at the next function call. To retain its value, you can either do:<p>
<div class="fragment"><pre class="fragment"> <span class="keywordtype">char</span> s[1024];
strcpy(s, <a class="code" href="group__qfits__filename.html#ga0">qfits_get_dir_name</a>(<span class="stringliteral">"/mnt/cdrom/data/image.fits"</span>));
</pre></div><p>
or:<p>
<div class="fragment"><pre class="fragment"> <span class="keywordtype">char</span> * s;
s = strdup(<a class="code" href="group__qfits__filename.html#ga0">qfits_get_dir_name</a>(<span class="stringliteral">"/mnt/cdrom/data/image.fits"</span>));
...
free(s);
</pre></div> <hr><h2>Function Documentation</h2>
<a class="anchor" name="ga1" doxytag="qfits_filename.c::qfits_get_base_name"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* qfits_get_base_name </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>filename</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Find out the base name of a file (i.e. without prefix path).
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Full path name to scan. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>Pointer to char within the input string.</dd></dl>
Provide a full path name and you get in return a pointer to a statically allocated string containing the name of the file only, without prefixing directory names. If the input string does not contain a slash (i.e. it is not a full path), the returned string is a copy of the input string.<p>
This function does not check for the existence of the path or the file.<p>
Examples: <div class="fragment"><pre class="fragment">
qfits_get_base_name("/cdrom/data/image.fits") returns "image.fits"
qfits_get_base_name("filename.fits") returns "filename.fits"
</pre></div> </td>
</tr>
</table>
<a class="anchor" name="ga0" doxytag="qfits_filename.c::qfits_get_dir_name"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* qfits_get_dir_name </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>filename</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Find the directory name in the given string.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Full path name to scan. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>Pointer to statically allocated string.</dd></dl>
Provide a full path name and you get in return a pointer to a statically allocated string containing the name of the directory only, without trailing slash. If the input string does not contain a slash (i.e. it is not a full path), the returned string is '.', corresponding to the current working directory. Since the returned string is statically allocated, do not try to free it or modify it.<p>
This function does not check for the existence of the path or the file.<p>
Examples: <div class="fragment"><pre class="fragment">
qfits_get_dir_name("/cdrom/data/image.fits") returns "/cdrom/data"
qfits_get_dir_name("filename.fits") returns "."
</pre></div> </td>
</tr>
</table>
<a class="anchor" name="ga3" doxytag="qfits_filename.c::qfits_get_ext_name"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* qfits_get_ext_name </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>filename</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Find out the extension of a file name.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>File name without path prefix. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>Pointer to char within the input string.</dd></dl>
Find out the extension of a given file name. Notice that the input character string must not contain a path prefix (typically, you feed in the output of <code>qfits_get_base_name</code>).<p>
Works with all kinds of extensions: returns the part of the string after the last dot. If no dot is found in the input string, NULL is returned.<p>
Examples: <div class="fragment"><pre class="fragment">
qfits_get_ext_name("filename.fits") returns "fits"
qfits_get_ext_name("hello.c") returns "c"
qfits_get_ext_name("readme") returns NULL
</pre></div> </td>
</tr>
</table>
<a class="anchor" name="ga2" doxytag="qfits_filename.c::qfits_get_root_name"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* qfits_get_root_name </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>filename</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Find out the root part of a basename (name without extension).
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>File name to scan. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>Pointer to statically allocated string.</dd></dl>
Find out the root part of a file name, i.e. the file name without extension. Since in Unix a file name can have several dots, only a number of extensions are supported. This includes:<p>
<ul>
<li>.fits and .FITS</li><li>.tfits and .TFITS</li><li>.paf and .PAF</li><li>.ascii and .ASCII</li><li>.dat and .DAT</li><li>.txt and .TXT</li></ul>
<p>
This function does not check for the existence of the path or the file.<p>
Examples: <div class="fragment"><pre class="fragment">
qfits_get_root_name("/cdrom/filename.fits") returns "/cdrom/filename"
qfits_get_root_name("filename.paf") returns "filename"
qfits_get_root_name("filename") returns "filename"
qfits_get_root_name("filename.ext") returns "filename.ext"
</pre></div><p>
Since the returned string is statically allocated in this module, do not try to free it or modify its contents. </td>
</tr>
</table>
</body>
</html>

View File

@ -0,0 +1,948 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>FITS header handling</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga0">qfits_header_new</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">FITS header constructor. <a href="#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga1">qfits_header_default</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">FITS header default constructor. <a href="#ga1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga2">qfits_header_add</a> (qfits_header *hdr, const char *key, const char *val, const char *com, const char *lin)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Add a new card to a FITS header. <a href="#ga2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga3">qfits_header_add_after</a> (qfits_header *hdr, const char *after, const char *key, const char *val, const char *com, const char *lin)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">add a new card to a FITS header <a href="#ga3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga4">qfits_header_append</a> (qfits_header *hdr, const char *key, const char *val, const char *com, const char *lin)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Append a new card to a FITS header. <a href="#ga4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga5">qfits_header_del</a> (qfits_header *hdr, const char *key)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Delete a card in a FITS header. <a href="#ga5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga6">qfits_header_mod</a> (qfits_header *hdr, const char *key, const char *val, const char *com)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Modifies a FITS card. <a href="#ga6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga7">qfits_header_sort</a> (qfits_header **hdr)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sort a FITS header. <a href="#ga7"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga8">qfits_header_copy</a> (const qfits_header *src)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Copy a FITS header. <a href="#ga8"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga9">qfits_header_destroy</a> (qfits_header *hdr)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">qfits_header destructor <a href="#ga9"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga10">qfits_header_getstr</a> (const qfits_header *hdr, const char *key)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the value associated to a key, as a string. <a href="#ga10"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga11">qfits_header_getitem</a> (const qfits_header *hdr, int idx, char *key, char *val, char *com, char *lin)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the i-th key/val/com/line tuple in a header. <a href="#ga11"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga12">qfits_header_getcom</a> (const qfits_header *hdr, const char *key)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the comment associated to a key, as a string. <a href="#ga12"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga13">qfits_header_getint</a> (const qfits_header *hdr, const char *key, int errval)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the value associated to a key, as an int. <a href="#ga13"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">double&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga14">qfits_header_getdouble</a> (const qfits_header *hdr, const char *key, double errval)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the value associated to a key, as a double. <a href="#ga14"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga15">qfits_header_getboolean</a> (const qfits_header *hdr, const char *key, int errval)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the value associated to a key, as a boolean (int). <a href="#ga15"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga16">qfits_header_dump</a> (const qfits_header *hdr, FILE *out)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Dump a FITS header to an opened file. <a href="#ga16"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
This file contains definition and related methods for the FITS header structure. This structure is meant to remain opaque to the user, who only accesses it through the dedicated functions.<p>
The 'keytuple' type is strictly internal to this module. It describes FITS cards as tuples (key,value,comment,line), where key is always a non-NULL character string, value and comment are allowed to be NULL. 'line' is a string containing the line as it has been read from the input FITS file (raw). It is set to NULL if the card is modified later. This allows in output two options: either reconstruct the FITS lines by printing key = value / comment in a FITS-compliant way, or output the lines as they were found in input, except for the modified ones.<p>
The following functions are associated methods to this data structure:<p>
<ul>
<li>keytuple_new() constructor</li><li>keytuple_del() destructor</li><li>keytuple_dmp() dumps a keytuple to stdout </li></ul>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="ga2" doxytag="qfits_header.c::qfits_header_add"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void qfits_header_add </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">qfits_header *&nbsp;</td>
<td class="mdname" nowrap> <em>hdr</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>key</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>val</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>com</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>lin</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Add a new card to a FITS header.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>hdr</em>&nbsp;</td><td>qfits_header object to modify </td></tr>
<tr><td valign="top"></td><td valign="top"><em>key</em>&nbsp;</td><td>FITS key </td></tr>
<tr><td valign="top"></td><td valign="top"><em>val</em>&nbsp;</td><td>FITS value </td></tr>
<tr><td valign="top"></td><td valign="top"><em>com</em>&nbsp;</td><td>FITS comment </td></tr>
<tr><td valign="top"></td><td valign="top"><em>lin</em>&nbsp;</td><td>FITS original line if exists </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>void</dd></dl>
This function adds a new card into a header, at the one-before-last position, i.e. the entry just before the END entry if it is there. The key must always be a non-NULL string, all other input parameters are allowed to get NULL values. </td>
</tr>
</table>
<a class="anchor" name="ga3" doxytag="qfits_header.c::qfits_header_add_after"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void qfits_header_add_after </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">qfits_header *&nbsp;</td>
<td class="mdname" nowrap> <em>hdr</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>after</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>key</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>val</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>com</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>lin</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
add a new card to a FITS header
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>hdr</em>&nbsp;</td><td>qfits_header object to modify </td></tr>
<tr><td valign="top"></td><td valign="top"><em>after</em>&nbsp;</td><td>Key to specify insertion place </td></tr>
<tr><td valign="top"></td><td valign="top"><em>key</em>&nbsp;</td><td>FITS key </td></tr>
<tr><td valign="top"></td><td valign="top"><em>val</em>&nbsp;</td><td>FITS value </td></tr>
<tr><td valign="top"></td><td valign="top"><em>com</em>&nbsp;</td><td>FITS comment </td></tr>
<tr><td valign="top"></td><td valign="top"><em>lin</em>&nbsp;</td><td>FITS original line if exists </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>void</dd></dl>
Adds a new card to a FITS header, after the specified key. Nothing happens if the specified key is not found in the header. All fields can be NULL, except after and key. </td>
</tr>
</table>
<a class="anchor" name="ga4" doxytag="qfits_header.c::qfits_header_append"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void qfits_header_append </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">qfits_header *&nbsp;</td>
<td class="mdname" nowrap> <em>hdr</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>key</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>val</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>com</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>lin</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Append a new card to a FITS header.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>hdr</em>&nbsp;</td><td>qfits_header object to modify </td></tr>
<tr><td valign="top"></td><td valign="top"><em>key</em>&nbsp;</td><td>FITS key </td></tr>
<tr><td valign="top"></td><td valign="top"><em>val</em>&nbsp;</td><td>FITS value </td></tr>
<tr><td valign="top"></td><td valign="top"><em>com</em>&nbsp;</td><td>FITS comment </td></tr>
<tr><td valign="top"></td><td valign="top"><em>lin</em>&nbsp;</td><td>FITS original line if exists </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>void</dd></dl>
Adds a new card in a FITS header as the last one. All fields can be NULL except key. </td>
</tr>
</table>
<a class="anchor" name="ga8" doxytag="qfits_header.c::qfits_header_copy"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">qfits_header* qfits_header_copy </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const qfits_header *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>src</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Copy a FITS header.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>src</em>&nbsp;</td><td>Header to replicate </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>Pointer to newly allocated qfits_header object.</dd></dl>
Makes a strict copy of all information contained in the source header. The returned header must be freed using qfits_header_destroy. </td>
</tr>
</table>
<a class="anchor" name="ga1" doxytag="qfits_header.c::qfits_header_default"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">qfits_header* qfits_header_default </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">void&nbsp;</td>
<td class="mdname1" valign="top" nowrap> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
FITS header default constructor.
<p>
<dl compact><dt><b>Returns:</b></dt><dd>1 newly allocated qfits_header object.</dd></dl>
This is a secondary constructor for a qfits_header object. It returns an allocated linked-list handler containing two cards: the first one (SIMPLE=T) and the last one (END). </td>
</tr>
</table>
<a class="anchor" name="ga5" doxytag="qfits_header.c::qfits_header_del"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void qfits_header_del </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">qfits_header *&nbsp;</td>
<td class="mdname" nowrap> <em>hdr</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>key</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Delete a card in a FITS header.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>hdr</em>&nbsp;</td><td>qfits_header to modify </td></tr>
<tr><td valign="top"></td><td valign="top"><em>key</em>&nbsp;</td><td>specifies which card to remove </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>void</dd></dl>
Removes a card from a FITS header. The first found card that matches the key is removed. </td>
</tr>
</table>
<a class="anchor" name="ga9" doxytag="qfits_header.c::qfits_header_destroy"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void qfits_header_destroy </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">qfits_header *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>hdr</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
qfits_header destructor
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>hdr</em>&nbsp;</td><td>qfits_header to deallocate </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>void</dd></dl>
Frees all memory associated to a given qfits_header object. </td>
</tr>
</table>
<a class="anchor" name="ga16" doxytag="qfits_header.c::qfits_header_dump"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_header_dump </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const qfits_header *&nbsp;</td>
<td class="mdname" nowrap> <em>hdr</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>FILE *&nbsp;</td>
<td class="mdname" nowrap> <em>out</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Dump a FITS header to an opened file.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>hdr</em>&nbsp;</td><td>FITS header to dump </td></tr>
<tr><td valign="top"></td><td valign="top"><em>out</em>&nbsp;</td><td>Opened file pointer </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0 if Ok, -1 otherwise Dumps a FITS header to an opened file pointer. </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga15" doxytag="qfits_header.c::qfits_header_getboolean"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_header_getboolean </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const qfits_header *&nbsp;</td>
<td class="mdname" nowrap> <em>hdr</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>key</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>errval</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Return the value associated to a key, as a boolean (int).
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>hdr</em>&nbsp;</td><td>qfits_header to parse </td></tr>
<tr><td valign="top"></td><td valign="top"><em>key</em>&nbsp;</td><td>key to find </td></tr>
<tr><td valign="top"></td><td valign="top"><em>errval</em>&nbsp;</td><td>default value to return if nothing is found </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int</dd></dl>
Finds the value associated to the given key and return it as a boolean. Returns errval if no matching key is found or no value is attached. A boolean is here understood as an int taking the value 0 or 1. errval can be set to any other integer value to reflect that nothing was found.<p>
errval is returned if no matching key is found or no value is attached.<p>
A true value is any character string beginning with a 'y' (yes), a 't' (true) or the digit '1'. A false value is any character string beginning with a 'n' (no), a 'f' (false) or the digit '0'. </td>
</tr>
</table>
<a class="anchor" name="ga12" doxytag="qfits_header.c::qfits_header_getcom"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* qfits_header_getcom </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const qfits_header *&nbsp;</td>
<td class="mdname" nowrap> <em>hdr</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>key</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Return the comment associated to a key, as a string.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>hdr</em>&nbsp;</td><td>qfits_header to parse </td></tr>
<tr><td valign="top"></td><td valign="top"><em>key</em>&nbsp;</td><td>key to find </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>pointer to statically allocated string</dd></dl>
Finds the comment associated to the given key and return it as a string. The returned pointer is statically allocated, so do not modify its contents or try to free it.<p>
Returns NULL if no matching key is found or no comment is attached. </td>
</tr>
</table>
<a class="anchor" name="ga14" doxytag="qfits_header.c::qfits_header_getdouble"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">double qfits_header_getdouble </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const qfits_header *&nbsp;</td>
<td class="mdname" nowrap> <em>hdr</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>key</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>double&nbsp;</td>
<td class="mdname" nowrap> <em>errval</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Return the value associated to a key, as a double.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>hdr</em>&nbsp;</td><td>qfits_header to parse </td></tr>
<tr><td valign="top"></td><td valign="top"><em>key</em>&nbsp;</td><td>key to find </td></tr>
<tr><td valign="top"></td><td valign="top"><em>errval</em>&nbsp;</td><td>default value to return if nothing is found </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>double</dd></dl>
Finds the value associated to the given key and return it as a double. Returns errval if no matching key is found or no value is attached. </td>
</tr>
</table>
<a class="anchor" name="ga13" doxytag="qfits_header.c::qfits_header_getint"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_header_getint </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const qfits_header *&nbsp;</td>
<td class="mdname" nowrap> <em>hdr</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>key</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>errval</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Return the value associated to a key, as an int.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>hdr</em>&nbsp;</td><td>qfits_header to parse </td></tr>
<tr><td valign="top"></td><td valign="top"><em>key</em>&nbsp;</td><td>key to find </td></tr>
<tr><td valign="top"></td><td valign="top"><em>errval</em>&nbsp;</td><td>default value to return if nothing is found </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int</dd></dl>
Finds the value associated to the given key and return it as an int. Returns errval if no matching key is found or no value is attached. </td>
</tr>
</table>
<a class="anchor" name="ga11" doxytag="qfits_header.c::qfits_header_getitem"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_header_getitem </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const qfits_header *&nbsp;</td>
<td class="mdname" nowrap> <em>hdr</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>idx</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>char *&nbsp;</td>
<td class="mdname" nowrap> <em>key</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>char *&nbsp;</td>
<td class="mdname" nowrap> <em>val</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>char *&nbsp;</td>
<td class="mdname" nowrap> <em>com</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>char *&nbsp;</td>
<td class="mdname" nowrap> <em>lin</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Return the i-th key/val/com/line tuple in a header.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>hdr</em>&nbsp;</td><td>Header to consider </td></tr>
<tr><td valign="top"></td><td valign="top"><em>idx</em>&nbsp;</td><td>Index of the requested card </td></tr>
<tr><td valign="top"></td><td valign="top"><em>key</em>&nbsp;</td><td>Output key </td></tr>
<tr><td valign="top"></td><td valign="top"><em>val</em>&nbsp;</td><td>Output value </td></tr>
<tr><td valign="top"></td><td valign="top"><em>com</em>&nbsp;</td><td>Output comment </td></tr>
<tr><td valign="top"></td><td valign="top"><em>lin</em>&nbsp;</td><td>Output initial line </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0 if Ok, -1 if error occurred.</dd></dl>
This function is useful to browse a FITS header object card by card. By iterating on the number of cards (available in the 'n' field of the qfits_header struct), you can retrieve the FITS lines and their components one by one. Indexes run from 0 to n-1. You can pass NULL values for key, val, com or lin if you are not interested in a given field.<p>
<div class="fragment"><pre class="fragment"> <span class="keywordtype">int</span> i ;
<span class="keywordtype">char</span> key[FITS_LINESZ+1] ;
<span class="keywordtype">char</span> val[FITS_LINESZ+1] ;
<span class="keywordtype">char</span> com[FITS_LINESZ+1] ;
<span class="keywordtype">char</span> lin[FITS_LINESZ+1] ;
<span class="keywordflow">for</span> (i=0 ; i&lt;hdr-&gt;n ; i++) {
<a class="code" href="group__qfits__header.html#ga11">qfits_header_getitem</a>(hdr, i, key, val, com, lin);
printf(<span class="stringliteral">"card[%d] key[%s] val[%s] com[%s]\n"</span>, i, key, val, com);
}
</pre></div><p>
This function has primarily been written to interface a qfits_header object to other languages (C++/Python). If you are working within a C program, you should use the other header manipulation routines available in this module. </td>
</tr>
</table>
<a class="anchor" name="ga10" doxytag="qfits_header.c::qfits_header_getstr"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* qfits_header_getstr </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const qfits_header *&nbsp;</td>
<td class="mdname" nowrap> <em>hdr</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>key</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Return the value associated to a key, as a string.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>hdr</em>&nbsp;</td><td>qfits_header to parse </td></tr>
<tr><td valign="top"></td><td valign="top"><em>key</em>&nbsp;</td><td>key to find </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>pointer to statically allocated string</dd></dl>
Finds the value associated to the given key and return it as a string. The returned pointer is statically allocated, so do not modify its contents or try to free it.<p>
Returns NULL if no matching key is found or no value is attached. </td>
</tr>
</table>
<a class="anchor" name="ga6" doxytag="qfits_header.c::qfits_header_mod"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void qfits_header_mod </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">qfits_header *&nbsp;</td>
<td class="mdname" nowrap> <em>hdr</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>key</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>val</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>com</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Modifies a FITS card.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>hdr</em>&nbsp;</td><td>qfits_header to modify </td></tr>
<tr><td valign="top"></td><td valign="top"><em>key</em>&nbsp;</td><td>FITS key </td></tr>
<tr><td valign="top"></td><td valign="top"><em>val</em>&nbsp;</td><td>FITS value </td></tr>
<tr><td valign="top"></td><td valign="top"><em>com</em>&nbsp;</td><td>FITS comment </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>void</dd></dl>
Finds the first card in the header matching 'key', and replaces its value and comment fields by the provided values. The initial FITS line is set to NULL in the card. </td>
</tr>
</table>
<a class="anchor" name="ga0" doxytag="qfits_header.c::qfits_header_new"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">qfits_header* qfits_header_new </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">void&nbsp;</td>
<td class="mdname1" valign="top" nowrap> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
FITS header constructor.
<p>
<dl compact><dt><b>Returns:</b></dt><dd>1 newly allocated (empty) qfits_header object.</dd></dl>
This is the main constructor for a qfits_header object. It returns an allocated linked-list handler with an empty card list. </td>
</tr>
</table>
<a class="anchor" name="ga7" doxytag="qfits_header.c::qfits_header_sort"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_header_sort </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">qfits_header **&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>hdr</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Sort a FITS header.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>hdr</em>&nbsp;</td><td>Header to sort (modified) </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>-1 in error case, 0 otherwise </dd></dl>
</td>
</tr>
</table>
</body>
</html>

View File

@ -0,0 +1,225 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>Pixel loader for FITS images.</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__image.html#ga0">qfitsloader_init</a> (qfitsloader *ql)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Initialize a qfitsloader control object. <a href="#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__image.html#ga1">qfits_loadpix</a> (qfitsloader *ql)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Load a pixel buffer for one complete image. <a href="#ga1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__image.html#ga2">qfits_loadpix_window</a> (qfitsloader *ql, int llx, int lly, int urx, int ury)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Load a pixel buffer for one image window. <a href="#ga2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__image.html#ga3">qfits_pixdump</a> (qfitsdumper *qd)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Dump a pixel buffer to an output FITS file in append mode. <a href="#ga3"></a><br></td></tr>
</table>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="ga1" doxytag="qfits_image.c::qfits_loadpix"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_loadpix </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">qfitsloader *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>ql</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Load a pixel buffer for one complete image.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>ql</em>&nbsp;</td><td>Allocated and initialized qfitsloader control object. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0 if Ok, -1 if error occurred. </dd></dl>
<dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__qfits__image.html#ga2">qfits_loadpix_window</a> </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga2" doxytag="qfits_image.c::qfits_loadpix_window"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_loadpix_window </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">qfitsloader *&nbsp;</td>
<td class="mdname" nowrap> <em>ql</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>llx</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>lly</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>urx</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>ury</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Load a pixel buffer for one image window.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>ql</em>&nbsp;</td><td>Allocated and initialized qfitsloader control object. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>llx</em>&nbsp;</td><td></td></tr>
<tr><td valign="top"></td><td valign="top"><em>lly</em>&nbsp;</td><td>Position of the window (start with (1,1)) </td></tr>
<tr><td valign="top"></td><td valign="top"><em>urx</em>&nbsp;</td><td></td></tr>
<tr><td valign="top"></td><td valign="top"><em>ury</em>&nbsp;</td><td></td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0 if Ok, -1 if error occurred.</dd></dl>
This function performs a load of a pixel buffer into memory. It expects an allocated and initialized qfitsloader object in input. See <a class="el" href="group__qfits__image.html#ga0">qfitsloader_init()</a> about initializing the object.<p>
This function will fill up the ibuf/fbuf/dbuf field, depending on the requested pixel type (resp. int, float or double).<p>
If llx lly urx and ury do not specify the whole image, ql-&gt;map must be 0, we do not want to mmap a file an load only a part of it. </td>
</tr>
</table>
<a class="anchor" name="ga3" doxytag="qfits_image.c::qfits_pixdump"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_pixdump </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">qfitsdumper *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>qd</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Dump a pixel buffer to an output FITS file in append mode.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>qd</em>&nbsp;</td><td>qfitsdumper control object. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0 if Ok, -1 otherwise.</dd></dl>
This function takes in input a qfitsdumper control object. This object must be allocated beforehand and contain valid references to the data to save, and how to save it.<p>
The minimum fields to fill are:<p>
<ul>
<li>filename: Name of the FITS file to dump to.</li><li>npix: Number of pixels in the buffer to be dumped.</li><li>ptype: Type of the passed buffer (PTYPE_FLOAT, PTYPE_INT, PTYPE_DOUBLE)</li><li>out_ptype: Requested FITS BITPIX for the output.</li></ul>
<p>
One of the following fields must point to the corresponding pixel buffer:<p>
<ul>
<li>ibuf for an int pixel buffer (ptype=PTYPE_INT)</li><li>fbuf for a float pixel buffer (ptype=PTYPE_FLOAT)</li><li>dbuf for a double pixel buffer (ptype=PTYPE_DOUBLE)</li></ul>
<p>
This is a fairly low-level function, in the sense that it does not check that the output file already contains a proper header or even that the file it is appending to is indeed a FITS file. It will convert the pixel buffer to the requested BITPIX type and append the data to the file, without padding with zeros. See <a class="el" href="group__qfits__rw.html#ga4">qfits_zeropad()</a> about padding.<p>
If the given output file name is "STDOUT" (all caps), the dump will be performed to stdout. </td>
</tr>
</table>
<a class="anchor" name="ga0" doxytag="qfits_image.c::qfitsloader_init"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfitsloader_init </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">qfitsloader *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>ql</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Initialize a qfitsloader control object.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>ql</em>&nbsp;</td><td>qfitsloader object to initialize. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0 if Ok, -1 if error occurred.</dd></dl>
This function expects a qfitsloader object with a number of input fields correctly filled in. The minimum fields to set are:<p>
<ul>
<li>filename: Name of the file to examine.</li><li>xtnum: Extension number to examine (0 for main section).</li><li>pnum: Plane number in the requested extension.</li><li>map : loading mode - flag to know if the file has to be mapped</li></ul>
<p>
You can go ahead with these fields only if you only want to get file information for this plane in this extension. If you want to later load the plane, you must additionally fill the 'ptype' field to a correct value (PTYPE_INT, PTYPE_FLOAT, PTYPE_DOUBLE) before calling <a class="el" href="group__qfits__image.html#ga1">qfits_loadpix()</a> so that it knows which conversion to perform.<p>
This function is basically a probe sent on a FITS file to ask qfits if loading these data would be Ok or not. The actual loading is performed by <a class="el" href="group__qfits__image.html#ga1">qfits_loadpix()</a> afterwards. </td>
</tr>
</table>
</body>
</html>

View File

@ -0,0 +1,61 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>FITS data block MD5 computation routine</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">const char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__md5.html#ga0">qfits_datamd5</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Compute the MD5 hash of data zones in a FITS file. <a href="#ga0"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
This module offers MD5 computation over all data areas of a FITS file. <hr><h2>Function Documentation</h2>
<a class="anchor" name="ga0" doxytag="qfits_md5.c::qfits_datamd5"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">const char* qfits_datamd5 </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>filename</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Compute the MD5 hash of data zones in a FITS file.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the FITS file to examine. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>1 statically allocated character string, or NULL.</dd></dl>
This function expects the name of a FITS file. It will compute the MD5 hash on all data blocks in the main data section and possibly extensions (including zero-padding blocks if necessary) and return it as a string suitable for inclusion into a FITS keyword.<p>
The returned string is statically allocated inside this function, so do not free it or modify it. This function returns NULL in case of error. </td>
</tr>
</table>
</body>
</html>

View File

@ -0,0 +1,534 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>POSIX-compatible extended memory handling</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga0">qfits_memory_malloc</a> (size_t size, const char *filename, int lineno)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Allocate memory. <a href="#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga1">qfits_memory_calloc</a> (size_t nmemb, size_t size, const char *filename, int lineno)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Allocate memory. <a href="#ga1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga2">qfits_memory_falloc</a> (char *name, size_t offs, size_t *size, const char *srcname, int srclin)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Map a file's contents to memory as a char pointer. <a href="#ga2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga3">qfits_memory_fdealloc</a> (void *ptr, size_t offs, size_t size, const char *filename, int lineno)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Free memory that has been allocated with falloc. <a href="#ga3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga4">qfits_memory_free</a> (void *ptr, const char *filename, int lineno)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Free memory. <a href="#ga4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga5">qfits_memory_realloc</a> (void *ptr, size_t size, const char *filename, int lineno)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Re-Allocate memory. <a href="#ga5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga6">qfits_memory_strdup</a> (const char *s, const char *filename, int lineno)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Duplicate a string using calloc. <a href="#ga6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga7">qfits_memory_status</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Display memory status information. <a href="#ga7"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga8">qfits_memory_is_empty</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Tell if there is still some memory allocated. <a href="#ga8"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
qfits_memory is a small and efficient module offering memory extension capabitilies to ANSI C programs running on POSIX-compliant systems. It offers several useful features such as memory leak detection, protection for free on NULL or unallocated pointers, and virtually unlimited memory space. qfits_memory requires the <code>mmap()</code> system call to be implemented in the local C library to function. This module has been tested on a number of current Unix * flavours and is reported to work fine. The current limitation is the limited number of pointers it can handle at the same time. <hr><h2>Function Documentation</h2>
<a class="anchor" name="ga1" doxytag="qfits_memory.c::qfits_memory_calloc"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void* qfits_memory_calloc </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">size_t&nbsp;</td>
<td class="mdname" nowrap> <em>nmemb</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>size_t&nbsp;</td>
<td class="mdname" nowrap> <em>size</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>lineno</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Allocate memory.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>nmemb</em>&nbsp;</td><td>Number of elements to allocate. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>size</em>&nbsp;</td><td>Size (in bytes) of each element. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the file where the alloc took place. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>lineno</em>&nbsp;</td><td>Line number in the file. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>1 newly allocated pointer.</dd></dl>
This function is a replacement call for calloc. It should never be called directly but through a macro instead, as:<p>
<div class="fragment"><pre class="fragment"> <a class="code" href="group__qfits__memory.html#ga1">qfits_memory_calloc</a>(nmemb, size, __FILE__, __LINE__)
</pre></div> </td>
</tr>
</table>
<a class="anchor" name="ga2" doxytag="qfits_memory.c::qfits_memory_falloc"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* qfits_memory_falloc </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">char *&nbsp;</td>
<td class="mdname" nowrap> <em>name</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>size_t&nbsp;</td>
<td class="mdname" nowrap> <em>offs</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>size_t *&nbsp;</td>
<td class="mdname" nowrap> <em>size</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>srcname</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>srclin</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Map a file's contents to memory as a char pointer.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>name</em>&nbsp;</td><td>Name of the file to map </td></tr>
<tr><td valign="top"></td><td valign="top"><em>offs</em>&nbsp;</td><td>Offset to the first mapped byte in file. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>size</em>&nbsp;</td><td>Returned size of the mapped file in bytes. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>srcname</em>&nbsp;</td><td>Name of the source file making the call. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>srclin</em>&nbsp;</td><td>Line # where the call was made. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>A pointer to char, to be freed using <a class="el" href="group__qfits__memory.html#ga4">qfits_memory_free()</a>.</dd></dl>
This function takes in input the name of a file. It tries to map the file into memory and if it succeeds, returns the file's contents as a char pointer. It also modifies the input size variable to be the size of the mapped file in bytes. This function is normally never directly called but through the falloc() macro.<p>
The offset indicates the starting point for the mapping, i.e. if you are not interested in mapping the whole file but only from a given place.<p>
The returned pointer ptr must be deallocated with qfits_memory_fdealloc(ptr) </td>
</tr>
</table>
<a class="anchor" name="ga3" doxytag="qfits_memory.c::qfits_memory_fdealloc"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void qfits_memory_fdealloc </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">void *&nbsp;</td>
<td class="mdname" nowrap> <em>ptr</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>size_t&nbsp;</td>
<td class="mdname" nowrap> <em>offs</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>size_t&nbsp;</td>
<td class="mdname" nowrap> <em>size</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>lineno</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Free memory that has been allocated with falloc.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>ptr</em>&nbsp;</td><td>Pointer to free. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>offs</em>&nbsp;</td><td>Offset to the first mapped byte in file. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>size</em>&nbsp;</td><td>size to unmap </td></tr>
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the file where the dealloc took place. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>lineno</em>&nbsp;</td><td>Line number in the file. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>void </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga4" doxytag="qfits_memory.c::qfits_memory_free"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void qfits_memory_free </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">void *&nbsp;</td>
<td class="mdname" nowrap> <em>ptr</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>lineno</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Free memory.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>ptr</em>&nbsp;</td><td>Pointer to free. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the file where the dealloc took place. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>lineno</em>&nbsp;</td><td>Line number in the file. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>void</dd></dl>
Free the memory associated to a given pointer. Prints out a warning on stderr if the requested pointer is NULL or cannot be found in the extended memory table. </td>
</tr>
</table>
<a class="anchor" name="ga8" doxytag="qfits_memory.c::qfits_memory_is_empty"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_memory_is_empty </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">void&nbsp;</td>
<td class="mdname1" valign="top" nowrap> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Tell if there is still some memory allocated.
<p>
<dl compact><dt><b>Returns:</b></dt><dd>1 if the memory table is tempty, 0 if no, -1 if the memory model is off </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga0" doxytag="qfits_memory.c::qfits_memory_malloc"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void* qfits_memory_malloc </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">size_t&nbsp;</td>
<td class="mdname" nowrap> <em>size</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>lineno</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Allocate memory.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>size</em>&nbsp;</td><td>Size (in bytes) to allocate. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the file where the alloc took place. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>lineno</em>&nbsp;</td><td>Line number in the file. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>1 newly allocated pointer.</dd></dl>
This function is a replacement call for malloc. It should never be called directly but through a macro instead, as:<p>
<div class="fragment"><pre class="fragment"> <a class="code" href="group__qfits__memory.html#ga0">qfits_memory_malloc</a>(size, __FILE__, __LINE__)
</pre></div> </td>
</tr>
</table>
<a class="anchor" name="ga5" doxytag="qfits_memory.c::qfits_memory_realloc"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void* qfits_memory_realloc </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">void *&nbsp;</td>
<td class="mdname" nowrap> <em>ptr</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>size_t&nbsp;</td>
<td class="mdname" nowrap> <em>size</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>lineno</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Re-Allocate memory.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>ptr</em>&nbsp;</td><td>Pointer to free. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>size</em>&nbsp;</td><td>Size (in bytes) to allocate. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the file where the alloc took place. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>lineno</em>&nbsp;</td><td>Line number in the file. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>1 newly allocated pointer.</dd></dl>
This function is a replacement call for realloc. It should never be called directly but through a macro instead, as:<p>
<div class="fragment"><pre class="fragment"> <a class="code" href="group__qfits__memory.html#ga5">qfits_memory_realloc</a>(nmemb, size, __FILE__, __LINE__)
</pre></div> </td>
</tr>
</table>
<a class="anchor" name="ga7" doxytag="qfits_memory.c::qfits_memory_status"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void qfits_memory_status </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">void&nbsp;</td>
<td class="mdname1" valign="top" nowrap> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Display memory status information.
<p>
<dl compact><dt><b>Returns:</b></dt><dd>void</dd></dl>
This function is meant for debugging purposes, but it is recommended to call it at the end of every executable making use of the extended memory features. </td>
</tr>
</table>
<a class="anchor" name="ga6" doxytag="qfits_memory.c::qfits_memory_strdup"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* qfits_memory_strdup </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname" nowrap> <em>s</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>lineno</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Duplicate a string using calloc.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>s</em>&nbsp;</td><td>String to duplicate. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the file where the call took place. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>lineno</em>&nbsp;</td><td>Line number in the file. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>1 newly allocated character string.</dd></dl>
This function calls in turn calloc to perform the allocation. It should never be called directly but only through a macro, like:<p>
<div class="fragment"><pre class="fragment"> <a class="code" href="group__qfits__memory.html#ga6">qfits_memory_strdup</a>(s, __FILE__, __LINE__)
</pre></div><p>
This function calls <a class="el" href="group__qfits__memory.html#ga0">qfits_memory_malloc()</a> to do the allocation. </td>
</tr>
</table>
</body>
</html>

View File

@ -0,0 +1,408 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>FITS header reading/writing</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__rw.html#ga0">qfits_header_read</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Read a FITS header from a file to an internal structure. <a href="#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__rw.html#ga1">qfits_header_read_hdr</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Read a FITS header from a 'hdr' file. <a href="#ga1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__rw.html#ga2">qfits_header_read_hdr_string</a> (const unsigned char *hdr_str, int nb_char)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Read a FITS header from a 'hdr' string. <a href="#ga2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__rw.html#ga3">qfits_header_readext</a> (const char *filename, int xtnum)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Read an extension header from a FITS file. <a href="#ga3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__rw.html#ga4">qfits_zeropad</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Pad an existing file with zeros to a multiple of 2880. <a href="#ga4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__rw.html#ga5">qfits_is_fits</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Identify if a file is a FITS file. <a href="#ga5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__rw.html#ga6">qfits_get_hdrinfo</a> (const char *filename, int xtnum, int *seg_start, int *seg_size)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Retrieve offset to start and size of a header in a FITS file. <a href="#ga6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__rw.html#ga7">qfits_get_datinfo</a> (const char *filename, int xtnum, int *seg_start, int *seg_size)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Retrieve offset to start and size of a data section in a file. <a href="#ga7"></a><br></td></tr>
</table>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="ga7" doxytag="qfits_rw.c::qfits_get_datinfo"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_get_datinfo </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>xtnum</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int *&nbsp;</td>
<td class="mdname" nowrap> <em>seg_start</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int *&nbsp;</td>
<td class="mdname" nowrap> <em>seg_size</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Retrieve offset to start and size of a data section in a file.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the file to examine. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>xtnum</em>&nbsp;</td><td>Extension number (0 for main). </td></tr>
<tr><td valign="top"></td><td valign="top"><em>seg_start</em>&nbsp;</td><td>Segment start in bytes (output). </td></tr>
<tr><td valign="top"></td><td valign="top"><em>seg_size</em>&nbsp;</td><td>Segment size in bytes (output). </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0 if Ok, -1 otherwise.</dd></dl>
This function retrieves the two most important informations about a data section in a FITS file: the offset to its beginning, and the size of the section in bytes. Both values are returned in the passed pointers to ints. It is Ok to pass NULL for any pointer if you do not want to retrieve the associated value.<p>
You must provide an extension number for the header, 0 meaning the main header in the file. </td>
</tr>
</table>
<a class="anchor" name="ga6" doxytag="qfits_rw.c::qfits_get_hdrinfo"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_get_hdrinfo </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>xtnum</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int *&nbsp;</td>
<td class="mdname" nowrap> <em>seg_start</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int *&nbsp;</td>
<td class="mdname" nowrap> <em>seg_size</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Retrieve offset to start and size of a header in a FITS file.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the file to examine </td></tr>
<tr><td valign="top"></td><td valign="top"><em>xtnum</em>&nbsp;</td><td>Extension number (0 for main) </td></tr>
<tr><td valign="top"></td><td valign="top"><em>seg_start</em>&nbsp;</td><td>Segment start in bytes (output) </td></tr>
<tr><td valign="top"></td><td valign="top"><em>seg_size</em>&nbsp;</td><td>Segment size in bytes (output) </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0 if Ok, -1 otherwise.</dd></dl>
This function retrieves the two most important informations about a header in a FITS file: the offset to its beginning, and the size of the header in bytes. Both values are returned in the passed pointers to ints. It is Ok to pass NULL for any pointer if you do not want to retrieve the associated value.<p>
You must provide an extension number for the header, 0 meaning the main header in the file. </td>
</tr>
</table>
<a class="anchor" name="ga0" doxytag="qfits_rw.c::qfits_header_read"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">qfits_header* qfits_header_read </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>filename</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Read a FITS header from a file to an internal structure.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the file to be read </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>Pointer to newly allocated qfits_header or NULL in error case.</dd></dl>
This function parses a FITS (main) header, and returns an allocated qfits_header object. The qfits_header object contains a linked-list of key "tuples". A key tuple contains:<p>
<ul>
<li>A keyword</li><li>A value</li><li>A comment</li><li>An original FITS line (as read from the input file)</li></ul>
<p>
Direct access to the structure is not foreseen, use accessor functions in fits_h.h<p>
Value, comment, and original line might be NULL pointers. </td>
</tr>
</table>
<a class="anchor" name="ga1" doxytag="qfits_rw.c::qfits_header_read_hdr"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">qfits_header* qfits_header_read_hdr </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>filename</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Read a FITS header from a 'hdr' file.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the file to be read </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>Pointer to newly allocated qfits_header or NULL in error case</dd></dl>
This function parses a 'hdr' file, and returns an allocated qfits_header object. A hdr file is an ASCII format were the header is written with a carriage return after each line. The command dfits typically displays a hdr file. </td>
</tr>
</table>
<a class="anchor" name="ga2" doxytag="qfits_rw.c::qfits_header_read_hdr_string"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">qfits_header* qfits_header_read_hdr_string </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const unsigned char *&nbsp;</td>
<td class="mdname" nowrap> <em>hdr_str</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>nb_char</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Read a FITS header from a 'hdr' string.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>hdr_str</em>&nbsp;</td><td>String containing the hdr file </td></tr>
<tr><td valign="top"></td><td valign="top"><em>nb_char</em>&nbsp;</td><td>Number of characters in the string </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>Pointer to newly allocated qfits_header or NULL in error case</dd></dl>
This function parses a 'hdr' string, and returns an allocated qfits_header object. </td>
</tr>
</table>
<a class="anchor" name="ga3" doxytag="qfits_rw.c::qfits_header_readext"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">qfits_header* qfits_header_readext </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>xtnum</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Read an extension header from a FITS file.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the FITS file to read </td></tr>
<tr><td valign="top"></td><td valign="top"><em>xtnum</em>&nbsp;</td><td>Extension number to read, starting from 0. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>Newly allocated qfits_header structure.</dd></dl>
Strictly similar to <a class="el" href="group__qfits__rw.html#ga0">qfits_header_read()</a> but reads headers from extensions instead. If the requested xtension is 0, this function returns the main header.<p>
Returns NULL in case of error. </td>
</tr>
</table>
<a class="anchor" name="ga5" doxytag="qfits_rw.c::qfits_is_fits"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_is_fits </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>filename</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Identify if a file is a FITS file.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>name of the file to check </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0, 1, or -1</dd></dl>
Returns 1 if the file name looks like a valid FITS file. Returns 0 else. If the file does not exist, returns -1. </td>
</tr>
</table>
<a class="anchor" name="ga4" doxytag="qfits_rw.c::qfits_zeropad"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void qfits_zeropad </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>filename</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Pad an existing file with zeros to a multiple of 2880.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the file to pad. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>void</dd></dl>
This function simply pads an existing file on disk with enough zeros for the file size to reach a multiple of 2880, as required by FITS. </td>
</tr>
</table>
</body>
</html>

View File

@ -0,0 +1,995 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>FITS table handling</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga0">qfits_is_table</a> (const char *filename, int xtnum)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Identify a file as containing a FITS table in extension. <a href="#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga1">qfits_table_prim_header_default</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Generate a default primary header to store tables. <a href="#ga1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga2">qfits_table_ext_header_default</a> (const qfits_table *t)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Generate a default extension header to store tables. <a href="#ga2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_table *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga3">qfits_table_new</a> (const char *filename, int table_type, int table_width, int nb_cols, int nb_raws)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Table object constructor. <a href="#ga3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga4">qfits_col_fill</a> (qfits_col *qc, int atom_nb, int atom_dec_nb, int atom_size, tfits_type atom_type, const char *label, const char *unit, const char *nullval, const char *disp, int zero_present, float zero, int scale_present, float scale, int offset_beg)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Fill a column object with some provided informations. <a href="#ga4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_table *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga5">qfits_table_open</a> (const char *filename, int xtnum)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Read a FITS extension. <a href="#ga5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga6">qfits_table_close</a> (qfits_table *t)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Free a FITS table and associated pointers. <a href="#ga6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">unsigned char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga7">qfits_query_column</a> (const qfits_table *th, int colnum, const int *selection)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Extract data from a column in a FITS table. <a href="#ga7"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">unsigned char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga8">qfits_query_column_seq</a> (const qfits_table *th, int colnum, int start_ind, int nb_rows)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Extract consequtive values from a column in a FITS table. <a href="#ga8"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga9">qfits_query_column_data</a> (const qfits_table *th, int colnum, const int *selection, const void *null_value)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Extract binary data from a column in a FITS table. <a href="#ga9"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga10">qfits_query_column_seq_data</a> (const qfits_table *th, int colnum, int start_ind, int nb_rows, const void *null_value)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Extract binary data from a column in a FITS table. <a href="#ga10"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga11">qfits_query_column_nulls</a> (const qfits_table *th, int colnum, const int *selection, int *nb_vals, int *nb_nulls)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Detect NULL values in a column. <a href="#ga11"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga12">qfits_save_table_hdrdump</a> (const void **array, const qfits_table *table, const qfits_header *fh)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Save a table to a FITS file with a given FITS header. <a href="#ga12"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga13">qfits_table_append_xtension</a> (FILE *outfile, const qfits_table *t, const void **data)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Appends a std extension header + data to a FITS table file. <a href="#ga13"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga14">qfits_table_append_xtension_hdr</a> (FILE *outfile, const qfits_table *t, const void **data, const qfits_header *hdr)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Appends a specified extension header + data to a FITS table file. <a href="#ga14"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga15">qfits_table_field_to_string</a> (const qfits_table *table, int col_id, int row_id, int use_zero_scale)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">given a col and a row, find out the string to write for display <a href="#ga15"></a><br></td></tr>
</table>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="ga4" doxytag="qfits_table.c::qfits_col_fill"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_col_fill </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">qfits_col *&nbsp;</td>
<td class="mdname" nowrap> <em>qc</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>atom_nb</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>atom_dec_nb</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>atom_size</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>tfits_type&nbsp;</td>
<td class="mdname" nowrap> <em>atom_type</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>label</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>unit</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>nullval</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>disp</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>zero_present</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>float&nbsp;</td>
<td class="mdname" nowrap> <em>zero</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>scale_present</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>float&nbsp;</td>
<td class="mdname" nowrap> <em>scale</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>offset_beg</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Fill a column object with some provided informations.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>qc</em>&nbsp;</td><td>Pointer to the column that has to be filled </td></tr>
<tr><td valign="top"></td><td valign="top"><em>unit</em>&nbsp;</td><td>Unit of the data </td></tr>
<tr><td valign="top"></td><td valign="top"><em>label</em>&nbsp;</td><td>Label of the column </td></tr>
<tr><td valign="top"></td><td valign="top"><em>disp</em>&nbsp;</td><td>Way to display the data </td></tr>
<tr><td valign="top"></td><td valign="top"><em>nullval</em>&nbsp;</td><td>Null value </td></tr>
<tr><td valign="top"></td><td valign="top"><em>atom_nb</em>&nbsp;</td><td>Number of atoms per field. According to the type, an atom is a double, an int, a char, ... </td></tr>
<tr><td valign="top"></td><td valign="top"><em>atom_dec_nb</em>&nbsp;</td><td>Number of decimals as specified in TFORM </td></tr>
<tr><td valign="top"></td><td valign="top"><em>atom_size</em>&nbsp;</td><td>Size in bytes of the field for ASCII tables, and of an atom for BIN tables. ASCII tables only contain 1 atom per field (except for A type where you can of course have more than one char per field) </td></tr>
<tr><td valign="top"></td><td valign="top"><em>atom_type</em>&nbsp;</td><td>Type of data (11 types for BIN, 5 for ASCII) </td></tr>
<tr><td valign="top"></td><td valign="top"><em>zero_present</em>&nbsp;</td><td>Flag to use or not zero </td></tr>
<tr><td valign="top"></td><td valign="top"><em>zero</em>&nbsp;</td><td>Zero value </td></tr>
<tr><td valign="top"></td><td valign="top"><em>scale_present</em>&nbsp;</td><td>Flag to use or not scale </td></tr>
<tr><td valign="top"></td><td valign="top"><em>scale</em>&nbsp;</td><td>Scale value </td></tr>
<tr><td valign="top"></td><td valign="top"><em>offset_beg</em>&nbsp;</td><td>Gives the position of the column </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>-1 in error case, 0 otherwise </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga0" doxytag="qfits_table.c::qfits_is_table"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_is_table </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>xtnum</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Identify a file as containing a FITS table in extension.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the FITS file to examine. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>xtnum</em>&nbsp;</td><td>Extension number to check (starting from 1). </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 1 if the extension contains a table, 0 else. Examines the requested extension and identifies the presence of a FITS table. </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga7" doxytag="qfits_table.c::qfits_query_column"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">unsigned char* qfits_query_column </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const qfits_table *&nbsp;</td>
<td class="mdname" nowrap> <em>th</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>colnum</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const int *&nbsp;</td>
<td class="mdname" nowrap> <em>selection</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Extract data from a column in a FITS table.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>th</em>&nbsp;</td><td>Allocated qfits_table </td></tr>
<tr><td valign="top"></td><td valign="top"><em>colnum</em>&nbsp;</td><td>Number of the column to extract (from 0 to colnum-1) </td></tr>
<tr><td valign="top"></td><td valign="top"><em>selection</em>&nbsp;</td><td>boolean array to define the selected rows </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>unsigned char array</dd></dl>
If selection is NULL, select the complete column.<p>
Extract a column from a FITS table and return the data as a bytes array. The returned array type and size are determined by the column object in the qfits_table and by the selection parameter.<p>
Returned array size in bytes is: nbselected * col-&gt;natoms * col-&gt;atom_size<p>
Numeric types are correctly understood and byte-swapped if needed, to be converted to the local machine type.<p>
NULL values have to be handled by the caller.<p>
The returned object must be deallocated with qfits_free(). </td>
</tr>
</table>
<a class="anchor" name="ga9" doxytag="qfits_table.c::qfits_query_column_data"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void* qfits_query_column_data </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const qfits_table *&nbsp;</td>
<td class="mdname" nowrap> <em>th</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>colnum</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const int *&nbsp;</td>
<td class="mdname" nowrap> <em>selection</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const void *&nbsp;</td>
<td class="mdname" nowrap> <em>null_value</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Extract binary data from a column in a FITS table.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>th</em>&nbsp;</td><td>Allocated qfits_table </td></tr>
<tr><td valign="top"></td><td valign="top"><em>colnum</em>&nbsp;</td><td>Number of the column to extract (from 0 to colnum-1) </td></tr>
<tr><td valign="top"></td><td valign="top"><em>selection</em>&nbsp;</td><td>bollean array to identify selected rows </td></tr>
<tr><td valign="top"></td><td valign="top"><em>null_value</em>&nbsp;</td><td>Value to return when a NULL value comes </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>Pointer to void *</dd></dl>
Extract a column from a FITS table and return the data as a generic void* array. The returned array type and size are determined by the column object in the qfits_table.<p>
Returned array size in bytes is: nb_selected * col-&gt;atom_nb * col-&gt;atom_size<p>
NULL values are recognized and replaced by the specified value. The returned object must be deallocated with qfits_free(). </td>
</tr>
</table>
<a class="anchor" name="ga11" doxytag="qfits_table.c::qfits_query_column_nulls"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int* qfits_query_column_nulls </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const qfits_table *&nbsp;</td>
<td class="mdname" nowrap> <em>th</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>colnum</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const int *&nbsp;</td>
<td class="mdname" nowrap> <em>selection</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int *&nbsp;</td>
<td class="mdname" nowrap> <em>nb_vals</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int *&nbsp;</td>
<td class="mdname" nowrap> <em>nb_nulls</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Detect NULL values in a column.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>th</em>&nbsp;</td><td>Allocated qfits_table </td></tr>
<tr><td valign="top"></td><td valign="top"><em>colnum</em>&nbsp;</td><td>Number of the column to check (from 0 to colnum-1) </td></tr>
<tr><td valign="top"></td><td valign="top"><em>selection</em>&nbsp;</td><td>Array to identify selected rows </td></tr>
<tr><td valign="top"></td><td valign="top"><em>nb_vals</em>&nbsp;</td><td>Gives the size of the output array </td></tr>
<tr><td valign="top"></td><td valign="top"><em>nb_nulls</em>&nbsp;</td><td>Gives the number of detected null values </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>array with 1 for NULLs and 0 for non-NULLs The returned object must be deallocated with qfits_free(). </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga8" doxytag="qfits_table.c::qfits_query_column_seq"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">unsigned char* qfits_query_column_seq </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const qfits_table *&nbsp;</td>
<td class="mdname" nowrap> <em>th</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>colnum</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>start_ind</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>nb_rows</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Extract consequtive values from a column in a FITS table.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>th</em>&nbsp;</td><td>Allocated qfits_table </td></tr>
<tr><td valign="top"></td><td valign="top"><em>colnum</em>&nbsp;</td><td>Number of the column to extract (from 0 to colnum-1) </td></tr>
<tr><td valign="top"></td><td valign="top"><em>start_ind</em>&nbsp;</td><td>Index of the first row (0 for the first) </td></tr>
<tr><td valign="top"></td><td valign="top"><em>nb_rows</em>&nbsp;</td><td>Number of rows to extract </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>unsigned char array Does the same as <a class="el" href="group__qfits__table.html#ga7">qfits_query_column()</a> but on a consequtive sequence of rows Spares the overhead of the selection object allocation The returned object must be deallocated with qfits_free(). </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga10" doxytag="qfits_table.c::qfits_query_column_seq_data"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void* qfits_query_column_seq_data </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const qfits_table *&nbsp;</td>
<td class="mdname" nowrap> <em>th</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>colnum</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>start_ind</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>nb_rows</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const void *&nbsp;</td>
<td class="mdname" nowrap> <em>null_value</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Extract binary data from a column in a FITS table.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>th</em>&nbsp;</td><td>Allocated qfits_table </td></tr>
<tr><td valign="top"></td><td valign="top"><em>colnum</em>&nbsp;</td><td>Number of the column to extract (from 0 to colnum-1) </td></tr>
<tr><td valign="top"></td><td valign="top"><em>start_ind</em>&nbsp;</td><td>Index of the first row (0 for the first) </td></tr>
<tr><td valign="top"></td><td valign="top"><em>nb_rows</em>&nbsp;</td><td>Number of rows to extract </td></tr>
<tr><td valign="top"></td><td valign="top"><em>null_value</em>&nbsp;</td><td>Value to return when a NULL value comes </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>Pointer to void * Does the same as <a class="el" href="group__qfits__table.html#ga9">qfits_query_column_data()</a> but on a consequtive sequence of rows. Spares the overhead of the selection object allocation The returned object must be deallocated with qfits_free(). </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga12" doxytag="qfits_table.c::qfits_save_table_hdrdump"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_save_table_hdrdump </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const void **&nbsp;</td>
<td class="mdname" nowrap> <em>array</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const qfits_table *&nbsp;</td>
<td class="mdname" nowrap> <em>table</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const qfits_header *&nbsp;</td>
<td class="mdname" nowrap> <em>fh</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Save a table to a FITS file with a given FITS header.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>array</em>&nbsp;</td><td>Data array. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>table</em>&nbsp;</td><td>table </td></tr>
<tr><td valign="top"></td><td valign="top"><em>fh</em>&nbsp;</td><td>FITS header to insert in the output file. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>-1 in error case, 0 otherwise </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga13" doxytag="qfits_table.c::qfits_table_append_xtension"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_table_append_xtension </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">FILE *&nbsp;</td>
<td class="mdname" nowrap> <em>outfile</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const qfits_table *&nbsp;</td>
<td class="mdname" nowrap> <em>t</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const void **&nbsp;</td>
<td class="mdname" nowrap> <em>data</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Appends a std extension header + data to a FITS table file.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>outfile</em>&nbsp;</td><td>Pointer to (opened) file ready for writing. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>t</em>&nbsp;</td><td>Pointer to qfits_table </td></tr>
<tr><td valign="top"></td><td valign="top"><em>data</em>&nbsp;</td><td>Table data to write </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0 if Ok, -1 otherwise</dd></dl>
Dumps a FITS table to a file. The whole table described by qfits_table, and the data arrays contained in 'data' are dumped to the file. An extension header is produced with all keywords needed to describe the table, then the data is dumped to the file. The output is then padded to reach a multiple of 2880 bytes in size. Notice that no main header is produced, only the extension part. </td>
</tr>
</table>
<a class="anchor" name="ga14" doxytag="qfits_table.c::qfits_table_append_xtension_hdr"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_table_append_xtension_hdr </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">FILE *&nbsp;</td>
<td class="mdname" nowrap> <em>outfile</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const qfits_table *&nbsp;</td>
<td class="mdname" nowrap> <em>t</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const void **&nbsp;</td>
<td class="mdname" nowrap> <em>data</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const qfits_header *&nbsp;</td>
<td class="mdname" nowrap> <em>hdr</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Appends a specified extension header + data to a FITS table file.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>outfile</em>&nbsp;</td><td>Pointer to (opened) file ready for writing. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>t</em>&nbsp;</td><td>Pointer to qfits_table </td></tr>
<tr><td valign="top"></td><td valign="top"><em>data</em>&nbsp;</td><td>Table data to write </td></tr>
<tr><td valign="top"></td><td valign="top"><em>hdr</em>&nbsp;</td><td>Specified extension header </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0 if Ok, -1 otherwise</dd></dl>
Dumps a FITS table to a file. The whole table described by qfits_table, and the data arrays contained in 'data' are dumped to the file following the specified fits header. The output is then padded to reach a multiple of 2880 bytes in size. Notice that no main header is produced, only the extension part. </td>
</tr>
</table>
<a class="anchor" name="ga6" doxytag="qfits_table.c::qfits_table_close"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void qfits_table_close </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">qfits_table *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>t</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Free a FITS table and associated pointers.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>t</em>&nbsp;</td><td>qfits_table to free </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>void Frees all memory associated to a qfits_table structure. </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga2" doxytag="qfits_table.c::qfits_table_ext_header_default"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">qfits_header* qfits_table_ext_header_default </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const qfits_table *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>t</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Generate a default extension header to store tables.
<p>
<dl compact><dt><b>Returns:</b></dt><dd>the header object </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga15" doxytag="qfits_table.c::qfits_table_field_to_string"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* qfits_table_field_to_string </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const qfits_table *&nbsp;</td>
<td class="mdname" nowrap> <em>table</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>col_id</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>row_id</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>use_zero_scale</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
given a col and a row, find out the string to write for display
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>table</em>&nbsp;</td><td>table structure </td></tr>
<tr><td valign="top"></td><td valign="top"><em>col_id</em>&nbsp;</td><td>col id (0 -&gt; nbcol-1) </td></tr>
<tr><td valign="top"></td><td valign="top"><em>row_id</em>&nbsp;</td><td>row id (0 -&gt; nrow-1) </td></tr>
<tr><td valign="top"></td><td valign="top"><em>use_zero_scale</em>&nbsp;</td><td>Flag to use or not zero and scale </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>the string</dd></dl>
This function is highly inefficient, it should not be used in loops to display a complete table. It is more to get one field from time to time, or for debugging puposes. The returned object must be deallocated with qfits_free(). </td>
</tr>
</table>
<a class="anchor" name="ga3" doxytag="qfits_table.c::qfits_table_new"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">qfits_table* qfits_table_new </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>table_type</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>table_width</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>nb_cols</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>nb_raws</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Table object constructor.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the FITS file associated to the table </td></tr>
<tr><td valign="top"></td><td valign="top"><em>table_type</em>&nbsp;</td><td>Type of the table (QFITS_ASCIITABLE or QFITS_BINTABLE) </td></tr>
<tr><td valign="top"></td><td valign="top"><em>table_width</em>&nbsp;</td><td>Width in bytes of the table </td></tr>
<tr><td valign="top"></td><td valign="top"><em>nb_cols</em>&nbsp;</td><td>Number of columns </td></tr>
<tr><td valign="top"></td><td valign="top"><em>nb_raws</em>&nbsp;</td><td>Number of raws </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>The table object The columns are also allocated. The object has to be deallocated with <a class="el" href="group__qfits__table.html#ga6">qfits_table_close()</a> </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga5" doxytag="qfits_table.c::qfits_table_open"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">qfits_table* qfits_table_open </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>xtnum</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Read a FITS extension.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the FITS file to examine. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>xtnum</em>&nbsp;</td><td>Extension number to read (starting from 1). </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>Pointer to newly allocated qfits_table structure.</dd></dl>
Read a FITS table from a given file name and extension, and return a newly allocated qfits_table structure. </td>
</tr>
</table>
<a class="anchor" name="ga1" doxytag="qfits_table.c::qfits_table_prim_header_default"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">qfits_header* qfits_table_prim_header_default </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">void&nbsp;</td>
<td class="mdname1" valign="top" nowrap> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Generate a default primary header to store tables.
<p>
<dl compact><dt><b>Returns:</b></dt><dd>the header object </dd></dl>
</td>
</tr>
</table>
</body>
</html>

View File

@ -0,0 +1,55 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>Get date/time, possibly in ISO8601 format</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__time.html#ga0">qfits_get_datetime_iso8601</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the current date and time as a static string. <a href="#ga0"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
This module contains various utilities to get the current date/time, and possibly format it according to the ISO 8601 format. <hr><h2>Function Documentation</h2>
<a class="anchor" name="ga0" doxytag="qfits_time.c::qfits_get_datetime_iso8601"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* qfits_get_datetime_iso8601 </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">void&nbsp;</td>
<td class="mdname1" valign="top" nowrap> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Returns the current date and time as a static string.
<p>
<dl compact><dt><b>Returns:</b></dt><dd>Pointer to statically allocated string</dd></dl>
Build and return a string containing the date of today and the current time in ISO8601 format. The returned pointer points to a statically allocated string in the function, so no need to free it. </td>
</tr>
</table>
</body>
</html>

View File

@ -0,0 +1,639 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>Simple FITS access routines</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga0">qfits_query_hdr</a> (const char *filename, const char *keyword)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Retrieve the value of a key in a FITS header. <a href="#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga1">qfits_query_ext</a> (const char *filename, const char *keyword, int xtnum)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Retrieve the value of a keyin a FITS extension header. <a href="#ga1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga2">qfits_query_n_ext</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Counts the number of extensions in a FITS file. <a href="#ga2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga3">qfits_query_nplanes</a> (const char *filename, int extnum)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Counts the number of planes in a FITS extension. <a href="#ga3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga4">qfits_pretty_string</a> (const char *s)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Clean out a FITS string value. <a href="#ga4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga5">qfits_is_boolean</a> (const char *s)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Identify if a FITS value is boolean. <a href="#ga5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga6">qfits_is_int</a> (const char *s)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Identify if a FITS value is an int. <a href="#ga6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga7">qfits_is_float</a> (const char *s)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Identify if a FITS value is float. <a href="#ga7"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga8">qfits_is_complex</a> (const char *s)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Identify if a FITS value is complex. <a href="#ga8"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga9">qfits_is_string</a> (const char *s)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Identify if a FITS value is string. <a href="#ga9"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga10">qfits_get_type</a> (const char *s)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Identify the type of a FITS value given as a string. <a href="#ga10"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga11">qfits_query_card</a> (const char *filename, const char *keyword)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Query a card in a FITS (main) header by a given key. <a href="#ga11"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga12">qfits_replace_card</a> (const char *filename, const char *keyword, const char *substitute)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Replace a card in a FITS (main) header by a given card. <a href="#ga12"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">const char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga13">qfits_version</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the current QFITS version. <a href="#ga13"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
This module offers a number of very basic low-level FITS access routines. <hr><h2>Function Documentation</h2>
<a class="anchor" name="ga10" doxytag="qfits_tools.c::qfits_get_type"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_get_type </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>s</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Identify the type of a FITS value given as a string.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>s</em>&nbsp;</td><td>FITS value as a string </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>integer naming the FITS type</dd></dl>
Returns the following value:<p>
<ul>
<li>QFITS_UNKNOWN (0) for an unknown type.</li><li>QFITS_BOOLEAN (1) for a boolean type.</li><li>QFITS_INT (2) for an integer type.</li><li>QFITS_FLOAT (3) for a floating-point type.</li><li>QFITS_COMPLEX (4) for a complex number.</li><li>QFITS_STRING (5) for a FITS string. </li></ul>
</td>
</tr>
</table>
<a class="anchor" name="ga5" doxytag="qfits_tools.c::qfits_is_boolean"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_is_boolean </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>s</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Identify if a FITS value is boolean.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>s</em>&nbsp;</td><td>FITS value as a string </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0 or 1</dd></dl>
Identifies if a FITS value is boolean. </td>
</tr>
</table>
<a class="anchor" name="ga8" doxytag="qfits_tools.c::qfits_is_complex"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_is_complex </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>s</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Identify if a FITS value is complex.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>s</em>&nbsp;</td><td>FITS value as a string </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0 or 1</dd></dl>
Identifies if a FITS value is complex. </td>
</tr>
</table>
<a class="anchor" name="ga7" doxytag="qfits_tools.c::qfits_is_float"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_is_float </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>s</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Identify if a FITS value is float.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>s</em>&nbsp;</td><td>FITS value as a string </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0 or 1</dd></dl>
Identifies if a FITS value is float. </td>
</tr>
</table>
<a class="anchor" name="ga6" doxytag="qfits_tools.c::qfits_is_int"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_is_int </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>s</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Identify if a FITS value is an int.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>s</em>&nbsp;</td><td>FITS value as a string </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0 or 1</dd></dl>
Identifies if a FITS value is an integer. </td>
</tr>
</table>
<a class="anchor" name="ga9" doxytag="qfits_tools.c::qfits_is_string"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_is_string </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>s</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Identify if a FITS value is string.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>s</em>&nbsp;</td><td>FITS value as a string </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0 or 1</dd></dl>
Identifies if a FITS value is a string. </td>
</tr>
</table>
<a class="anchor" name="ga4" doxytag="qfits_tools.c::qfits_pretty_string"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* qfits_pretty_string </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>s</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Clean out a FITS string value.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>s</em>&nbsp;</td><td>pointer to allocated FITS value string. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>pointer to statically allocated character string</dd></dl>
From a string FITS value like 'marvin o''hara', remove head and tail quotes, replace double '' with simple ', trim blanks on each side, and return the result in a statically allocated area.<p>
Examples:<p>
<ul>
<li>['o''hara'] becomes [o'hara]</li><li>[' H '] becomes [H]</li><li>['1.0 '] becomes [1.0] </li></ul>
</td>
</tr>
</table>
<a class="anchor" name="ga11" doxytag="qfits_tools.c::qfits_query_card"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* qfits_query_card </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>keyword</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Query a card in a FITS (main) header by a given key.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the FITS file to check. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>keyword</em>&nbsp;</td><td>Where to read a card in the header. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>Allocated string containing the card or NULL </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga1" doxytag="qfits_tools.c::qfits_query_ext"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* qfits_query_ext </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>keyword</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>xtnum</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Retrieve the value of a keyin a FITS extension header.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>name of the FITS file to browse. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>keyword</em>&nbsp;</td><td>name of the FITS key to look for. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>xtnum</em>&nbsp;</td><td>xtension number </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>pointer to statically allocated character string</dd></dl>
Same as qfits_query_hdr but for extensions. xtnum starts from 1 to the number of extensions. If xtnum is zero, this function is strictly identical to <a class="el" href="group__qfits__tools.html#ga0">qfits_query_hdr()</a>. </td>
</tr>
</table>
<a class="anchor" name="ga0" doxytag="qfits_tools.c::qfits_query_hdr"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* qfits_query_hdr </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>keyword</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Retrieve the value of a key in a FITS header.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the FITS file to browse </td></tr>
<tr><td valign="top"></td><td valign="top"><em>keyword</em>&nbsp;</td><td>Name of the keyword to find </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>pointer to statically allocated character string</dd></dl>
Provide the name of a FITS file and a keyword to look for. The input file is memory-mapped and the first keyword matching the requested one is located. The value corresponding to this keyword is copied to a statically allocated area, so do not modify it or free it.<p>
The input keyword is first converted to upper case and expanded to the HIERARCH scheme if given in the shortFITS notation.<p>
This function is pretty fast due to the mmapping. Due to buffering on most Unixes, it is possible to call many times this function in a row on the same file and do not suffer too much from performance problems. If the file contents are already in the cache, the file will not be re-opened every time.<p>
It is possible, though, to modify this function to perform several searches in a row. See the source code.<p>
Returns NULL in case the requested keyword cannot be found. </td>
</tr>
</table>
<a class="anchor" name="ga2" doxytag="qfits_tools.c::qfits_query_n_ext"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_query_n_ext </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>filename</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Counts the number of extensions in a FITS file.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the FITS file to browse. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int Counts how many extensions are in the file. Returns 0 if no extension is found, and -1 if an error occurred. </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga3" doxytag="qfits_tools.c::qfits_query_nplanes"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_query_nplanes </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap> <em>extnum</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Counts the number of planes in a FITS extension.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the FITS file to browse. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>extnum</em>&nbsp;</td><td>Extensin number </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int Counts how many planes are in the extension. Returns 0 if no plane is found, and -1 if an error occurred. </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga12" doxytag="qfits_tools.c::qfits_replace_card"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int qfits_replace_card </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname" nowrap> <em>filename</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>keyword</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>const char *&nbsp;</td>
<td class="mdname" nowrap> <em>substitute</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Replace a card in a FITS (main) header by a given card.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>filename</em>&nbsp;</td><td>Name of the FITS file to modify. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>keyword</em>&nbsp;</td><td>Where to substitute a card in the header. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>substitute</em>&nbsp;</td><td>What to replace the line with. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>int 0 if Ok, -1 otherwise</dd></dl>
Replaces a whole card (80 chars) in a FITS header by a given FITS line (80 chars). The replacing line is assumed correctly formatted and containing at least 80 characters. The file is modified: it must be accessible in read/write mode.<p>
The input keyword is first converted to upper case and expanded to the HIERARCH scheme if given in the shortFITS notation.<p>
Returns 0 if everything worked Ok, -1 otherwise. </td>
</tr>
</table>
<a class="anchor" name="ga13" doxytag="qfits_tools.c::qfits_version"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">const char* qfits_version </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">void&nbsp;</td>
<td class="mdname1" valign="top" nowrap> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Return the current QFITS version.
<p>
<dl compact><dt><b>Returns:</b></dt><dd>the QFITS version </dd></dl>
</td>
</tr>
</table>
</body>
</html>

View File

@ -2,7 +2,7 @@
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>qfits 5.3.1</title>
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
@ -12,7 +12,7 @@
<!-- Generated by Doxygen 1.4.1 -->
<h1>qfits Reference manual </h1>
<p>
<h3 align="center">5.3.1 </h3><hr>
<h3 align="center">6.2.0 </h3><hr>
<h2><a class="anchor" name="welcome">
Introduction</a></h2>
<b>qfits</b> is a stand-alone library written in C to interact with files complying with the FITS format. It is fast and portable over any kind of POSIX-compliant platform.<p>
@ -21,7 +21,6 @@ Functionalities offered by this library are:<p>
<ul>
<li>Header queries (get keywords, values).</li><li>Header manipulation (load/modify/save).</li><li>Header/data offset queries.</li><li>Pixel loading/saving to memory.</li><li>Support for files of any dimension (NAXIS).</li><li>Support for FITS extensions, including ASCII and binary tables.</li></ul>
<p>
This library also comes with a limited set of interfaces to Python to make some of its functionalities usable from this language. See the compilation instructions to build it as a Python module. The Qfits.py module contains its own doc.<p>
<hr>
<h2><a class="anchor" name="history">
History</a></h2>
@ -29,51 +28,42 @@ History</a></h2>
<b>qfits</b> was written to take care of all low-level aspects of the FITS format, and only these. You will find there a wealth of optimized functions to access everything inside FITS files, but nothing about what you could do with the data: this is left to other (e.g. image processing) libraries. There is no suggested image or cube type, and the table object only loads the data without trying to interpret them.<p>
The idea is that people wanting to work with FITS might have different requirements: somebody writing an image viewer might just want to load a pixel buffer, somebody handling headers only might want to have easy access to header information without touching pixel data. <b>qfits</b> allows you to get your hands on what is contained in a FITS file but does not force you to use any specific high-level data type to describe your data.<p>
<hr>
<h2><a class="anchor" name="authors">
Authors</a></h2>
Nicolas Devillard and Yves Jung, ESO.<p>
<hr>
<h2><a class="anchor" name="header">
Header handling</a></h2>
This section gives you an overview of the functionalities offered to work on FITS headers with <b>qfits</b>. For a complete reference, check out the reference manual: <a class="el" href="qfits_8h.html">qfits.h</a>.<p>
This section gives you an overview of the functionalities offered to work on FITS headers with <b>qfits</b>. For a complete reference, check out the reference manual: qfits.h.<p>
FITS headers are simply formatted as 80-char lines (<em>cards</em>) containing ancillary data represented in ASCII format like:<p>
keyword = value / comment<p>
If you want to retrieve data from a FITS file header, you will find various useful query routines to get a keyword value from main or extension headers. Values are returned as strings and not coerced to any particular (e.g. numerical) type. See e.g.<p>
<ul>
<li><a class="el" href="qfits_8h.html#a85">qfits_query_hdr()</a> to query the main header.</li><li><a class="el" href="qfits_8h.html#a86">qfits_query_ext()</a> to query an extension header.</li><li><a class="el" href="qfits_8h.html#a87">qfits_query_n_ext()</a> to get the number of extensions.</li></ul>
<p>
You may also want to handle file inputs by yourself and have FITS cards split into their components key/value/comment. See e.g.<p>
<ul>
<li><a class="el" href="qfits_8h.html#a52">qfits_getkey()</a> to extract the key from a FITS line.</li><li><a class="el" href="qfits_8h.html#a53">qfits_getvalue()</a> to extract the value.</li><li><a class="el" href="qfits_8h.html#a54">qfits_getcomment()</a> to extract the comment.</li></ul>
<li><a class="el" href="group__qfits__tools.html#ga0">qfits_query_hdr()</a> to query the main header.</li><li><a class="el" href="group__qfits__tools.html#ga1">qfits_query_ext()</a> to query an extension header.</li><li><a class="el" href="group__qfits__tools.html#ga2">qfits_query_n_ext()</a> to get the number of extensions.</li></ul>
<p>
Since all FITS values are returned as strings, you may need to identify types. See e.g.<p>
<ul>
<li><a class="el" href="qfits_8h.html#a95">qfits_get_type()</a> to identify a value type</li><li><a class="el" href="qfits_8h.html#a90">qfits_is_boolean()</a></li><li><a class="el" href="qfits_8h.html#a91">qfits_is_int()</a></li><li><a class="el" href="qfits_8h.html#a92">qfits_is_float()</a></li><li><a class="el" href="qfits_8h.html#a93">qfits_is_complex()</a></li><li><a class="el" href="qfits_8h.html#a94">qfits_is_string()</a></li></ul>
<li><a class="el" href="group__qfits__tools.html#ga10">qfits_get_type()</a> to identify a value type</li><li><a class="el" href="group__qfits__tools.html#ga5">qfits_is_boolean()</a></li><li><a class="el" href="group__qfits__tools.html#ga6">qfits_is_int()</a></li><li><a class="el" href="group__qfits__tools.html#ga7">qfits_is_float()</a></li><li><a class="el" href="group__qfits__tools.html#ga8">qfits_is_complex()</a></li><li><a class="el" href="group__qfits__tools.html#ga9">qfits_is_string()</a></li></ul>
<p>
Of course, you can use the usual <code>atof()</code>, <code>atoi()</code> and <code>scanf()</code> functions to convert a string to a numerical type.<p>
You may also want to perform more complex operations on FITS headers, like loading one, modifying it and saving it back to a new file. The <a class="el" href="structqfits__header.html">qfits_header</a> data structure is offered for that purpose. It comes with utilities like:<p>
You may also want to perform more complex operations on FITS headers, like loading one, modifying it and saving it back to a new file. The qfits_header data structure is offered for that purpose. It comes with utilities like:<p>
<ul>
<li><a class="el" href="qfits_8h.html#a55">qfits_header_read()</a> to load a header.</li><li><a class="el" href="qfits_8h.html#a58">qfits_header_readext()</a> same from an extension.</li><li><a class="el" href="qfits_8h.html#a48">qfits_header_dump()</a> to save a header to a file.</li><li>...</li></ul>
<li><a class="el" href="group__qfits__rw.html#ga0">qfits_header_read()</a> to load a header.</li><li><a class="el" href="group__qfits__rw.html#ga3">qfits_header_readext()</a> same from an extension.</li><li><a class="el" href="group__qfits__header.html#ga16">qfits_header_dump()</a> to save a header to a file.</li><li>...</li></ul>
<p>
And of course all manipulation tools you can think of:<p>
<ul>
<li><a class="el" href="qfits_8h.html#a29">qfits_header_add()</a></li><li><a class="el" href="qfits_8h.html#a30">qfits_header_add_after()</a></li><li><a class="el" href="qfits_8h.html#a31">qfits_header_append()</a></li><li><a class="el" href="qfits_8h.html#a33">qfits_header_mod()</a></li><li><a class="el" href="qfits_8h.html#a32">qfits_header_del()</a></li><li>...</li></ul>
<li><a class="el" href="group__qfits__header.html#ga2">qfits_header_add()</a></li><li><a class="el" href="group__qfits__header.html#ga3">qfits_header_add_after()</a></li><li><a class="el" href="group__qfits__header.html#ga4">qfits_header_append()</a></li><li><a class="el" href="group__qfits__header.html#ga6">qfits_header_mod()</a></li><li><a class="el" href="group__qfits__header.html#ga5">qfits_header_del()</a></li><li>...</li></ul>
<p>
There are other functions to create new FITS cards, dump a header to screen for debugging purposes, etc. See the reference manual (<a class="el" href="qfits_8h.html">qfits.h</a>) for an exhaustive description.<p>
An important feature of the <a class="el" href="structqfits__header.html">qfits_header</a> object when loaded from a file, is that it keeps the memory of the initial FITS card. The data structure that is carried around for each FITS card contains:<p>
There are other functions to create new FITS cards, dump a header to screen for debugging purposes, etc. See the reference manual for an exhaustive description.<p>
An important feature of the qfits_header object when loaded from a file, is that it keeps the memory of the initial FITS card. The data structure that is carried around for each FITS card contains:<p>
<ul>
<li>Identified keyword</li><li>Identified value</li><li>Possible comment</li><li>Line as read from initial file when applicable.</li></ul>
<p>
This feature is fairly useful if you want to perform header manipulation without getting too intrusive. You can use this to load a header, modify a couple of cards and dump all back to disk. The dumped header will only be modified for the cards you have touched, all others will be forwarded verbatim as they appeared in the initial file. This least-modification policy ensures that you will not modify the lines you do not need to touch.<p>
This feature can be turned off by "touching" all lines in a header using <a class="el" href="qfits_8h.html#a36">qfits_header_touchall()</a>, which removes all initial line information from a <a class="el" href="structqfits__header.html">qfits_header</a> object. This is useful to force a reformatting of a FITS header e.g. when the file header is damaged.<p>
Notice that ESO's <code>HIERARCH</code> keywords and DICB ordering are natively supported by <b>qfits</b>, i.e. when you work with <a class="el" href="structqfits__header.html">qfits_header</a> objects you can be sure that they will properly recognize and sort keywords following ESO conventions.<p>
Notice that ESO's <code>HIERARCH</code> keywords and DICB ordering are natively supported by <b>qfits</b>, i.e. when you work with qfits_header objects you can be sure that they will properly recognize and sort keywords following ESO conventions.<p>
<hr>
<h2><a class="anchor" name="data">
Data handling</a></h2>
This section gives you an overview of the functionalities offered to work on FITS data segments with <b>qfits</b>. For a complete reference, check out the reference manual (<a class="el" href="qfits_8h.html">qfits.h</a>).<p>
This section gives you an overview of the functionalities offered to work on FITS data segments with <b>qfits</b>. For a complete reference, check out the reference manual.<p>
Data segments are quite simply stored: they always contain data contiguously in uncompressed format, so reading them is mostly a matter of applying an <code>fread()</code> statement at the right place in the file, with the right size. To find out about offsets to data and header parts in a FITS file (possibly containing several extensions), you can make use of:<p>
<ul>
<li><a class="el" href="qfits_8h.html#a96">qfits_get_hdrinfo()</a> to return information about a header position and size (in bytes) in a file.</li><li><a class="el" href="qfits_8h.html#a97">qfits_get_datinfo()</a> to return information about a data segment position and size (in bytes) in a file.</li></ul>
<li><a class="el" href="group__qfits__rw.html#ga6">qfits_get_hdrinfo()</a> to return information about a header position and size (in bytes) in a file.</li><li><a class="el" href="group__qfits__rw.html#ga7">qfits_get_datinfo()</a> to return information about a data segment position and size (in bytes) in a file.</li></ul>
<p>
<b>qfits</b> includes a caching mechanism to speed up accesses to large files to an optimal access time (only one parsing of the file is needed, even with multiple queries on the same file). This mechanism is internal to this module and invisible to the programmer using <b>qfits</b>. This means that you can loop on all sections on a huge file to retrieve file offsets for each extension, and pay the price of file parsing only at the first call.<p>
If you want to dive further into data loading, you may want to have a look at table and image handling functionalities.<h3><a class="anchor" name="table">
@ -87,35 +77,25 @@ In BINARY tables, you can find 11 different data types, in ASCII tables, there a
<li>TFITS_BIN_TYPE_A : Characters (1 byte)</li><li>TFITS_BIN_TYPE_B : Unsigned byte (1 byte)</li><li>TFITS_BIN_TYPE_C : Float complex (2 * 4 bytes)</li><li>TFITS_BIN_TYPE_D : Double (8 bytes)</li><li>TFITS_BIN_TYPE_E : Float (4 bytes)</li><li>TFITS_BIN_TYPE_I : Short (2 bytes)</li><li>TFITS_BIN_TYPE_J : Integer (4 bytes)</li><li>TFITS_BIN_TYPE_L : Logical (1 byte)</li><li>TFITS_BIN_TYPE_M : Double complex (2 * 8 bytes)</li><li>TFITS_BIN_TYPE_P : Array descriptor (2 * 4 bytes)</li><li>TFITS_BIN_TYPE_X : Bit (1 bit)</li></ul>
</li></ul>
<p>
The <a class="el" href="structqfits__table.html">qfits_table</a> object provided by <b>qfits</b> contains all necessary informations to define how the data are stored in the file: the name of the file it comes from, the table type (QFITS_BINTABLE or QFITS_ASCIITABLE), the number of columns and for each column a pointer to a <a class="el" href="structqfits__col.html">qfits_col</a> object.<p>
Each <a class="el" href="structqfits__col.html">qfits_col</a> object contains informations defining the associated column: the type (e.g. TFITS_BIN_TYPE_L), the number of rows, the number of atoms per field, the label, the unit, etc...).<p>
This <a class="el" href="structqfits__table.html">qfits_table</a> object is returned by <a class="el" href="qfits_8h.html#a109">qfits_table_open()</a> and should only be destroyed with <a class="el" href="qfits_8h.html#a110">qfits_table_close()</a>.<p>
This <a class="el" href="structqfits__table.html">qfits_table</a> object does not contain the table data, but has to be used to load the data with functions like:<p>
The qfits_table object provided by <b>qfits</b> contains all necessary informations to define how the data are stored in the file: the name of the file it comes from, the table type (QFITS_BINTABLE or QFITS_ASCIITABLE), the number of columns and for each column a pointer to a qfits_col object.<p>
Each qfits_col object contains informations defining the associated column: the type (e.g. TFITS_BIN_TYPE_L), the number of rows, the number of atoms per field, the label, the unit, etc...).<p>
This qfits_table object is returned by <a class="el" href="group__qfits__table.html#ga5">qfits_table_open()</a> and should only be destroyed with <a class="el" href="group__qfits__table.html#ga6">qfits_table_close()</a>.<p>
This qfits_table object does not contain the table data, but has to be used to load the data with functions like:<p>
<ul>
<li><a class="el" href="qfits_8h.html#a111">qfits_query_column()</a></li><li><a class="el" href="qfits_8h.html#a114">qfits_query_column_data()</a></li><li><a class="el" href="qfits_8h.html#a116">qfits_query_column_nulls()</a></li></ul>
<li><a class="el" href="group__qfits__table.html#ga7">qfits_query_column()</a></li><li><a class="el" href="group__qfits__table.html#ga9">qfits_query_column_data()</a></li><li><a class="el" href="group__qfits__table.html#ga11">qfits_query_column_nulls()</a></li></ul>
<p>
<a class="el" href="qfits_8h.html#a111">qfits_query_column()</a> returns you simply the data (byte swapped if necessary) as they were read in the file as a byte array. It is up to the user to interpret the data (e.g. to try to find out where the NULL values are).<p>
<a class="el" href="qfits_8h.html#a114">qfits_query_column_data()</a> does the same, but identifies the NULL values and replaces them by a user-provided value. In this case, the returned array is an array of data of the right type. It is returned as a void*, the user just has to cast it to a double*, a short* or what is needed.<p>
For example, if you require in a table that contains 15 rows a column where you can find 3 values of type TFITS_BIN_TYPE_M (double complex), <a class="el" href="qfits_8h.html#a114">qfits_query_column_data()</a> will return an array of 15 * 3 * 2 double values.<p>
<b>qfits</b> also provides functions to write a table to a FITS file (<a class="el" href="qfits_8h.html#a117">qfits_save_table_hdrdump()</a>), or to print out a table value or a complete table on the screen or in a file (<a class="el" href="qfits_8h.html#a120">qfits_table_field_to_string()</a>).<h3><a class="anchor" name="image">
<a class="el" href="group__qfits__table.html#ga7">qfits_query_column()</a> returns you simply the data (byte swapped if necessary) as they were read in the file as a byte array. It is up to the user to interpret the data (e.g. to try to find out where the NULL values are).<p>
<a class="el" href="group__qfits__table.html#ga9">qfits_query_column_data()</a> does the same, but identifies the NULL values and replaces them by a user-provided value. In this case, the returned array is an array of data of the right type. It is returned as a void*, the user just has to cast it to a double*, a short* or what is needed.<p>
For example, if you require in a table that contains 15 rows a column where you can find 3 values of type TFITS_BIN_TYPE_M (double complex), <a class="el" href="group__qfits__table.html#ga9">qfits_query_column_data()</a> will return an array of 15 * 3 * 2 double values.<p>
<b>qfits</b> also provides functions to write a table to a FITS file (<a class="el" href="group__qfits__table.html#ga12">qfits_save_table_hdrdump()</a>), or to print out a table value or a complete table on the screen or in a file (<a class="el" href="group__qfits__table.html#ga15">qfits_table_field_to_string()</a>).<h3><a class="anchor" name="image">
Image handling</a></h3>
The qfitsloader and qfitsdumper objects are offered to simplify the action of reading/writing image data. The corresponding operators take care of retrieving all necessary ancillary information (image size, pixel type, buffer position), perform a memory allocation or mapping and read the file into memory. See the following functions:<p>
<ul>
<li><a class="el" href="qfits_8h.html#a73">qfitsloader_init()</a> to initialize a loader object.</li><li><a class="el" href="qfits_8h.html#a74">qfits_loadpix()</a> to load pixel data into memory.</li><li><a class="el" href="qfits_8h.html#a78">qfits_pixdump()</a> to save pixel data to disk.</li></ul>
<p>
As for tables, the idea is that you first launch an analysis of the file to get back a number of informations about what is present there. In the case of images, you use <a class="el" href="qfits_8h.html#a73">qfitsloader_init()</a> to see if pixel loading could be done, then use <a class="el" href="qfits_8h.html#a74">qfits_loadpix()</a> to perform the actual load.<p>
Pixel I/O are taking place in float, int or double format. See the corresponding functions:<p>
<ul>
<li><a class="el" href="qfits_8h.html#a75">qfits_pixin_float()</a></li><li><a class="el" href="qfits_8h.html#a76">qfits_pixin_int()</a></li><li><a class="el" href="qfits_8h.html#a77">qfits_pixin_double()</a></li><li><a class="el" href="qfits_8h.html#a79">qfits_pixdump_float()</a></li><li><a class="el" href="qfits_8h.html#a80">qfits_pixdump_int()</a></li><li><a class="el" href="qfits_8h.html#a81">qfits_pixdump_double()</a></li></ul>
<li><a class="el" href="group__qfits__image.html#ga0">qfitsloader_init()</a> to initialize a loader object.</li><li><a class="el" href="group__qfits__image.html#ga1">qfits_loadpix()</a> to load pixel data into memory.</li><li><a class="el" href="group__qfits__image.html#ga3">qfits_pixdump()</a> to save pixel data to disk.</li></ul>
<p>
As for tables, the idea is that you first launch an analysis of the file to get back a number of informations about what is present there. In the case of images, you use <a class="el" href="group__qfits__image.html#ga0">qfitsloader_init()</a> to see if pixel loading could be done, then use <a class="el" href="group__qfits__image.html#ga1">qfits_loadpix()</a> to perform the actual load.<p>
Loading pixels as floats means that whichever pixel format (BITPIX) is used in your input FITS file, all pixels will be converted to your local representation of float upon loading. The 3 offered types basically allow you to work with 3 kinds of pixels internally, choose the one that best suits your needs. 'int' is not recommended for loss of precision, and 'double' for memory and performance issues.<p>
Saving pixels can be done with any BITPIX setting. There are 3 pixel dumpers as there are 3 pixel loaders, because there are 3 possible types for pixel buffers in memory (int, float, double). All pixels are converted on the fly to the requested BITPIX setting.<p>
Notice that as soon as you start using pixel loading functions, you must comply with the <b>qfits</b> memory model. This basically means that you should not only include <code><a class="el" href="qfits_8h.html">qfits.h</a></code> in your program, but also <code>xmemory.h</code> to get the proper definitions for memory allocation functions.<h2><a class="anchor" name="utils">
Other utilities</a></h2>
Some additional functions are offered in <b>qfits</b>, they are useful in the VLT context. See:<p>
<ul>
<li>date_now()</li><li>time_now()</li><li>get_date_iso8601()</li><li>get_datetime_iso8601()</li></ul>
<p>
Notice that as soon as you start using pixel loading functions, you must comply with the <b>qfits</b> memory model.<p>
<hr>
<h2><a class="anchor" name="features">
Features</a></h2>
@ -124,13 +104,9 @@ Portability</a></h3>
This library has been ported and tested on the following platforms:<p>
<ul>
<li>Linux x86 and alpha</li><li>Solaris 2.5, 2.6 and 2.8</li><li>HPUX 8, 9, 10, 11</li><li>AIX</li><li>BSD compatible, including Darwin (Mac OS X)</li><li>OSF/1 or Tru64</li></ul>
<p>
Since <b>qfits</b> depends on POSIX system routines, there is little chance it could compile natively on Windows, except with the help from GNU porting tools from Cygnus. This has never been attempted so far.<h3><a class="anchor" name="speed">
<h3><a class="anchor" name="speed">
Speed</a></h3>
The offered routines make use of caching mechanisms and memory-mapping system calls to enhance FITS file parsing and speed up the code.<h3><a class="anchor" name="interfaces">
Interfaces to C++/Python</a></h3>
You should be able to compile this library with a C++ compiler, the header files include the usual blurb to allow that without warning from the compiler. You might have problems due to pointer casts and other various incompatibilities due to the variety of C++ dialects and compilers, though. If you really need to hook this library into C++ code, your best bet is probably to compile the library as a standard C library and link your C++ code against it.<p>
A limited set of interfaces to Python is offered. See the INSTALL file in the main distribution directory for instructions about installing this library as a Python module.<h3><a class="anchor" name="precision">
The offered routines make use of caching mechanisms and memory-mapping system calls to enhance FITS file parsing and speed up the code.<h3><a class="anchor" name="precision">
Numerical precision</a></h3>
Since FITS headers are stored as strings, numerical precision is limited by the number of digits used to write a number in a FITS card, which is in theory larger than what a 32-bit floating-point can store. Using <b>qfits</b>, these values are available to a C programmer as a string, making sure that precision has at least not be lost in the reading process.<h3><a class="anchor" name="conservative">
Conservative headers</a></h3>
@ -138,228 +114,20 @@ As mentioned above, if you only need to load a header, modify a card and save it
Native HIERARCH support</a></h3>
Native support for ESO's <code>HIERARCH</code> keywords, as well as keywords of any length (up to 80 chars per line).<h3><a class="anchor" name="dicb">
ESO/DICB keyword ordering</a></h3>
Native support for DICB (ESO only) ordering of keywords in the headers. FITS files created with this library will be DICB compliant with respect to keyword ordering.<h3><a class="anchor" name="xmemory">
Native support for DICB (ESO only) ordering of keywords in the headers. FITS files created with this library will be DICB compliant with respect to keyword ordering.<h3><a class="anchor" name="qfits_memory">
Memory model</a></h3>
<b>qfits</b> does not only offer pixel loading mechanisms, it also comes bundled with a memory module based on a model optimized for the handling of very large data segments. In practice, it means that as soon as you have included <code>xmemory.h</code>, your calls to malloc/calloc/free are re-directed to specific versions which put your program on steroids. Calls to memory allocators will yield valid data pointers past the hardware limits of your machine, up to 2 or 4 Gb on a 32-bit workstation and insanely high values on 64-bit processors.<p>
This memory module is also distributed as a stand-alone module which can be downloaded and used without <b>qfits</b>. It is mandatory to use this module when using <b>qfits</b> pixel loaders, to get the advantages of large memory handling.<p>
If you are only interested in header manipulation, you do not need to include <code>xmemory.h</code>.<p>
<b>qfits</b> does not only offer pixel loading mechanisms, it also comes bundled with a memory module based on a model optimized for the handling of very large data segments. Calls to memory allocators will yield valid data pointers past the hardware limits of your machine, up to 2 or 4 Gb on a 32-bit workstation and insanely high values on 64-bit processors.<p>
<hr>
<h2><a class="anchor" name="install">
Installation instructions</a></h2>
In the main <b>qfits</b> directory, type:<p>
<div class="fragment"><pre class="fragment">
./configure ; make
<div class="fragment"><pre class="fragment">
./configure --prefix=install_dir ; make ; make install
</pre></div><p>
To use the library in your programs, add the following line on top of your module:<p>
<div class="fragment"><pre class="fragment"><span class="preprocessor">#include "<a class="code" href="qfits_8h.html">qfits.h</a>"</span>
<div class="fragment"><pre class="fragment"><span class="preprocessor">#include "qfits.h"</span>
</pre></div><p>
And link your program with the <b>qfits</b> library by adding <code>-lqfits</code> to the compile line.<p>
If you ever need to make calls to one of the <b>qfits</b> pixel loaders, you need to include the memory model definitions also with:<p>
<div class="fragment"><pre class="fragment"><span class="preprocessor">#include "xmemory.h"</span>
</pre></div><p>
Including this file is needed so that you can safely <code>free()</code> the pointer returned by a pixel loader. See the documentation about pixel loaders for more information.<p>
To compile <b>qfits</b> as a Python module, you need to have Python installed on your machine and available in your PATH. Type:<p>
<div class="fragment"><pre class="fragment">
% python setup.py install
</pre></div><p>
This should build the module and install it in your default library path. This makes use of the distutils package, standardized since Python 2.0. This means that you need Python 2.0 at least to compile and run this module. If you are running Python 1.5 or 1.6, you may want to install the <code>distutils</code> package on your platform, which will handle the <b>qfits</b> module installation.<p>
<hr>
<h2><a class="anchor" name="python">
Python module documentation</a></h2>
The following documentation has been directly extracted from the qfits Python module (Qfits.py) by running:<p>
<div class="fragment"><pre class="fragment">
% pydoc Qfits.py
</pre></div><p>
Once Qfits.py is installed in your Python distribution, you should also be able to browse this documentation using <code>pydoc</code>.<p>
<div class="fragment"><pre class="fragment">
Python Library Documentation: module Qfits
NAME
Qfits - Qfits.py: a module to read header information from a FITS file.
FILE
Qfits.py
DESCRIPTION
This module offers a function to read all headers in a given
FITS file and return them as a list of strings.
CLASSES
fitsinfo
class fitsinfo
| The fitsinfo class encapsulates queries into a FITS header.
|
| Initialize an instance by giving the name of a file, the following
| fields are then filled in:
|
| - filename - Name of the file
| - n_ext - Number of FITS extensions in file
| - hdrs - List of headers
| - xtnum - Current extension number for get()
|
| The following methods are offered:
|
| * get()
| This method retrieves keyword information in a given instance.
| Provide one or more keywords to look for and this function will
| browse the hdrs list for matching keywords. This method returns a
| string if you requested only 1 keyword or a list of strings if you
| requested several keywords. A failed match returns None.
|
| This method will only search for keywords in the xtnum extension.
|
| get() supports the shortFITS notation, in which A.B.C is transformed
| into HIERARCH ESO A B C before lookup in the FITS header. Notice that
| the given strings are also converted to uppercase before the search
| is launched. See the function expand_keyword() in this module.
|
| Returned string values are always pretty-formatted, i.e. something
| stored into a FITS string as 'o''hara' will be returned as o'hara.
|
| Examples:
|
| q = fitsinfo('vltframe.fits')
| q.get('simple') # returns 'T'
| q.get('simple', 'naxis') # returns ('T', '2')
|
| To search for keywords in the 3rd extension:
|
| q = fitsinfo('wfiframe.fits')
| q.xtnum = 3
| q.get('xtension') # returns 'IMAGE'
| q.get('det.chip3.id', 'bitpix')
| # returns ('ccd52', '16')
|
| * datamd5()
| This method computes the MD5 signature of all the data parts of the
| given FITS file and returns it as a 32-char string containing a
| hexadecimal number on 128 bits.
|
| Methods defined here:
|
| __init__(self, filename)
| Provide a filename to initialize the object.
|
| __repr__(self)
|
| datamd5(self)
|
| get(self, *keywords)
| Get a list of keyword values and return it as a list. If only one
| keyword is requested, the returned value is a single string (or
| None if the keyword was not found). If several keywords are passed,
| the returned value is a list of found values.
|
| The search is only performed in the current extension (xtnum field
| in the class).
|
| ----------------------------------------------------------------------
FUNCTIONS
datamd5(filename)
This function computes the MD5 signature of all data parts in a FITS
file and returns a 32-char string containing the signature as an
hexadecimal number (128 bits). It raises an IOError exception if the
given filename does not correspond to a valid FITS file.
expand_keyword(key)
This function is useful to expand a given keyword into
its FITS equivalent. What it does is simply bring the
word to uppercase, then expand shortFITS words to HIERARCH
ESO notation, like:
simple -&gt; SIMPLE
NaXiS -&gt; NAXIS
det.dit -&gt; HIERARCH ESO DET DIT
get_headers(filename)
This function is the main operator in this module.
Given a file name, it returns all header informations
in a list of lists. The top list contains one element
per found header, i.e. if the given file has 8 extensions,
the top list contains 9 items (1 for the main header,
8 for the extension headers). Each list contains
in turn all informations about the corresponding
headers as a list of tuples like
(key, value, comment)
Example:
The given FITS file contains 1 main header and 2
extension headers given as follows:
--- main header
SIMPLE = T / FITS format
BITPIX = 8 / Bits per pixel
NAXIS = 0 / No data
...
END
--- extension 1
XTENSION = 'IMAGE' / Image extension
BITPIX = 16 / Bits per pixel
...
END
--- extension 2
XTENSION = 'IMAGE' / Image extension
BITPIX = -32 / Bits per pixel
...
END
The returned list contains three items.
The first one is a list corresponding to the
main header, then come the two extension
headers. The first list looks like:
[ ('SIMPLE','T','FITS format'),
('BITPIX', '8', 'Bits per pixel'),
('NAXIS', '0', 'No data'),
...
('END', '', '') ]
The extension lists look like this:
[ ('XTENSION', 'IMAGE', 'Image extension'),
('BITPIX', '16', 'Bits per pixel'),
...
('END', '', '') ]
[ ('XTENSION', 'IMAGE', 'Image extension'),
('BITPIX', '-32', 'Bits per pixel'),
...
('END', '', '') ]
In summary, if you want to get all FITS header informations
from a FITS file, call this function with:
hdr = qfits.get_headers(filename)
This function will raise an IOError exception if the provided
filename does not correspond to a valid file, and None if
the file is not FITS.
If the load succeeded, you can access individual keywords
with the following syntax:
hdr[extension][row][index]
Where:
extension runs from 0 to N_EXT (inclusive)
row is the row number of the card
index is 0 for the keyword, 1 for the value, 2 for the comment.
The number of FITS extensions found in the file is simply:
len(hdr)-1
version()
This function returns the version number of the
underlying qfits module.
</pre></div><p>
<hr>
<h2><a class="anchor" name="faq">
Frequently Asked Questions</a></h2>
@ -368,15 +136,11 @@ Where should I start to use qfits?</a></h3>
Try to build the library on your system first. You should then have a new library file called libqfits.a. To use the library functionalities in your programs, you must add the following include in your list of includes:<p>
<div class="fragment"><pre class="fragment">
#include "qfits.h"
</pre></div><p>
And then compile your program adding the correct flags to indicate where the <b><a class="el" href="qfits_8h.html">qfits.h</a></b> header file is, where the libqfits.a file is, and that you want to link against libqfits. Example: if the header file is in /usr/local/include and the library in /usr/local/lib, you would use:<p>
</pre></div><p>
And then compile your program adding the correct flags to indicate where the <b>qfits.h</b> header file is, where the libqfits.a file is, and that you want to link against libqfits. Example: if the header file is in /usr/local/include and the library in /usr/local/lib, you would use:<p>
<div class="fragment"><pre class="fragment">
% cc -o myprog myprog.c -I/usr/local/include -L/usr/local/lib -lqfits
</pre></div><p>
If you need to use pixel loaders/dumpers, you also need to include the <b>qfits</b> memory-handling module:<p>
<div class="fragment"><pre class="fragment">
#include "xmemory.h"
</pre></div><p>
</pre></div><p>
Now you are all set. Refer to this documentation for more information about the offered data structures and associated methods.<h3><a class="anchor" name="faq2">
What should I know about the cache mechanism?</a></h3>
Parsing FITS files to find extensions is a lengthy process, because the FITS format does not declare in the main header where the following extensions are located in the file. Any access to a FITS file with this library will cache a number of offset pointers in the file to allow fast access to extensions. This means that the file is parsed completely only once, the first time it is accessed through any of the <b>qfits</b> functions.<p>

View File

@ -0,0 +1,27 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>QFITS Reference Manual Modules</h1>Here is a list of all modules:<ul>
<li><a class="el" href="group__qfits__cache.html">FITS caching capabilities</a>
<li><a class="el" href="group__qfits__filename.html">Get various names (filenames, dir names,...)</a>
<li><a class="el" href="group__qfits__header.html">FITS header handling</a>
<li><a class="el" href="group__qfits__image.html">Pixel loader for FITS images.</a>
<li><a class="el" href="group__qfits__md5.html">FITS data block MD5 computation routine</a>
<li><a class="el" href="group__qfits__rw.html">FITS header reading/writing</a>
<li><a class="el" href="group__qfits__table.html">FITS table handling</a>
<li><a class="el" href="group__qfits__time.html">Get date/time, possibly in ISO8601 format</a>
<li><a class="el" href="group__qfits__tools.html">Simple FITS access routines</a>
<li><a class="el" href="group__qfits__memory.html">POSIX-compatible extended memory handling</a>
</ul>
</body>
</html>

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,18 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>qfits.head File Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
</table>
</body>
</html>

View File

@ -0,0 +1,54 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<div class="nav">
<a class="el" href="dir_000000.html">src</a></div>
<h1>qfits_cache.c File Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Typedefs</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef <a class="el" href="struct__qfits__cache__cell__.html">_qfits_cache_cell_</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits__cache_8c.html#a0">qfits_cache_cell</a></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__cache.html#ga0">qfits_cache_purge</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Purge the qfits cache. <a href="group__qfits__cache.html#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__cache.html#ga1">qfits_query</a> (const char *filename, int what)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Query a FITS file offset from the cache. <a href="group__qfits__cache.html#ga1"></a><br></td></tr>
</table>
<hr><h2>Typedef Documentation</h2>
<a class="anchor" name="a0" doxytag="qfits_cache.c::qfits_cache_cell"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">typedef struct <a class="el" href="struct__qfits__cache__cell__.html">_qfits_cache_cell_</a> <a class="el" href="struct__qfits__cache__cell__.html">qfits_cache_cell</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
</body>
</html>

View File

@ -0,0 +1,33 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<div class="nav">
<a class="el" href="dir_000000.html">src</a></div>
<h1>qfits_filename.c File Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__filename.html#ga0">qfits_get_dir_name</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Find the directory name in the given string. <a href="group__qfits__filename.html#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__filename.html#ga1">qfits_get_base_name</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Find out the base name of a file (i.e. without prefix path). <a href="group__qfits__filename.html#ga1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__filename.html#ga2">qfits_get_root_name</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Find out the root part of a basename (name without extension). <a href="group__qfits__filename.html#ga2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__filename.html#ga3">qfits_get_ext_name</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Find out the extension of a file name. <a href="group__qfits__filename.html#ga3"></a><br></td></tr>
</table>
</body>
</html>

View File

@ -0,0 +1,263 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<div class="nav">
<a class="el" href="dir_000000.html">src</a></div>
<h1>qfits_header.c File Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Typedefs</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef <a class="el" href="struct__keytuple__.html">_keytuple_</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits__header_8c.html#a0">keytuple</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef enum <a class="el" href="qfits__header_8c.html#a56">_keytype_</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits__header_8c.html#a1">keytype</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Possible key types. <a href="#a1"></a><br></td></tr>
<tr><td colspan="2"><br><h2>Enumerations</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">enum &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits__header_8c.html#a56">_keytype_</a> { <br>
&nbsp;&nbsp;<a class="el" href="qfits__header_8c.html#a56a2">keytype_undef</a> = 0,
<a class="el" href="qfits__header_8c.html#a56a3">keytype_top</a> = 1,
<a class="el" href="qfits__header_8c.html#a56a4">keytype_bitpix</a> = 2,
<a class="el" href="qfits__header_8c.html#a56a5">keytype_naxis</a> = 3,
<br>
&nbsp;&nbsp;<a class="el" href="qfits__header_8c.html#a56a6">keytype_naxis1</a> = 11,
<a class="el" href="qfits__header_8c.html#a56a7">keytype_naxis2</a> = 12,
<a class="el" href="qfits__header_8c.html#a56a8">keytype_naxis3</a> = 13,
<a class="el" href="qfits__header_8c.html#a56a9">keytype_naxis4</a> = 14,
<br>
&nbsp;&nbsp;<a class="el" href="qfits__header_8c.html#a56a10">keytype_naxisi</a> = 20,
<a class="el" href="qfits__header_8c.html#a56a11">keytype_group</a> = 30,
<a class="el" href="qfits__header_8c.html#a56a12">keytype_pcount</a> = 31,
<a class="el" href="qfits__header_8c.html#a56a13">keytype_gcount</a> = 32,
<br>
&nbsp;&nbsp;<a class="el" href="qfits__header_8c.html#a56a14">keytype_extend</a> = 33,
<a class="el" href="qfits__header_8c.html#a56a15">keytype_bscale</a> = 34,
<a class="el" href="qfits__header_8c.html#a56a16">keytype_bzero</a> = 35,
<a class="el" href="qfits__header_8c.html#a56a17">keytype_tfields</a> = 36,
<br>
&nbsp;&nbsp;<a class="el" href="qfits__header_8c.html#a56a18">keytype_tbcoli</a> = 40,
<a class="el" href="qfits__header_8c.html#a56a19">keytype_tformi</a> = 41,
<a class="el" href="qfits__header_8c.html#a56a20">keytype_primary</a> = 100,
<a class="el" href="qfits__header_8c.html#a56a21">keytype_hierarch_dpr</a> = 200,
<br>
&nbsp;&nbsp;<a class="el" href="qfits__header_8c.html#a56a22">keytype_hierarch_obs</a> = 201,
<a class="el" href="qfits__header_8c.html#a56a23">keytype_hierarch_tpl</a> = 202,
<a class="el" href="qfits__header_8c.html#a56a24">keytype_hierarch_gen</a> = 203,
<a class="el" href="qfits__header_8c.html#a56a25">keytype_hierarch_tel</a> = 204,
<br>
&nbsp;&nbsp;<a class="el" href="qfits__header_8c.html#a56a26">keytype_hierarch_ins</a> = 205,
<a class="el" href="qfits__header_8c.html#a56a27">keytype_hierarch_det</a> = 206,
<a class="el" href="qfits__header_8c.html#a56a28">keytype_hierarch_log</a> = 207,
<a class="el" href="qfits__header_8c.html#a56a29">keytype_hierarch_pro</a> = 208,
<br>
&nbsp;&nbsp;<a class="el" href="qfits__header_8c.html#a56a30">keytype_hierarch</a> = 300,
<a class="el" href="qfits__header_8c.html#a56a31">keytype_history</a> = 400,
<a class="el" href="qfits__header_8c.html#a56a32">keytype_comment</a> = 500,
<a class="el" href="qfits__header_8c.html#a56a33">keytype_end</a> = 1000
<br>
}</td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga0">qfits_header_new</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">FITS header constructor. <a href="group__qfits__header.html#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga1">qfits_header_default</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">FITS header default constructor. <a href="group__qfits__header.html#ga1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga2">qfits_header_add</a> (qfits_header *hdr, const char *key, const char *val, const char *com, const char *lin)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Add a new card to a FITS header. <a href="group__qfits__header.html#ga2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga3">qfits_header_add_after</a> (qfits_header *hdr, const char *after, const char *key, const char *val, const char *com, const char *lin)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">add a new card to a FITS header <a href="group__qfits__header.html#ga3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga4">qfits_header_append</a> (qfits_header *hdr, const char *key, const char *val, const char *com, const char *lin)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Append a new card to a FITS header. <a href="group__qfits__header.html#ga4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga5">qfits_header_del</a> (qfits_header *hdr, const char *key)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Delete a card in a FITS header. <a href="group__qfits__header.html#ga5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga6">qfits_header_mod</a> (qfits_header *hdr, const char *key, const char *val, const char *com)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Modifies a FITS card. <a href="group__qfits__header.html#ga6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga7">qfits_header_sort</a> (qfits_header **hdr)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sort a FITS header. <a href="group__qfits__header.html#ga7"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga8">qfits_header_copy</a> (const qfits_header *src)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Copy a FITS header. <a href="group__qfits__header.html#ga8"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga9">qfits_header_destroy</a> (qfits_header *hdr)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">qfits_header destructor <a href="group__qfits__header.html#ga9"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga10">qfits_header_getstr</a> (const qfits_header *hdr, const char *key)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the value associated to a key, as a string. <a href="group__qfits__header.html#ga10"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga11">qfits_header_getitem</a> (const qfits_header *hdr, int idx, char *key, char *val, char *com, char *lin)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the i-th key/val/com/line tuple in a header. <a href="group__qfits__header.html#ga11"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga12">qfits_header_getcom</a> (const qfits_header *hdr, const char *key)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the comment associated to a key, as a string. <a href="group__qfits__header.html#ga12"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga13">qfits_header_getint</a> (const qfits_header *hdr, const char *key, int errval)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the value associated to a key, as an int. <a href="group__qfits__header.html#ga13"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">double&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga14">qfits_header_getdouble</a> (const qfits_header *hdr, const char *key, double errval)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the value associated to a key, as a double. <a href="group__qfits__header.html#ga14"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga15">qfits_header_getboolean</a> (const qfits_header *hdr, const char *key, int errval)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the value associated to a key, as a boolean (int). <a href="group__qfits__header.html#ga15"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__header.html#ga16">qfits_header_dump</a> (const qfits_header *hdr, FILE *out)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Dump a FITS header to an opened file. <a href="group__qfits__header.html#ga16"></a><br></td></tr>
</table>
<hr><h2>Typedef Documentation</h2>
<a class="anchor" name="a0" doxytag="qfits_header.c::keytuple"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">typedef struct <a class="el" href="struct__keytuple__.html">_keytuple_</a> <a class="el" href="struct__keytuple__.html">keytuple</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="a1" doxytag="qfits_header.c::keytype"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">typedef enum <a class="el" href="qfits__header_8c.html#a56">_keytype_</a> <a class="el" href="qfits__header_8c.html#a1">keytype</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Possible key types.
<p>
This enum stores all possible types for a FITS keyword. These determine the order of appearance in a header, they are a crucial point for DICB (ESO) compatibility. This classification is internal to this module. </td>
</tr>
</table>
<hr><h2>Enumeration Type Documentation</h2>
<a class="anchor" name="a56" doxytag="qfits_header.c::_keytype_"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">enum <a class="el" href="qfits__header_8c.html#a56">_keytype_</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
<dl compact><dt><b>Enumeration values: </b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"><em><a class="anchor" name="a56a2" doxytag="keytype_undef"></a>keytype_undef</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a3" doxytag="keytype_top"></a>keytype_top</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a4" doxytag="keytype_bitpix"></a>keytype_bitpix</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a5" doxytag="keytype_naxis"></a>keytype_naxis</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a6" doxytag="keytype_naxis1"></a>keytype_naxis1</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a7" doxytag="keytype_naxis2"></a>keytype_naxis2</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a8" doxytag="keytype_naxis3"></a>keytype_naxis3</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a9" doxytag="keytype_naxis4"></a>keytype_naxis4</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a10" doxytag="keytype_naxisi"></a>keytype_naxisi</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a11" doxytag="keytype_group"></a>keytype_group</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a12" doxytag="keytype_pcount"></a>keytype_pcount</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a13" doxytag="keytype_gcount"></a>keytype_gcount</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a14" doxytag="keytype_extend"></a>keytype_extend</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a15" doxytag="keytype_bscale"></a>keytype_bscale</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a16" doxytag="keytype_bzero"></a>keytype_bzero</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a17" doxytag="keytype_tfields"></a>keytype_tfields</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a18" doxytag="keytype_tbcoli"></a>keytype_tbcoli</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a19" doxytag="keytype_tformi"></a>keytype_tformi</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a20" doxytag="keytype_primary"></a>keytype_primary</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a21" doxytag="keytype_hierarch_dpr"></a>keytype_hierarch_dpr</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a22" doxytag="keytype_hierarch_obs"></a>keytype_hierarch_obs</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a23" doxytag="keytype_hierarch_tpl"></a>keytype_hierarch_tpl</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a24" doxytag="keytype_hierarch_gen"></a>keytype_hierarch_gen</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a25" doxytag="keytype_hierarch_tel"></a>keytype_hierarch_tel</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a26" doxytag="keytype_hierarch_ins"></a>keytype_hierarch_ins</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a27" doxytag="keytype_hierarch_det"></a>keytype_hierarch_det</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a28" doxytag="keytype_hierarch_log"></a>keytype_hierarch_log</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a29" doxytag="keytype_hierarch_pro"></a>keytype_hierarch_pro</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a30" doxytag="keytype_hierarch"></a>keytype_hierarch</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a31" doxytag="keytype_history"></a>keytype_history</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a32" doxytag="keytype_comment"></a>keytype_comment</em>&nbsp;</td><td>
</td></tr>
<tr><td valign="top"><em><a class="anchor" name="a56a33" doxytag="keytype_end"></a>keytype_end</em>&nbsp;</td><td>
</td></tr>
</table>
</dl>
</td>
</tr>
</table>
</body>
</html>

View File

@ -0,0 +1,73 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<div class="nav">
<a class="el" href="dir_000000.html">src</a></div>
<h1>qfits_image.c File Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__image.html#ga0">qfitsloader_init</a> (qfitsloader *ql)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Initialize a qfitsloader control object. <a href="group__qfits__image.html#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__image.html#ga1">qfits_loadpix</a> (qfitsloader *ql)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Load a pixel buffer for one complete image. <a href="group__qfits__image.html#ga1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__image.html#ga2">qfits_loadpix_window</a> (qfitsloader *ql, int llx, int lly, int urx, int ury)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Load a pixel buffer for one image window. <a href="group__qfits__image.html#ga2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__image.html#ga3">qfits_pixdump</a> (qfitsdumper *qd)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Dump a pixel buffer to an output FITS file in append mode. <a href="group__qfits__image.html#ga3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits__image_8c.html#a11">main</a> (int argc, char *argv[])</td></tr>
</table>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="a11" doxytag="qfits_image.c::main"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int main </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">int&nbsp;</td>
<td class="mdname" nowrap> <em>argc</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>char *&nbsp;</td>
<td class="mdname" nowrap> <em>argv</em>[]</td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
</body>
</html>

View File

@ -0,0 +1,24 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<div class="nav">
<a class="el" href="dir_000000.html">src</a></div>
<h1>qfits_md5.c File Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">const char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__md5.html#ga0">qfits_datamd5</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Compute the MD5 hash of data zones in a FITS file. <a href="group__qfits__md5.html#ga0"></a><br></td></tr>
</table>
</body>
</html>

View File

@ -0,0 +1,365 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<div class="nav">
<a class="el" href="dir_000000.html">src</a></div>
<h1>qfits_memory.c File Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="qfits__memory_8c.html#a33">qfits_memory_status_</a> (const char *, int)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga0">qfits_memory_malloc</a> (size_t size, const char *filename, int lineno)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Allocate memory. <a href="group__qfits__memory.html#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga1">qfits_memory_calloc</a> (size_t nmemb, size_t size, const char *filename, int lineno)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Allocate memory. <a href="group__qfits__memory.html#ga1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga2">qfits_memory_falloc</a> (char *name, size_t offs, size_t *size, const char *srcname, int srclin)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Map a file's contents to memory as a char pointer. <a href="group__qfits__memory.html#ga2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga3">qfits_memory_fdealloc</a> (void *ptr, size_t offs, size_t size, const char *filename, int lineno)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Free memory that has been allocated with falloc. <a href="group__qfits__memory.html#ga3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga4">qfits_memory_free</a> (void *ptr, const char *filename, int lineno)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Free memory. <a href="group__qfits__memory.html#ga4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga5">qfits_memory_realloc</a> (void *ptr, size_t size, const char *filename, int lineno)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Re-Allocate memory. <a href="group__qfits__memory.html#ga5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga6">qfits_memory_strdup</a> (const char *s, const char *filename, int lineno)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Duplicate a string using calloc. <a href="group__qfits__memory.html#ga6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga7">qfits_memory_status</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Display memory status information. <a href="group__qfits__memory.html#ga7"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__memory.html#ga8">qfits_memory_is_empty</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Tell if there is still some memory allocated. <a href="group__qfits__memory.html#ga8"></a><br></td></tr>
</table>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="a33" doxytag="qfits_memory.c::qfits_memory_status_"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void qfits_memory_status_ </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const char *&nbsp;</td>
<td class="mdname" nowrap>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>int&nbsp;</td>
<td class="mdname" nowrap></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<hr><h2>Variable Documentation</h2>
<a class="anchor" name="a6" doxytag="qfits_memory.c::alloc_max"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">size_t <a class="el" href="qfits__memory_8c.html#a6">alloc_max</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="a4" doxytag="qfits_memory.c::alloc_ram"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">size_t <a class="el" href="qfits__memory_8c.html#a4">alloc_ram</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="a5" doxytag="qfits_memory.c::alloc_swap"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">size_t <a class="el" href="qfits__memory_8c.html#a5">alloc_swap</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="a3" doxytag="qfits_memory.c::alloc_total"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">size_t <a class="el" href="qfits__memory_8c.html#a3">alloc_total</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="a9" doxytag="qfits_memory.c::file_reg"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="qfits__memory_8c.html#a9">file_reg</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="a7" doxytag="qfits_memory.c::max_cells"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="qfits__memory_8c.html#a7">max_cells</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="a10" doxytag="qfits_memory.c::n_mm_files"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="qfits__memory_8c.html#a10">n_mm_files</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="a11" doxytag="qfits_memory.c::n_mm_mappings"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="qfits__memory_8c.html#a11">n_mm_mappings</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="a2" doxytag="qfits_memory.c::ncells"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="qfits__memory_8c.html#a2">ncells</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="a8" doxytag="qfits_memory.c::nswapfiles"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="qfits__memory_8c.html#a8">nswapfiles</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="a12" doxytag="qfits_memory.c::pagesize"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="qfits__memory_8c.html#a12">pagesize</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="a13" doxytag="qfits_memory.c::rlimit_data"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="qfits__memory_8c.html#a13">rlimit_data</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
</body>
</html>

View File

@ -0,0 +1,45 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<div class="nav">
<a class="el" href="dir_000000.html">src</a></div>
<h1>qfits_rw.c File Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__rw.html#ga0">qfits_header_read</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Read a FITS header from a file to an internal structure. <a href="group__qfits__rw.html#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__rw.html#ga1">qfits_header_read_hdr</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Read a FITS header from a 'hdr' file. <a href="group__qfits__rw.html#ga1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__rw.html#ga2">qfits_header_read_hdr_string</a> (const unsigned char *hdr_str, int nb_char)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Read a FITS header from a 'hdr' string. <a href="group__qfits__rw.html#ga2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__rw.html#ga3">qfits_header_readext</a> (const char *filename, int xtnum)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Read an extension header from a FITS file. <a href="group__qfits__rw.html#ga3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__rw.html#ga4">qfits_zeropad</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Pad an existing file with zeros to a multiple of 2880. <a href="group__qfits__rw.html#ga4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__rw.html#ga5">qfits_is_fits</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Identify if a file is a FITS file. <a href="group__qfits__rw.html#ga5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__rw.html#ga6">qfits_get_hdrinfo</a> (const char *filename, int xtnum, int *seg_start, int *seg_size)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Retrieve offset to start and size of a header in a FITS file. <a href="group__qfits__rw.html#ga6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__rw.html#ga7">qfits_get_datinfo</a> (const char *filename, int xtnum, int *seg_start, int *seg_size)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Retrieve offset to start and size of a data section in a file. <a href="group__qfits__rw.html#ga7"></a><br></td></tr>
</table>
</body>
</html>

View File

@ -0,0 +1,69 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<div class="nav">
<a class="el" href="dir_000000.html">src</a></div>
<h1>qfits_table.c File Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga0">qfits_is_table</a> (const char *filename, int xtnum)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Identify a file as containing a FITS table in extension. <a href="group__qfits__table.html#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga1">qfits_table_prim_header_default</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Generate a default primary header to store tables. <a href="group__qfits__table.html#ga1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_header *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga2">qfits_table_ext_header_default</a> (const qfits_table *t)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Generate a default extension header to store tables. <a href="group__qfits__table.html#ga2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_table *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga3">qfits_table_new</a> (const char *filename, int table_type, int table_width, int nb_cols, int nb_raws)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Table object constructor. <a href="group__qfits__table.html#ga3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga4">qfits_col_fill</a> (qfits_col *qc, int atom_nb, int atom_dec_nb, int atom_size, tfits_type atom_type, const char *label, const char *unit, const char *nullval, const char *disp, int zero_present, float zero, int scale_present, float scale, int offset_beg)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Fill a column object with some provided informations. <a href="group__qfits__table.html#ga4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">qfits_table *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga5">qfits_table_open</a> (const char *filename, int xtnum)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Read a FITS extension. <a href="group__qfits__table.html#ga5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga6">qfits_table_close</a> (qfits_table *t)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Free a FITS table and associated pointers. <a href="group__qfits__table.html#ga6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">unsigned char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga7">qfits_query_column</a> (const qfits_table *th, int colnum, const int *selection)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Extract data from a column in a FITS table. <a href="group__qfits__table.html#ga7"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">unsigned char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga8">qfits_query_column_seq</a> (const qfits_table *th, int colnum, int start_ind, int nb_rows)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Extract consequtive values from a column in a FITS table. <a href="group__qfits__table.html#ga8"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga9">qfits_query_column_data</a> (const qfits_table *th, int colnum, const int *selection, const void *null_value)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Extract binary data from a column in a FITS table. <a href="group__qfits__table.html#ga9"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga10">qfits_query_column_seq_data</a> (const qfits_table *th, int colnum, int start_ind, int nb_rows, const void *null_value)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Extract binary data from a column in a FITS table. <a href="group__qfits__table.html#ga10"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga11">qfits_query_column_nulls</a> (const qfits_table *th, int colnum, const int *selection, int *nb_vals, int *nb_nulls)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Detect NULL values in a column. <a href="group__qfits__table.html#ga11"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga12">qfits_save_table_hdrdump</a> (const void **array, const qfits_table *table, const qfits_header *fh)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Save a table to a FITS file with a given FITS header. <a href="group__qfits__table.html#ga12"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga13">qfits_table_append_xtension</a> (FILE *outfile, const qfits_table *t, const void **data)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Appends a std extension header + data to a FITS table file. <a href="group__qfits__table.html#ga13"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga14">qfits_table_append_xtension_hdr</a> (FILE *outfile, const qfits_table *t, const void **data, const qfits_header *hdr)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Appends a specified extension header + data to a FITS table file. <a href="group__qfits__table.html#ga14"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__table.html#ga15">qfits_table_field_to_string</a> (const qfits_table *table, int col_id, int row_id, int use_zero_scale)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">given a col and a row, find out the string to write for display <a href="group__qfits__table.html#ga15"></a><br></td></tr>
</table>
</body>
</html>

View File

@ -0,0 +1,24 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<div class="nav">
<a class="el" href="dir_000000.html">src</a></div>
<h1>qfits_time.c File Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__time.html#ga0">qfits_get_datetime_iso8601</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the current date and time as a static string. <a href="group__qfits__time.html#ga0"></a><br></td></tr>
</table>
</body>
</html>

View File

@ -0,0 +1,63 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<div class="nav">
<a class="el" href="dir_000000.html">src</a></div>
<h1>qfits_tools.c File Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga0">qfits_query_hdr</a> (const char *filename, const char *keyword)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Retrieve the value of a key in a FITS header. <a href="group__qfits__tools.html#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga1">qfits_query_ext</a> (const char *filename, const char *keyword, int xtnum)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Retrieve the value of a keyin a FITS extension header. <a href="group__qfits__tools.html#ga1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga2">qfits_query_n_ext</a> (const char *filename)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Counts the number of extensions in a FITS file. <a href="group__qfits__tools.html#ga2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga3">qfits_query_nplanes</a> (const char *filename, int extnum)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Counts the number of planes in a FITS extension. <a href="group__qfits__tools.html#ga3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga4">qfits_pretty_string</a> (const char *s)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Clean out a FITS string value. <a href="group__qfits__tools.html#ga4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga5">qfits_is_boolean</a> (const char *s)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Identify if a FITS value is boolean. <a href="group__qfits__tools.html#ga5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga6">qfits_is_int</a> (const char *s)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Identify if a FITS value is an int. <a href="group__qfits__tools.html#ga6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga7">qfits_is_float</a> (const char *s)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Identify if a FITS value is float. <a href="group__qfits__tools.html#ga7"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga8">qfits_is_complex</a> (const char *s)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Identify if a FITS value is complex. <a href="group__qfits__tools.html#ga8"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga9">qfits_is_string</a> (const char *s)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Identify if a FITS value is string. <a href="group__qfits__tools.html#ga9"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga10">qfits_get_type</a> (const char *s)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Identify the type of a FITS value given as a string. <a href="group__qfits__tools.html#ga10"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga11">qfits_query_card</a> (const char *filename, const char *keyword)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Query a card in a FITS (main) header by a given key. <a href="group__qfits__tools.html#ga11"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga12">qfits_replace_card</a> (const char *filename, const char *keyword, const char *substitute)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Replace a card in a FITS (main) header by a given card. <a href="group__qfits__tools.html#ga12"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">const char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__qfits__tools.html#ga13">qfits_version</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the current QFITS version. <a href="group__qfits__tools.html#ga13"></a><br></td></tr>
</table>
</body>
</html>

View File

@ -0,0 +1,197 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>_keytuple_ Struct Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Fields</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__keytuple__.html#o0">key</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__keytuple__.html#o1">val</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__keytuple__.html#o2">com</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__keytuple__.html#o3">lin</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__keytuple__.html#o4">typ</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="struct__keytuple__.html">_keytuple_</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__keytuple__.html#o5">next</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="struct__keytuple__.html">_keytuple_</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__keytuple__.html#o6">prev</a></td></tr>
</table>
<hr><h2>Field Documentation</h2>
<a class="anchor" name="o2" doxytag="_keytuple_::com"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* <a class="el" href="struct__keytuple__.html#o2">_keytuple_::com</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Value, always as a string </td>
</tr>
</table>
<a class="anchor" name="o0" doxytag="_keytuple_::key"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* <a class="el" href="struct__keytuple__.html#o0">_keytuple_::key</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o3" doxytag="_keytuple_::lin"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* <a class="el" href="struct__keytuple__.html#o3">_keytuple_::lin</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Comment associated to key </td>
</tr>
</table>
<a class="anchor" name="o5" doxytag="_keytuple_::next"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">struct <a class="el" href="struct__keytuple__.html">_keytuple_</a>* <a class="el" href="struct__keytuple__.html#o5">_keytuple_::next</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Implemented as a doubly-linked list </td>
</tr>
</table>
<a class="anchor" name="o6" doxytag="_keytuple_::prev"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">struct <a class="el" href="struct__keytuple__.html">_keytuple_</a>* <a class="el" href="struct__keytuple__.html#o6">_keytuple_::prev</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o4" doxytag="_keytuple_::typ"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="struct__keytuple__.html#o4">_keytuple_::typ</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Initial line in FITS header if applicable </td>
</tr>
</table>
<a class="anchor" name="o1" doxytag="_keytuple_::val"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* <a class="el" href="struct__keytuple__.html#o1">_keytuple_::val</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Key: unique string in a list </td>
</tr>
</table>
<hr>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="qfits__header_8c.html">qfits_header.c</a></ul>
</body>
</html>

View File

@ -0,0 +1,297 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>QFITS Reference Manual 6.2.0</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>_qfits_cache_cell_ Struct Reference</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Fields</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__qfits__cache__cell__.html#o0">name</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">ino_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__qfits__cache__cell__.html#o1">inode</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">time_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__qfits__cache__cell__.html#o2">mtime</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__qfits__cache__cell__.html#o3">filesize</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">time_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__qfits__cache__cell__.html#o4">ctime</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__qfits__cache__cell__.html#o5">exts</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__qfits__cache__cell__.html#o6">ohdr</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__qfits__cache__cell__.html#o7">shdr</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__qfits__cache__cell__.html#o8">data</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__qfits__cache__cell__.html#o9">dsiz</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct__qfits__cache__cell__.html#o10">fsize</a></td></tr>
</table>
<hr><h2>Field Documentation</h2>
<a class="anchor" name="o4" doxytag="_qfits_cache_cell_::ctime"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">time_t <a class="el" href="struct__qfits__cache__cell__.html#o4">_qfits_cache_cell_::ctime</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o8" doxytag="_qfits_cache_cell_::data"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int* <a class="el" href="struct__qfits__cache__cell__.html#o8">_qfits_cache_cell_::data</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o9" doxytag="_qfits_cache_cell_::dsiz"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int* <a class="el" href="struct__qfits__cache__cell__.html#o9">_qfits_cache_cell_::dsiz</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o5" doxytag="_qfits_cache_cell_::exts"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="struct__qfits__cache__cell__.html#o5">_qfits_cache_cell_::exts</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o3" doxytag="_qfits_cache_cell_::filesize"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="struct__qfits__cache__cell__.html#o3">_qfits_cache_cell_::filesize</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o10" doxytag="_qfits_cache_cell_::fsize"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="struct__qfits__cache__cell__.html#o10">_qfits_cache_cell_::fsize</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o1" doxytag="_qfits_cache_cell_::inode"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">ino_t <a class="el" href="struct__qfits__cache__cell__.html#o1">_qfits_cache_cell_::inode</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o2" doxytag="_qfits_cache_cell_::mtime"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">time_t <a class="el" href="struct__qfits__cache__cell__.html#o2">_qfits_cache_cell_::mtime</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o0" doxytag="_qfits_cache_cell_::name"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* <a class="el" href="struct__qfits__cache__cell__.html#o0">_qfits_cache_cell_::name</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o6" doxytag="_qfits_cache_cell_::ohdr"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int* <a class="el" href="struct__qfits__cache__cell__.html#o6">_qfits_cache_cell_::ohdr</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o7" doxytag="_qfits_cache_cell_::shdr"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int* <a class="el" href="struct__qfits__cache__cell__.html#o7">_qfits_cache_cell_::shdr</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<hr>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="qfits__cache_8c.html">qfits_cache.c</a></ul>
</body>
</html>

View File

@ -1,383 +0,0 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>qfits 5.3.1</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>qfits_col Struct Reference</h1>Column object.
<a href="#_details">More...</a>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Fields</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__col.html#o0">atom_nb</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__col.html#o1">atom_dec_nb</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__col.html#o2">atom_size</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="qfits_8h.html#a4">tfits_type</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__col.html#o3">atom_type</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__col.html#o4">tlabel</a> [FITSVALSZ]</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__col.html#o5">tunit</a> [FITSVALSZ]</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__col.html#o6">nullval</a> [FITSVALSZ]</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__col.html#o7">tdisp</a> [FITSVALSZ]</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__col.html#o8">zero_present</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">float&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__col.html#o9">zero</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__col.html#o10">scale_present</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">float&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__col.html#o11">scale</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__col.html#o12">off_beg</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__col.html#o13">readable</a></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
Column object.
<p>
This structure contains all information needed to read a column in a table. These informations come from the header. The <a class="el" href="structqfits__table.html">qfits_table</a> object contains a list of qfits_col objects.<p>
This structure has to be created from scratch and filled if one want to generate a FITS table.
<p>
<hr><h2>Field Documentation</h2>
<a class="anchor" name="o1" doxytag="qfits_col::atom_dec_nb"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfits__col.html#o1">qfits_col::atom_dec_nb</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Number of decimals in a ASCII field. This value is always 0 for BIN tables </td>
</tr>
</table>
<a class="anchor" name="o0" doxytag="qfits_col::atom_nb"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfits__col.html#o0">qfits_col::atom_nb</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Number of atoms in one field. In ASCII tables, it is the number of characters in the field as defined in TFORM%d keyword. In BIN tables, it is the number of atoms in each field. For type 'A', it is the number of characters. A field with two complex object will have atom_nb = 4. </td>
</tr>
</table>
<a class="anchor" name="o2" doxytag="qfits_col::atom_size"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfits__col.html#o2">qfits_col::atom_size</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Size of one element in bytes. In ASCII tables, atom_size is the size of the element once it has been converted in its 'destination' type. For example, if "123" is contained in an ASCII table in a column defined as I type, atom_nb=3, atom_size=4. In ASCII tables:<ul>
<li>type 'A' : atom_size = atom_nb = number of chars</li><li>type 'I', 'F' or 'E' : atom_size = 4</li><li>type 'D' : atom_size = 8 In BIN tables :</li><li>type 'A', 'L', 'X', 'B': atom_size = 1</li><li>type 'I' : atom_size = 2</li><li>type 'E', 'J', 'C', 'P' : atom_size = 4</li><li>type 'D', 'M' : atom_size = 8 In ASCII table, there is one element per field. The size in bytes and in number of characters is atom_nb, and the size in bytes after conversion of the field is atom_size. In BIN tables, the size in bytes of a field is always atom_nb*atom_size.</li></ul>
</td>
</tr>
</table>
<a class="anchor" name="o3" doxytag="qfits_col::atom_type"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"><a class="el" href="qfits_8h.html#a4">tfits_type</a> <a class="el" href="structqfits__col.html#o3">qfits_col::atom_type</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Type of data in the column as specified in TFORM keyword In ASCII tables : TFITS_ASCII_TYPE_* with *=A, I, F, E or D In BIN tables : TFITS_BIN_TYPE_* with *=L, X, B, I, J, A, E, D, C, M or P </td>
</tr>
</table>
<a class="anchor" name="o6" doxytag="qfits_col::nullval"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char <a class="el" href="structqfits__col.html#o6">qfits_col::nullval</a>[FITSVALSZ] </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Null value </td>
</tr>
</table>
<a class="anchor" name="o12" doxytag="qfits_col::off_beg"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfits__col.html#o12">qfits_col::off_beg</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Offset between the beg. of the table and the beg. of the column. </td>
</tr>
</table>
<a class="anchor" name="o13" doxytag="qfits_col::readable"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfits__col.html#o13">qfits_col::readable</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Flag to know if the column is readable. An empty col is not readable </td>
</tr>
</table>
<a class="anchor" name="o11" doxytag="qfits_col::scale"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">float <a class="el" href="structqfits__col.html#o11">qfits_col::scale</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o10" doxytag="qfits_col::scale_present"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfits__col.html#o10">qfits_col::scale_present</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o7" doxytag="qfits_col::tdisp"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char <a class="el" href="structqfits__col.html#o7">qfits_col::tdisp</a>[FITSVALSZ] </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Display format </td>
</tr>
</table>
<a class="anchor" name="o4" doxytag="qfits_col::tlabel"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char <a class="el" href="structqfits__col.html#o4">qfits_col::tlabel</a>[FITSVALSZ] </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Label of the column </td>
</tr>
</table>
<a class="anchor" name="o5" doxytag="qfits_col::tunit"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char <a class="el" href="structqfits__col.html#o5">qfits_col::tunit</a>[FITSVALSZ] </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Unit of the data </td>
</tr>
</table>
<a class="anchor" name="o9" doxytag="qfits_col::zero"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">float <a class="el" href="structqfits__col.html#o9">qfits_col::zero</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o8" doxytag="qfits_col::zero_present"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfits__col.html#o8">qfits_col::zero_present</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
zero and scale are used when the quantity in the field does not represent a true physical quantity. Basically, thez should be used when they are present: physical_value = zero + scale * field_value They are read from TZERO and TSCAL in the header </td>
</tr>
</table>
<hr>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="qfits_8h.html">qfits.h</a></ul>
</body>
</html>

View File

@ -1,105 +0,0 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>qfits 5.3.1</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>qfits_header Struct Reference</h1>FITS header object.
<a href="#_details">More...</a>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Fields</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__header.html#o0">first</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__header.html#o1">last</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__header.html#o2">n</a></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
FITS header object.
<p>
This structure represents a FITS header in memory. It is actually no more than a thin layer on top of the keytuple object. No field in this structure should be directly modifiable by the user, only through accessor functions.
<p>
<hr><h2>Field Documentation</h2>
<a class="anchor" name="o0" doxytag="qfits_header::first"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void* <a class="el" href="structqfits__header.html#o0">qfits_header::first</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o1" doxytag="qfits_header::last"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void* <a class="el" href="structqfits__header.html#o1">qfits_header::last</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<a class="anchor" name="o2" doxytag="qfits_header::n"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfits__header.html#o2">qfits_header::n</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
</td>
</tr>
</table>
<hr>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="qfits_8h.html">qfits.h</a></ul>
</body>
</html>

View File

@ -1,199 +0,0 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>qfits 5.3.1</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>qfits_table Struct Reference</h1>Table object.
<a href="#_details">More...</a>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Fields</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__table.html#o0">filename</a> [FILENAMESZ]</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__table.html#o1">tab_t</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__table.html#o2">tab_w</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__table.html#o3">nc</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__table.html#o4">nr</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="structqfits__col.html">qfits_col</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfits__table.html#o5">col</a></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
Table object.
<p>
This structure contains all information needed to read a FITS table. These information come from the header. The object is created by qfits_open().<p>
To read a FITS table, here is a code example: <div class="fragment"><pre class="fragment"> <span class="keywordtype">int</span> main(<span class="keywordtype">int</span> argc, <span class="keywordtype">char</span>* argv[])
{
<a class="code" href="structqfits__table.html">qfits_table</a> * table ;
<span class="keywordtype">int</span> n_ext ;
<span class="keywordtype">int</span> i ;
<span class="comment">// Query the number of extensions</span>
n_ext = <a class="code" href="qfits_8h.html#a87">qfits_query_n_ext</a>(argv[1]) ;
<span class="comment">// For each extension</span>
<span class="keywordflow">for</span> (i=0 ; i&lt;n_ext ; i++) {
<span class="comment">// Read all the infos about the current table </span>
table = <a class="code" href="qfits_8h.html#a109">qfits_table_open</a>(argv[1], i+1) ;
<span class="comment">// Display the current table </span>
dump_extension(table, stdout, <span class="charliteral">'|'</span>, 1, 1) ;
}
return ;
}
</pre></div>
<p>
<hr><h2>Field Documentation</h2>
<a class="anchor" name="o5" doxytag="qfits_table::col"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"><a class="el" href="structqfits__col.html">qfits_col</a>* <a class="el" href="structqfits__table.html#o5">qfits_table::col</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Array of <a class="el" href="structqfits__col.html">qfits_col</a> objects </td>
</tr>
</table>
<a class="anchor" name="o0" doxytag="qfits_table::filename"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char <a class="el" href="structqfits__table.html#o0">qfits_table::filename</a>[FILENAMESZ] </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Name of the file the table comes from or it is intended to end to </td>
</tr>
</table>
<a class="anchor" name="o3" doxytag="qfits_table::nc"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfits__table.html#o3">qfits_table::nc</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Number of columns </td>
</tr>
</table>
<a class="anchor" name="o4" doxytag="qfits_table::nr"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfits__table.html#o4">qfits_table::nr</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Number of raws </td>
</tr>
</table>
<a class="anchor" name="o1" doxytag="qfits_table::tab_t"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfits__table.html#o1">qfits_table::tab_t</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Table type. Possible values: QFITS_INVALIDTABLE, QFITS_BINTABLE, QFITS_ASCIITABLE </td>
</tr>
</table>
<a class="anchor" name="o2" doxytag="qfits_table::tab_w"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfits__table.html#o2">qfits_table::tab_w</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Width in bytes of the table </td>
</tr>
</table>
<hr>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="qfits_8h.html">qfits.h</a></ul>
</body>
</html>

View File

@ -1,230 +0,0 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>qfits 5.3.1</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>qfitsdumper Struct Reference</h1>qfits dumper control object
<a href="#_details">More...</a>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Fields</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsdumper.html#o0">filename</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsdumper.html#o1">npix</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsdumper.html#o2">ptype</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsdumper.html#o3">ibuf</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">float *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsdumper.html#o4">fbuf</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">double *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsdumper.html#o5">dbuf</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsdumper.html#o6">out_ptype</a></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
qfits dumper control object
<p>
This structure offers various control parameters to dump a pixel buffer to a FITS file. The buffer will be dumped as requested to the requested file in append mode. Of course, the requested file must be writeable for the operation to succeed.<p>
The following example demonstrates how to save a linear ramp sized 100x100 to a FITS file with BITPIX=16. Notice that this code only dumps the pixel buffer, no header information is provided in this case.<p>
<div class="fragment"><pre class="fragment"> <span class="keywordtype">int</span> i, j ;
<span class="keywordtype">int</span> * ibuf ;
<a class="code" href="structqfitsdumper.html">qfitsdumper</a> qd ;
<span class="comment">// Fill a buffer with 100x100 int pixels</span>
ibuf = malloc(100 * 100 * <span class="keyword">sizeof</span>(<span class="keywordtype">int</span>));
<span class="keywordflow">for</span> (j=0 ; j&lt;100 ; j++) {
<span class="keywordflow">for</span> (i=0 ; i&lt;100 ; i++) {
ibuf[i+j*100] = i+j ;
}
}
qd.<a class="code" href="structqfitsdumper.html#o0">filename</a> = <span class="stringliteral">"out.fits"</span> ; <span class="comment">// Output file name</span>
qd.<a class="code" href="structqfitsdumper.html#o1">npix</a> = 100 * 100 ; <span class="comment">// Number of pixels</span>
qd.<a class="code" href="structqfitsdumper.html#o2">ptype</a> = PTYPE_INT ; <span class="comment">// Input buffer type</span>
qd.<a class="code" href="structqfitsdumper.html#o3">ibuf</a> = ibuf ; <span class="comment">// Set buffer pointer</span>
qd.<a class="code" href="structqfitsdumper.html#o6">out_ptype</a> = BPP_16_SIGNED ; <span class="comment">// Save with BITPIX=16</span>
<span class="comment">// Dump buffer to file (error checking omitted for clarity)</span>
<a class="code" href="qfits_8h.html#a78">qfits_pixdump</a>(&amp;qd);
free(ibuf);
</pre></div><p>
If the provided output file name is "STDOUT" (all capitals), the function will dump the pixels to the stdout steam (usually the console, could have been re-directed).
<p>
<hr><h2>Field Documentation</h2>
<a class="anchor" name="o5" doxytag="qfitsdumper::dbuf"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">double* <a class="el" href="structqfitsdumper.html#o5">qfitsdumper::dbuf</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Pointer to input double pixel buffer </td>
</tr>
</table>
<a class="anchor" name="o4" doxytag="qfitsdumper::fbuf"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">float* <a class="el" href="structqfitsdumper.html#o4">qfitsdumper::fbuf</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Pointer to input float pixel buffer </td>
</tr>
</table>
<a class="anchor" name="o0" doxytag="qfitsdumper::filename"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* <a class="el" href="structqfitsdumper.html#o0">qfitsdumper::filename</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Name of the file to dump to, "STDOUT" to dump to stdout </td>
</tr>
</table>
<a class="anchor" name="o3" doxytag="qfitsdumper::ibuf"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int* <a class="el" href="structqfitsdumper.html#o3">qfitsdumper::ibuf</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Pointer to input integer pixel buffer </td>
</tr>
</table>
<a class="anchor" name="o1" doxytag="qfitsdumper::npix"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfitsdumper.html#o1">qfitsdumper::npix</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Number of pixels in the buffer to dump </td>
</tr>
</table>
<a class="anchor" name="o6" doxytag="qfitsdumper::out_ptype"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfitsdumper.html#o6">qfitsdumper::out_ptype</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Requested BITPIX in output FITS file </td>
</tr>
</table>
<a class="anchor" name="o2" doxytag="qfitsdumper::ptype"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfitsdumper.html#o2">qfitsdumper::ptype</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Buffer type: PTYPE_FLOAT, PTYPE_INT or PTYPE_DOUBLE </td>
</tr>
</table>
<hr>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="qfits_8h.html">qfits.h</a></ul>
</body>
</html>

View File

@ -1,524 +0,0 @@
<html>
<head>
<meta name="keywords" content="eso, FITS format, C library">
<link href="doxygen.css" rel="stylesheet" type="text/css">
<title>qfits 5.3.1</title>
</head>
<body text="#000000" bgcolor="#ffffff">
<!-- Generated by Doxygen 1.4.1 -->
<h1>qfitsloader Struct Reference</h1>qfits loader control object
<a href="#_details">More...</a>
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Fields</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o0">_init</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o1">filename</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o2">xtnum</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o3">pnum</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o4">ptype</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o5">map</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o6">exts</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o7">lx</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o8">ly</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o9">np</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o10">bitpix</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o11">seg_start</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o12">seg_size</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">double&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o13">bscale</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">double&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o14">bzero</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o15">ibuf</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">float *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o16">fbuf</a></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">double *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structqfitsloader.html#o17">dbuf</a></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
qfits loader control object
<p>
This structure serves two purposes: input and output for the qfits pixel loading facility. To request pixels from a FITS file, you need to allocate (statically or dynamically) such a structure and fill up the input fields (filename, xtension number, etc.) to specify the pixels you want from the file.<p>
Before performing the actual load, you must pass the initialized structure to <a class="el" href="qfits_8h.html#a73">qfitsloader_init()</a> which will check whether the operation is feasible or not (check its returned value).<p>
If the operation was deemed feasible, you can proceed to load the pixels, passing the same structure to <a class="el" href="qfits_8h.html#a74">qfits_loadpix()</a> which will fill up the output fields of the struct. Notice that a pixel buffer will have been allocated (through malloc or mmap) and placed into the structure. You need to call free() on this pointer when you are done with it, typically in the image or cube destructor.<p>
The <a class="el" href="qfits_8h.html#a73">qfitsloader_init()</a> function is also useful to probe a FITS file for useful informations, like getting the size of images in the file, the pixel depth, or data offset.<p>
Example of a code that prints out various informations about a plane to load, without actually loading it:<p>
<div class="fragment"><pre class="fragment"><span class="keywordtype">int</span> main(<span class="keywordtype">int</span> argc, <span class="keywordtype">char</span> * argv[])
{
<a class="code" href="structqfitsloader.html">qfitsloader</a> ql ;
ql.<a class="code" href="structqfitsloader.html#o1">filename</a> = argv[1] ;
ql.<a class="code" href="structqfitsloader.html#o2">xtnum</a> = 0 ;
ql.<a class="code" href="structqfitsloader.html#o3">pnum</a> = 0 ;
<span class="keywordflow">if</span> (<a class="code" href="qfits_8h.html#a73">qfitsloader_init</a>(&amp;ql)!=0) {
printf(<span class="stringliteral">"cannot read info about %s\n"</span>, argv[1]);
<span class="keywordflow">return</span> -1 ;
}
printf( <span class="stringliteral">"file : %s\n"</span>
<span class="stringliteral">"xtnum : %d\n"</span>
<span class="stringliteral">"pnum : %d\n"</span>
<span class="stringliteral">"# xtensions : %d\n"</span>
<span class="stringliteral">"size X : %d\n"</span>
<span class="stringliteral">"size Y : %d\n"</span>
<span class="stringliteral">"planes : %d\n"</span>
<span class="stringliteral">"bitpix : %d\n"</span>
<span class="stringliteral">"datastart : %d\n"</span>
<span class="stringliteral">"datasize : %d\n"</span>
<span class="stringliteral">"bscale : %g\n"</span>
<span class="stringliteral">"bzero : %g\n"</span>,
ql.<a class="code" href="structqfitsloader.html#o1">filename</a>,
ql.<a class="code" href="structqfitsloader.html#o2">xtnum</a>,
ql.<a class="code" href="structqfitsloader.html#o3">pnum</a>,
ql.<a class="code" href="structqfitsloader.html#o6">exts</a>,
ql.<a class="code" href="structqfitsloader.html#o7">lx</a>,
ql.<a class="code" href="structqfitsloader.html#o8">ly</a>,
ql.<a class="code" href="structqfitsloader.html#o9">np</a>,
ql.<a class="code" href="structqfitsloader.html#o10">bitpix</a>,
ql.<a class="code" href="structqfitsloader.html#o11">seg_start</a>,
ql.<a class="code" href="structqfitsloader.html#o12">seg_size</a>,
ql.<a class="code" href="structqfitsloader.html#o13">bscale</a>,
ql.<a class="code" href="structqfitsloader.html#o14">bzero</a>);
<span class="keywordflow">return</span> 0 ;
}
</pre></div>
<p>
<hr><h2>Field Documentation</h2>
<a class="anchor" name="o0" doxytag="qfitsloader::_init"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfitsloader.html#o0">qfitsloader::_init</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Private field to see if structure has been initialized </td>
</tr>
</table>
<a class="anchor" name="o10" doxytag="qfitsloader::bitpix"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfitsloader.html#o10">qfitsloader::bitpix</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
output: BITPIX for this extension </td>
</tr>
</table>
<a class="anchor" name="o13" doxytag="qfitsloader::bscale"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">double <a class="el" href="structqfitsloader.html#o13">qfitsloader::bscale</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
output: BSCALE found for this extension </td>
</tr>
</table>
<a class="anchor" name="o14" doxytag="qfitsloader::bzero"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">double <a class="el" href="structqfitsloader.html#o14">qfitsloader::bzero</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
output: BZERO found for this extension </td>
</tr>
</table>
<a class="anchor" name="o17" doxytag="qfitsloader::dbuf"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">double* <a class="el" href="structqfitsloader.html#o17">qfitsloader::dbuf</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
output: Pointer to pixel buffer loaded as double values </td>
</tr>
</table>
<a class="anchor" name="o6" doxytag="qfitsloader::exts"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfitsloader.html#o6">qfitsloader::exts</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
output: Total number of extensions found in file </td>
</tr>
</table>
<a class="anchor" name="o16" doxytag="qfitsloader::fbuf"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">float* <a class="el" href="structqfitsloader.html#o16">qfitsloader::fbuf</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
output: Pointer to pixel buffer loaded as float values </td>
</tr>
</table>
<a class="anchor" name="o1" doxytag="qfitsloader::filename"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">char* <a class="el" href="structqfitsloader.html#o1">qfitsloader::filename</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
input: Name of the file you want to read pixels from </td>
</tr>
</table>
<a class="anchor" name="o15" doxytag="qfitsloader::ibuf"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int* <a class="el" href="structqfitsloader.html#o15">qfitsloader::ibuf</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
output: Pointer to pixel buffer loaded as integer values </td>
</tr>
</table>
<a class="anchor" name="o7" doxytag="qfitsloader::lx"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfitsloader.html#o7">qfitsloader::lx</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
output: Size in X of the requested plane </td>
</tr>
</table>
<a class="anchor" name="o8" doxytag="qfitsloader::ly"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfitsloader.html#o8">qfitsloader::ly</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
output: Size in Y of the requested plane </td>
</tr>
</table>
<a class="anchor" name="o5" doxytag="qfitsloader::map"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfitsloader.html#o5">qfitsloader::map</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
input: Guarantee file copy or allow file mapping </td>
</tr>
</table>
<a class="anchor" name="o9" doxytag="qfitsloader::np"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfitsloader.html#o9">qfitsloader::np</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
output: Number of planes present in this extension </td>
</tr>
</table>
<a class="anchor" name="o3" doxytag="qfitsloader::pnum"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfitsloader.html#o3">qfitsloader::pnum</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
input: Index of the plane you want, from 0 to np-1 </td>
</tr>
</table>
<a class="anchor" name="o4" doxytag="qfitsloader::ptype"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfitsloader.html#o4">qfitsloader::ptype</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
input: Pixel type you want (PTYPE_FLOAT, PTYPE_INT or PTYPE_DOUBLE) </td>
</tr>
</table>
<a class="anchor" name="o12" doxytag="qfitsloader::seg_size"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfitsloader.html#o12">qfitsloader::seg_size</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
output: Size of the data segment (in bytes) for your request </td>
</tr>
</table>
<a class="anchor" name="o11" doxytag="qfitsloader::seg_start"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfitsloader.html#o11">qfitsloader::seg_start</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
output: Start of the data segment (in bytes) for your request </td>
</tr>
</table>
<a class="anchor" name="o2" doxytag="qfitsloader::xtnum"></a><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">int <a class="el" href="structqfitsloader.html#o2">qfitsloader::xtnum</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
input: xtension number you want to read </td>
</tr>
</table>
<hr>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="qfits_8h.html">qfits.h</a></ul>
</body>
</html>

File diff suppressed because it is too large Load Diff

View File

@ -1,79 +0,0 @@
/*----------------------------------------------------------------------------*/
/**
@file xmemory.h
@author Nicolas Devillard
@date Oct 2000
@version $Revision: 1.24 $
@brief POSIX-compatible extended memory handling.
xmemory is a small and efficient module offering memory extension
capabitilies to ANSI C programs running on POSIX-compliant systems. It
offers several useful features such as memory leak detection, protection for
free on NULL or unallocated pointers, and virtually unlimited memory space.
xmemory requires the @c mmap() system call to be implemented in the local C
library to function. This module has been tested on a number of current Unix
flavours and is reported to work fine.
The current limitation is the limited number of pointers it can handle at
the same time.
See the documentation attached to this module for more information.
*/
/*----------------------------------------------------------------------------*/
/*
$Id: xmemory.h,v 1.24 2005/05/18 14:38:01 yjung Exp $
$Author: yjung $
$Date: 2005/05/18 14:38:01 $
$Revision: 1.24 $
*/
#ifndef XMEMORY_H
#define XMEMORY_H
/*-----------------------------------------------------------------------------
Includes
-----------------------------------------------------------------------------*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
/*-----------------------------------------------------------------------------
Defines
-----------------------------------------------------------------------------*/
/* To know if the current module has been linked against xmemory.c or not */
#define _XMEMORY_ 1
/*-----------------------------------------------------------------------------
Macros
-----------------------------------------------------------------------------*/
/* Protect strdup redefinition on systems which #define it */
#ifdef strdup
#undef strdup
#endif
#define malloc(s) xmemory_malloc(s, __FILE__,__LINE__)
#define calloc(n,s) xmemory_calloc(n,s, __FILE__,__LINE__)
#define realloc(p,s) xmemory_realloc(p,s, __FILE__,__LINE__)
#define free(p) xmemory_free(p, __FILE__,__LINE__)
#define strdup(s) xmemory_strdup(s, __FILE__,__LINE__)
#define falloc(f,o,s) xmemory_falloc(f,o,s, __FILE__,__LINE__)
#define fdealloc(f,o,s) xmemory_fdealloc(f,o,s, __FILE__,__LINE__)
#define xmemory_status() xmemory_status_(__FILE__,__LINE__)
/*-----------------------------------------------------------------------------
Function prototypes
-----------------------------------------------------------------------------*/
void * xmemory_malloc(size_t, const char *, int) ;
void * xmemory_calloc(size_t, size_t, const char *, int) ;
void * xmemory_realloc(void *, size_t, const char *, int) ;
void xmemory_free(void *, const char *, int) ;
char * xmemory_strdup(const char *, const char *, int) ;
char * xmemory_falloc(char *, size_t, size_t *, const char *, int) ;
void xmemory_fdealloc(void *, size_t, size_t, const char *, int) ;
void xmemory_status_(const char * filename, int lineno) ;
#endif

Binary file not shown.

View File

@ -1,39 +0,0 @@
all clean: refman.dvi
ps: refman.ps
pdf: refman.pdf
ps_2on1: refman_2on1.ps
pdf_2on1: refman_2on1.pdf
refman.ps: refman.dvi
dvips -o refman.ps refman.dvi
refman.pdf: refman.ps
ps2pdf refman.ps refman.pdf
refman.dvi: refman.tex doxygen.sty
echo "Running latex..."
latex refman.tex
echo "Running makeindex..."
makeindex refman.idx
echo "Rerunning latex...."
latex refman.tex
latex_count=5 ; \
while egrep -s 'Rerun (LaTeX|to get cross-references right)' refman.log && [ $$latex_count -gt 0 ] ;\
do \
echo "Rerunning latex...." ;\
latex refman.tex ;\
latex_count=`expr $$latex_count - 1` ;\
done
refman_2on1.ps: refman.ps
psnup -2 refman.ps >refman_2on1.ps
refman_2on1.pdf: refman_2on1.ps
ps2pdf refman_2on1.ps refman_2on1.pdf
clean:
rm -f *.ps *.dvi *.aux *.toc *.idx *.ind *.ilg *.log *.out refman.pdf

View File

@ -1,8 +0,0 @@
\section{qfits Data Structures}
Here are the data structures with brief descriptions:\begin{CompactList}
\item\contentsline{section}{{\bf qfits\_\-col} (Column object )}{\pageref{structqfits__col}}{}
\item\contentsline{section}{{\bf qfits\_\-header} (FITS header object )}{\pageref{structqfits__header}}{}
\item\contentsline{section}{{\bf qfits\_\-table} (Table object )}{\pageref{structqfits__table}}{}
\item\contentsline{section}{{\bf qfitsdumper} (Qfits dumper control object )}{\pageref{structqfitsdumper}}{}
\item\contentsline{section}{{\bf qfitsloader} (Qfits loader control object )}{\pageref{structqfitsloader}}{}
\end{CompactList}

View File

@ -1,7 +0,0 @@
\section{/home/yjung/tmp/qfits/include/ Directory Reference}
\label{dir_000000}\index{/home/yjung/tmp/qfits/include/ Directory Reference@{/home/yjung/tmp/qfits/include/ Directory Reference}}
\subsection*{Files}
\begin{CompactItemize}
\item
file {\bf qfits.h}
\end{CompactItemize}

View File

@ -1,4 +0,0 @@
\section{qfits Directories}
This directory hierarchy is sorted roughly, but not completely, alphabetically:\begin{CompactList}
\item \contentsline{section}{include}{\pageref{dir_000000}}{}
\end{CompactList}

View File

@ -1,64 +0,0 @@
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{doxygen}
\RequirePackage{calc}
\RequirePackage{array}
\pagestyle{fancyplain}
\newcommand{\clearemptydoublepage}{\newpage{\pagestyle{empty}\cleardoublepage}}
\renewcommand{\chaptermark}[1]{\markboth{#1}{}}
\renewcommand{\sectionmark}[1]{\markright{\thesection\ #1}}
\lhead[\fancyplain{}{\bfseries\thepage}]
{\fancyplain{}{\bfseries\rightmark}}
\rhead[\fancyplain{}{\bfseries\leftmark}]
{\fancyplain{}{\bfseries\thepage}}
\rfoot[\fancyplain{}{\bfseries\scriptsize Generated on Mon Jul 25 17:39:15 2005 for qfits by Doxygen }]{}
\lfoot[]{\fancyplain{}{\bfseries\scriptsize Generated on Mon Jul 25 17:39:15 2005 for qfits by Doxygen }}
\cfoot{}
\newenvironment{CompactList}
{\begin{list}{}{
\setlength{\leftmargin}{0.5cm}
\setlength{\itemsep}{0pt}
\setlength{\parsep}{0pt}
\setlength{\topsep}{0pt}
\renewcommand{\makelabel}{}}}
{\end{list}}
\newenvironment{CompactItemize}
{
\begin{itemize}
\setlength{\itemsep}{-3pt}
\setlength{\parsep}{0pt}
\setlength{\topsep}{0pt}
\setlength{\partopsep}{0pt}
}
{\end{itemize}}
\newcommand{\PBS}[1]{\let\temp=\\#1\let\\=\temp}
\newlength{\tmplength}
\newenvironment{TabularC}[1]
{
\setlength{\tmplength}
{\linewidth/(#1)-\tabcolsep*2-\arrayrulewidth*(#1+1)/(#1)}
\par\begin{tabular*}{\linewidth}
{*{#1}{|>{\PBS\raggedright\hspace{0pt}}p{\the\tmplength}}|}
}
{\end{tabular*}\par}
\newcommand{\entrylabel}[1]{
{\parbox[b]{\labelwidth-4pt}{\makebox[0pt][l]{\textbf{#1}}\\}}}
\newenvironment{Desc}
{\begin{list}{}
{
\settowidth{\labelwidth}{40pt}
\setlength{\leftmargin}{\labelwidth}
\setlength{\parsep}{0pt}
\setlength{\itemsep}{-4pt}
\renewcommand{\makelabel}{\entrylabel}
}
}
{\end{list}}
\newenvironment{Indent}
{\begin{list}{}{\setlength{\leftmargin}{0.5cm}}
\item[]\ignorespaces}
{\unskip\end{list}}
\setlength{\parindent}{0cm}
\setlength{\parskip}{0.2cm}
\addtocounter{secnumdepth}{1}
\sloppy
\usepackage[T1]{fontenc}

View File

@ -1,5 +0,0 @@
\section{qfits File List}
Here is a list of all files with brief descriptions:\begin{CompactList}
\item\contentsline{section}{{\bf qfits.h} }{\pageref{qfits_8h}}{}
\item\contentsline{section}{{\bf qfits.head} }{\pageref{qfits_8head}}{}
\end{CompactList}

View File

@ -1,477 +0,0 @@
\section{Introduction}\label{index_welcome}
{\bf qfits} is a stand-alone library written in C to interact with files complying with the FITS format. It is fast and portable over any kind of POSIX-compliant platform.
Rather than going through the FITS format specification and trying to implement some support for everything that is described there, this library was built day after day upon request. This guarantees that all the functions you will find in the library have been written for some purpose in the VLT pipeline context, and all of them are used daily in a production environment.
Functionalities offered by this library are:
\begin{itemize}
\item Header queries (get keywords, values).\item Header manipulation (load/modify/save).\item Header/data offset queries.\item Pixel loading/saving to memory.\item Support for files of any dimension (NAXIS).\item Support for FITS extensions, including ASCII and binary tables.\end{itemize}
This library also comes with a limited set of interfaces to Python to make some of its functionalities usable from this language. See the compilation instructions to build it as a Python module. The Qfits.py module contains its own doc.
\section{History}\label{index_history}
{\bf qfits} was born from the need to have a simple but powerful C library to handle FITS file access. There are already many libraries on the Net to handle FITS files, but they tend to be bloated with far too many features and may raise portability and maintenance issues.
{\bf qfits} was written to take care of all low-level aspects of the FITS format, and only these. You will find there a wealth of optimized functions to access everything inside FITS files, but nothing about what you could do with the data: this is left to other (e.g. image processing) libraries. There is no suggested image or cube type, and the table object only loads the data without trying to interpret them.
The idea is that people wanting to work with FITS might have different requirements: somebody writing an image viewer might just want to load a pixel buffer, somebody handling headers only might want to have easy access to header information without touching pixel data. {\bf qfits} allows you to get your hands on what is contained in a FITS file but does not force you to use any specific high-level data type to describe your data.
\section{Authors}\label{index_authors}
Nicolas Devillard and Yves Jung, ESO.
\section{Header handling}\label{index_header}
This section gives you an overview of the functionalities offered to work on FITS headers with {\bf qfits}. For a complete reference, check out the reference manual: {\bf qfits.h}{\rm (p.\,\pageref{qfits_8h})}.
FITS headers are simply formatted as 80-char lines ({\em cards\/}) containing ancillary data represented in ASCII format like:
keyword = value / comment
If you want to retrieve data from a FITS file header, you will find various useful query routines to get a keyword value from main or extension headers. Values are returned as strings and not coerced to any particular (e.g. numerical) type. See e.g.
\begin{itemize}
\item {\bf qfits\_\-query\_\-hdr()}{\rm (p.\,\pageref{qfits_8h_a85})} to query the main header.\item {\bf qfits\_\-query\_\-ext()}{\rm (p.\,\pageref{qfits_8h_a86})} to query an extension header.\item {\bf qfits\_\-query\_\-n\_\-ext()}{\rm (p.\,\pageref{qfits_8h_a87})} to get the number of extensions.\end{itemize}
You may also want to handle file inputs by yourself and have FITS cards split into their components key/value/comment. See e.g.
\begin{itemize}
\item {\bf qfits\_\-getkey()}{\rm (p.\,\pageref{qfits_8h_a52})} to extract the key from a FITS line.\item {\bf qfits\_\-getvalue()}{\rm (p.\,\pageref{qfits_8h_a53})} to extract the value.\item {\bf qfits\_\-getcomment()}{\rm (p.\,\pageref{qfits_8h_a54})} to extract the comment.\end{itemize}
Since all FITS values are returned as strings, you may need to identify types. See e.g.
\begin{itemize}
\item {\bf qfits\_\-get\_\-type()}{\rm (p.\,\pageref{qfits_8h_a95})} to identify a value type\item {\bf qfits\_\-is\_\-boolean()}{\rm (p.\,\pageref{qfits_8h_a90})}\item {\bf qfits\_\-is\_\-int()}{\rm (p.\,\pageref{qfits_8h_a91})}\item {\bf qfits\_\-is\_\-float()}{\rm (p.\,\pageref{qfits_8h_a92})}\item {\bf qfits\_\-is\_\-complex()}{\rm (p.\,\pageref{qfits_8h_a93})}\item {\bf qfits\_\-is\_\-string()}{\rm (p.\,\pageref{qfits_8h_a94})}\end{itemize}
Of course, you can use the usual {\tt atof()}, {\tt atoi()} and {\tt scanf()} functions to convert a string to a numerical type.
You may also want to perform more complex operations on FITS headers, like loading one, modifying it and saving it back to a new file. The {\bf qfits\_\-header}{\rm (p.\,\pageref{structqfits__header})} data structure is offered for that purpose. It comes with utilities like:
\begin{itemize}
\item {\bf qfits\_\-header\_\-read()}{\rm (p.\,\pageref{qfits_8h_a55})} to load a header.\item {\bf qfits\_\-header\_\-readext()}{\rm (p.\,\pageref{qfits_8h_a58})} same from an extension.\item {\bf qfits\_\-header\_\-dump()}{\rm (p.\,\pageref{qfits_8h_a48})} to save a header to a file.\item ...\end{itemize}
And of course all manipulation tools you can think of:
\begin{itemize}
\item {\bf qfits\_\-header\_\-add()}{\rm (p.\,\pageref{qfits_8h_a29})}\item {\bf qfits\_\-header\_\-add\_\-after()}{\rm (p.\,\pageref{qfits_8h_a30})}\item {\bf qfits\_\-header\_\-append()}{\rm (p.\,\pageref{qfits_8h_a31})}\item {\bf qfits\_\-header\_\-mod()}{\rm (p.\,\pageref{qfits_8h_a33})}\item {\bf qfits\_\-header\_\-del()}{\rm (p.\,\pageref{qfits_8h_a32})}\item ...\end{itemize}
There are other functions to create new FITS cards, dump a header to screen for debugging purposes, etc. See the reference manual ({\bf qfits.h}{\rm (p.\,\pageref{qfits_8h})}) for an exhaustive description.
An important feature of the {\bf qfits\_\-header}{\rm (p.\,\pageref{structqfits__header})} object when loaded from a file, is that it keeps the memory of the initial FITS card. The data structure that is carried around for each FITS card contains:
\begin{itemize}
\item Identified keyword\item Identified value\item Possible comment\item Line as read from initial file when applicable.\end{itemize}
This feature is fairly useful if you want to perform header manipulation without getting too intrusive. You can use this to load a header, modify a couple of cards and dump all back to disk. The dumped header will only be modified for the cards you have touched, all others will be forwarded verbatim as they appeared in the initial file. This least-modification policy ensures that you will not modify the lines you do not need to touch.
This feature can be turned off by \char`\"{}touching\char`\"{} all lines in a header using {\bf qfits\_\-header\_\-touchall()}{\rm (p.\,\pageref{qfits_8h_a36})}, which removes all initial line information from a {\bf qfits\_\-header}{\rm (p.\,\pageref{structqfits__header})} object. This is useful to force a reformatting of a FITS header e.g. when the file header is damaged.
Notice that ESO's {\tt HIERARCH} keywords and DICB ordering are natively supported by {\bf qfits}, i.e. when you work with {\bf qfits\_\-header}{\rm (p.\,\pageref{structqfits__header})} objects you can be sure that they will properly recognize and sort keywords following ESO conventions.
\section{Data handling}\label{index_data}
This section gives you an overview of the functionalities offered to work on FITS data segments with {\bf qfits}. For a complete reference, check out the reference manual ({\bf qfits.h}{\rm (p.\,\pageref{qfits_8h})}).
Data segments are quite simply stored: they always contain data contiguously in uncompressed format, so reading them is mostly a matter of applying an {\tt fread()} statement at the right place in the file, with the right size. To find out about offsets to data and header parts in a FITS file (possibly containing several extensions), you can make use of:
\begin{itemize}
\item {\bf qfits\_\-get\_\-hdrinfo()}{\rm (p.\,\pageref{qfits_8h_a96})} to return information about a header position and size (in bytes) in a file.\item {\bf qfits\_\-get\_\-datinfo()}{\rm (p.\,\pageref{qfits_8h_a97})} to return information about a data segment position and size (in bytes) in a file.\end{itemize}
{\bf qfits} includes a caching mechanism to speed up accesses to large files to an optimal access time (only one parsing of the file is needed, even with multiple queries on the same file). This mechanism is internal to this module and invisible to the programmer using {\bf qfits}. This means that you can loop on all sections on a huge file to retrieve file offsets for each extension, and pay the price of file parsing only at the first call.
If you want to dive further into data loading, you may want to have a look at table and image handling functionalities.\subsection{Table handling}\label{index_table}
A table is stored in a FITS file in an extension. The extension header contains all needed informations to read the data (number of columns, the column types, the columns labels, the columns unit, etc...).
A FITS table is composed by columns. Within one column there can only be data of one defined type, but you can store several values by field.
In BINARY tables, you can find 11 different data types, in ASCII tables, there are 5 different types. All these types are supported by {\bf qfits:} \begin{itemize}
\item ASCII tables:\begin{itemize}
\item TFITS\_\-ASCII\_\-TYPE\_\-A : Characters (1 byte)\item TFITS\_\-ASCII\_\-TYPE\_\-D : Double (8 bytes)\item TFITS\_\-ASCII\_\-TYPE\_\-E : Float (4 bytes)\item TFITS\_\-ASCII\_\-TYPE\_\-F : Float (4 bytes)\item TFITS\_\-ASCII\_\-TYPE\_\-I : Integer (4 bytes)\end{itemize}
\item BIN tables:\begin{itemize}
\item TFITS\_\-BIN\_\-TYPE\_\-A : Characters (1 byte)\item TFITS\_\-BIN\_\-TYPE\_\-B : Unsigned byte (1 byte)\item TFITS\_\-BIN\_\-TYPE\_\-C : Float complex (2 $\ast$ 4 bytes)\item TFITS\_\-BIN\_\-TYPE\_\-D : Double (8 bytes)\item TFITS\_\-BIN\_\-TYPE\_\-E : Float (4 bytes)\item TFITS\_\-BIN\_\-TYPE\_\-I : Short (2 bytes)\item TFITS\_\-BIN\_\-TYPE\_\-J : Integer (4 bytes)\item TFITS\_\-BIN\_\-TYPE\_\-L : Logical (1 byte)\item TFITS\_\-BIN\_\-TYPE\_\-M : Double complex (2 $\ast$ 8 bytes)\item TFITS\_\-BIN\_\-TYPE\_\-P : Array descriptor (2 $\ast$ 4 bytes)\item TFITS\_\-BIN\_\-TYPE\_\-X : Bit (1 bit)\end{itemize}
\end{itemize}
The {\bf qfits\_\-table}{\rm (p.\,\pageref{structqfits__table})} object provided by {\bf qfits} contains all necessary informations to define how the data are stored in the file: the name of the file it comes from, the table type (QFITS\_\-BINTABLE or QFITS\_\-ASCIITABLE), the number of columns and for each column a pointer to a {\bf qfits\_\-col}{\rm (p.\,\pageref{structqfits__col})} object.
Each {\bf qfits\_\-col}{\rm (p.\,\pageref{structqfits__col})} object contains informations defining the associated column: the type (e.g. TFITS\_\-BIN\_\-TYPE\_\-L), the number of rows, the number of atoms per field, the label, the unit, etc...).
This {\bf qfits\_\-table}{\rm (p.\,\pageref{structqfits__table})} object is returned by {\bf qfits\_\-table\_\-open()}{\rm (p.\,\pageref{qfits_8h_a109})} and should only be destroyed with {\bf qfits\_\-table\_\-close()}{\rm (p.\,\pageref{qfits_8h_a110})}.
This {\bf qfits\_\-table}{\rm (p.\,\pageref{structqfits__table})} object does not contain the table data, but has to be used to load the data with functions like:
\begin{itemize}
\item {\bf qfits\_\-query\_\-column()}{\rm (p.\,\pageref{qfits_8h_a111})}\item {\bf qfits\_\-query\_\-column\_\-data()}{\rm (p.\,\pageref{qfits_8h_a114})}\item {\bf qfits\_\-query\_\-column\_\-nulls()}{\rm (p.\,\pageref{qfits_8h_a116})}\end{itemize}
{\bf qfits\_\-query\_\-column()}{\rm (p.\,\pageref{qfits_8h_a111})} returns you simply the data (byte swapped if necessary) as they were read in the file as a byte array. It is up to the user to interpret the data (e.g. to try to find out where the NULL values are).
{\bf qfits\_\-query\_\-column\_\-data()}{\rm (p.\,\pageref{qfits_8h_a114})} does the same, but identifies the NULL values and replaces them by a user-provided value. In this case, the returned array is an array of data of the right type. It is returned as a void$\ast$, the user just has to cast it to a double$\ast$, a short$\ast$ or what is needed.
For example, if you require in a table that contains 15 rows a column where you can find 3 values of type TFITS\_\-BIN\_\-TYPE\_\-M (double complex), {\bf qfits\_\-query\_\-column\_\-data()}{\rm (p.\,\pageref{qfits_8h_a114})} will return an array of 15 $\ast$ 3 $\ast$ 2 double values.
{\bf qfits} also provides functions to write a table to a FITS file ({\bf qfits\_\-save\_\-table\_\-hdrdump()}{\rm (p.\,\pageref{qfits_8h_a117})}), or to print out a table value or a complete table on the screen or in a file ({\bf qfits\_\-table\_\-field\_\-to\_\-string()}{\rm (p.\,\pageref{qfits_8h_a120})}).\subsection{Image handling}\label{index_image}
The qfitsloader and qfitsdumper objects are offered to simplify the action of reading/writing image data. The corresponding operators take care of retrieving all necessary ancillary information (image size, pixel type, buffer position), perform a memory allocation or mapping and read the file into memory. See the following functions:
\begin{itemize}
\item {\bf qfitsloader\_\-init()}{\rm (p.\,\pageref{qfits_8h_a73})} to initialize a loader object.\item {\bf qfits\_\-loadpix()}{\rm (p.\,\pageref{qfits_8h_a74})} to load pixel data into memory.\item {\bf qfits\_\-pixdump()}{\rm (p.\,\pageref{qfits_8h_a78})} to save pixel data to disk.\end{itemize}
As for tables, the idea is that you first launch an analysis of the file to get back a number of informations about what is present there. In the case of images, you use {\bf qfitsloader\_\-init()}{\rm (p.\,\pageref{qfits_8h_a73})} to see if pixel loading could be done, then use {\bf qfits\_\-loadpix()}{\rm (p.\,\pageref{qfits_8h_a74})} to perform the actual load.
Pixel I/O are taking place in float, int or double format. See the corresponding functions:
\begin{itemize}
\item {\bf qfits\_\-pixin\_\-float()}{\rm (p.\,\pageref{qfits_8h_a75})}\item {\bf qfits\_\-pixin\_\-int()}{\rm (p.\,\pageref{qfits_8h_a76})}\item {\bf qfits\_\-pixin\_\-double()}{\rm (p.\,\pageref{qfits_8h_a77})}\item {\bf qfits\_\-pixdump\_\-float()}{\rm (p.\,\pageref{qfits_8h_a79})}\item {\bf qfits\_\-pixdump\_\-int()}{\rm (p.\,\pageref{qfits_8h_a80})}\item {\bf qfits\_\-pixdump\_\-double()}{\rm (p.\,\pageref{qfits_8h_a81})}\end{itemize}
Loading pixels as floats means that whichever pixel format (BITPIX) is used in your input FITS file, all pixels will be converted to your local representation of float upon loading. The 3 offered types basically allow you to work with 3 kinds of pixels internally, choose the one that best suits your needs. 'int' is not recommended for loss of precision, and 'double' for memory and performance issues.
Saving pixels can be done with any BITPIX setting. There are 3 pixel dumpers as there are 3 pixel loaders, because there are 3 possible types for pixel buffers in memory (int, float, double). All pixels are converted on the fly to the requested BITPIX setting.
Notice that as soon as you start using pixel loading functions, you must comply with the {\bf qfits} memory model. This basically means that you should not only include {\tt {\bf qfits.h}{\rm (p.\,\pageref{qfits_8h})}} in your program, but also {\tt xmemory.h} to get the proper definitions for memory allocation functions.\section{Other utilities}\label{index_utils}
Some additional functions are offered in {\bf qfits}, they are useful in the VLT context. See:
\begin{itemize}
\item date\_\-now()\item time\_\-now()\item get\_\-date\_\-iso8601()\item get\_\-datetime\_\-iso8601()\end{itemize}
\section{Features}\label{index_features}
This section describes various unique features of {\bf qfits}.\subsection{Portability}\label{index_portability}
This library has been ported and tested on the following platforms:
\begin{itemize}
\item Linux x86 and alpha\item Solaris 2.5, 2.6 and 2.8\item HPUX 8, 9, 10, 11\item AIX\item BSD compatible, including Darwin (Mac OS X)\item OSF/1 or Tru64\end{itemize}
Since {\bf qfits} depends on POSIX system routines, there is little chance it could compile natively on Windows, except with the help from GNU porting tools from Cygnus. This has never been attempted so far.\subsection{Speed}\label{index_speed}
The offered routines make use of caching mechanisms and memory-mapping system calls to enhance FITS file parsing and speed up the code.\subsection{Interfaces to C++/Python}\label{index_interfaces}
You should be able to compile this library with a C++ compiler, the header files include the usual blurb to allow that without warning from the compiler. You might have problems due to pointer casts and other various incompatibilities due to the variety of C++ dialects and compilers, though. If you really need to hook this library into C++ code, your best bet is probably to compile the library as a standard C library and link your C++ code against it.
A limited set of interfaces to Python is offered. See the INSTALL file in the main distribution directory for instructions about installing this library as a Python module.\subsection{Numerical precision}\label{index_precision}
Since FITS headers are stored as strings, numerical precision is limited by the number of digits used to write a number in a FITS card, which is in theory larger than what a 32-bit floating-point can store. Using {\bf qfits}, these values are available to a C programmer as a string, making sure that precision has at least not be lost in the reading process.\subsection{Conservative headers}\label{index_conservative}
As mentioned above, if you only need to load a header, modify a card and save it back, you will find out that {\em only\/} the card you touched has been modified, the rest was verbatim transferred. This is useful to ensure that the library formatting does not disturb your format.\subsection{Native HIERARCH support}\label{index_hierarch}
Native support for ESO's {\tt HIERARCH} keywords, as well as keywords of any length (up to 80 chars per line).\subsection{ESO/DICB keyword ordering}\label{index_dicb}
Native support for DICB (ESO only) ordering of keywords in the headers. FITS files created with this library will be DICB compliant with respect to keyword ordering.\subsection{Memory model}\label{index_xmemory}
{\bf qfits} does not only offer pixel loading mechanisms, it also comes bundled with a memory module based on a model optimized for the handling of very large data segments. In practice, it means that as soon as you have included {\tt xmemory.h}, your calls to malloc/calloc/free are re-directed to specific versions which put your program on steroids. Calls to memory allocators will yield valid data pointers past the hardware limits of your machine, up to 2 or 4 Gb on a 32-bit workstation and insanely high values on 64-bit processors.
This memory module is also distributed as a stand-alone module which can be downloaded and used without {\bf qfits}. It is mandatory to use this module when using {\bf qfits} pixel loaders, to get the advantages of large memory handling.
If you are only interested in header manipulation, you do not need to include {\tt xmemory.h}.
\section{Installation instructions}\label{index_install}
In the main {\bf qfits} directory, type:
\footnotesize\begin{verbatim}
./configure ; make
\end{verbatim}
\normalsize
To use the library in your programs, add the following line on top of your module:
\footnotesize\begin{verbatim}#include "qfits.h"
\end{verbatim}
\normalsize
And link your program with the {\bf qfits} library by adding {\tt -lqfits} to the compile line.
If you ever need to make calls to one of the {\bf qfits} pixel loaders, you need to include the memory model definitions also with:
\footnotesize\begin{verbatim}#include "xmemory.h"
\end{verbatim}
\normalsize
Including this file is needed so that you can safely {\tt free()} the pointer returned by a pixel loader. See the documentation about pixel loaders for more information.
To compile {\bf qfits} as a Python module, you need to have Python installed on your machine and available in your PATH. Type:
\footnotesize\begin{verbatim}
% python setup.py install
\end{verbatim}
\normalsize
This should build the module and install it in your default library path. This makes use of the distutils package, standardized since Python 2.0. This means that you need Python 2.0 at least to compile and run this module. If you are running Python 1.5 or 1.6, you may want to install the {\tt distutils} package on your platform, which will handle the {\bf qfits} module installation.
\section{Python module documentation}\label{index_python}
The following documentation has been directly extracted from the qfits Python module (Qfits.py) by running:
\footnotesize\begin{verbatim}
% pydoc Qfits.py
\end{verbatim}
\normalsize
Once Qfits.py is installed in your Python distribution, you should also be able to browse this documentation using {\tt pydoc}.
\footnotesize\begin{verbatim}
Python Library Documentation: module Qfits
NAME
Qfits - Qfits.py: a module to read header information from a FITS file.
FILE
Qfits.py
DESCRIPTION
This module offers a function to read all headers in a given
FITS file and return them as a list of strings.
CLASSES
fitsinfo
class fitsinfo
| The fitsinfo class encapsulates queries into a FITS header.
|
| Initialize an instance by giving the name of a file, the following
| fields are then filled in:
|
| - filename - Name of the file
| - n_ext - Number of FITS extensions in file
| - hdrs - List of headers
| - xtnum - Current extension number for get()
|
| The following methods are offered:
|
| * get()
| This method retrieves keyword information in a given instance.
| Provide one or more keywords to look for and this function will
| browse the hdrs list for matching keywords. This method returns a
| string if you requested only 1 keyword or a list of strings if you
| requested several keywords. A failed match returns None.
|
| This method will only search for keywords in the xtnum extension.
|
| get() supports the shortFITS notation, in which A.B.C is transformed
| into HIERARCH ESO A B C before lookup in the FITS header. Notice that
| the given strings are also converted to uppercase before the search
| is launched. See the function expand_keyword() in this module.
|
| Returned string values are always pretty-formatted, i.e. something
| stored into a FITS string as 'o''hara' will be returned as o'hara.
|
| Examples:
|
| q = fitsinfo('vltframe.fits')
| q.get('simple') # returns 'T'
| q.get('simple', 'naxis') # returns ('T', '2')
|
| To search for keywords in the 3rd extension:
|
| q = fitsinfo('wfiframe.fits')
| q.xtnum = 3
| q.get('xtension') # returns 'IMAGE'
| q.get('det.chip3.id', 'bitpix')
| # returns ('ccd52', '16')
|
| * datamd5()
| This method computes the MD5 signature of all the data parts of the
| given FITS file and returns it as a 32-char string containing a
| hexadecimal number on 128 bits.
|
| Methods defined here:
|
| __init__(self, filename)
| Provide a filename to initialize the object.
|
| __repr__(self)
|
| datamd5(self)
|
| get(self, *keywords)
| Get a list of keyword values and return it as a list. If only one
| keyword is requested, the returned value is a single string (or
| None if the keyword was not found). If several keywords are passed,
| the returned value is a list of found values.
|
| The search is only performed in the current extension (xtnum field
| in the class).
|
| ----------------------------------------------------------------------
FUNCTIONS
datamd5(filename)
This function computes the MD5 signature of all data parts in a FITS
file and returns a 32-char string containing the signature as an
hexadecimal number (128 bits). It raises an IOError exception if the
given filename does not correspond to a valid FITS file.
expand_keyword(key)
This function is useful to expand a given keyword into
its FITS equivalent. What it does is simply bring the
word to uppercase, then expand shortFITS words to HIERARCH
ESO notation, like:
simple -> SIMPLE
NaXiS -> NAXIS
det.dit -> HIERARCH ESO DET DIT
get_headers(filename)
This function is the main operator in this module.
Given a file name, it returns all header informations
in a list of lists. The top list contains one element
per found header, i.e. if the given file has 8 extensions,
the top list contains 9 items (1 for the main header,
8 for the extension headers). Each list contains
in turn all informations about the corresponding
headers as a list of tuples like
(key, value, comment)
Example:
The given FITS file contains 1 main header and 2
extension headers given as follows:
--- main header
SIMPLE = T / FITS format
BITPIX = 8 / Bits per pixel
NAXIS = 0 / No data
...
END
--- extension 1
XTENSION = 'IMAGE' / Image extension
BITPIX = 16 / Bits per pixel
...
END
--- extension 2
XTENSION = 'IMAGE' / Image extension
BITPIX = -32 / Bits per pixel
...
END
The returned list contains three items.
The first one is a list corresponding to the
main header, then come the two extension
headers. The first list looks like:
[ ('SIMPLE','T','FITS format'),
('BITPIX', '8', 'Bits per pixel'),
('NAXIS', '0', 'No data'),
...
('END', '', '') ]
The extension lists look like this:
[ ('XTENSION', 'IMAGE', 'Image extension'),
('BITPIX', '16', 'Bits per pixel'),
...
('END', '', '') ]
[ ('XTENSION', 'IMAGE', 'Image extension'),
('BITPIX', '-32', 'Bits per pixel'),
...
('END', '', '') ]
In summary, if you want to get all FITS header informations
from a FITS file, call this function with:
hdr = qfits.get_headers(filename)
This function will raise an IOError exception if the provided
filename does not correspond to a valid file, and None if
the file is not FITS.
If the load succeeded, you can access individual keywords
with the following syntax:
hdr[extension][row][index]
Where:
extension runs from 0 to N_EXT (inclusive)
row is the row number of the card
index is 0 for the keyword, 1 for the value, 2 for the comment.
The number of FITS extensions found in the file is simply:
len(hdr)-1
version()
This function returns the version number of the
underlying qfits module.
\end{verbatim}
\normalsize
\section{Frequently Asked Questions}\label{index_faq}
\subsection{Where should I start to use qfits?}\label{index_faq1}
Try to build the library on your system first. You should then have a new library file called libqfits.a. To use the library functionalities in your programs, you must add the following include in your list of includes:
\footnotesize\begin{verbatim}
#include "qfits.h"
\end{verbatim}
\normalsize
And then compile your program adding the correct flags to indicate where the {\bf {\bf qfits.h}{\rm (p.\,\pageref{qfits_8h})}} header file is, where the libqfits.a file is, and that you want to link against libqfits. Example: if the header file is in /usr/local/include and the library in /usr/local/lib, you would use:
\footnotesize\begin{verbatim}
% cc -o myprog myprog.c -I/usr/local/include -L/usr/local/lib -lqfits
\end{verbatim}
\normalsize
If you need to use pixel loaders/dumpers, you also need to include the {\bf qfits} memory-handling module:
\footnotesize\begin{verbatim}
#include "xmemory.h"
\end{verbatim}
\normalsize
Now you are all set. Refer to this documentation for more information about the offered data structures and associated methods.\subsection{What should I know about the cache mechanism?}\label{index_faq2}
Parsing FITS files to find extensions is a lengthy process, because the FITS format does not declare in the main header where the following extensions are located in the file. Any access to a FITS file with this library will cache a number of offset pointers in the file to allow fast access to extensions. This means that the file is parsed completely only once, the first time it is accessed through any of the {\bf qfits} functions.
The cache is implemented (since version 4.2) as a rotating buffer of modest size: 128 FITS file information structures can be held simultaneously. If you do need to perform accesses on a list of more than 128 files and want to use the caching mechanism at its best, it is recommended to isolate all your FITS requests to a given file in the same code area.
As a programmer, you do not need to initialize or shutdown the cache, this is done automatically.
The rotating buffer is a global data structure private to the cache module. The immediate side-effect is that the library is thread-unsafe. If you are concerned about writing multi-threaded applications, you should use a mutex upon accessing this library. Making a thread-safe compliant version of this library should not be too hard, but the need has not been felt yet.

File diff suppressed because it is too large Load Diff

View File

@ -1,2 +0,0 @@
\section{qfits.head File Reference}
\label{qfits_8head}\index{qfits.head@{qfits.head}}

View File

@ -1,269 +0,0 @@
\documentclass[a4paper,11pt,twoside]{report}
\usepackage{a4wide}
\usepackage{makeidx}
\usepackage{fancyhdr}
\usepackage{graphicx}
\usepackage{float}
\usepackage{alltt}
\usepackage{doxygen}
\usepackage{longtable}
\usepackage{verbatim}
\usepackage{epsf}
\makeindex
%
\raggedbottom
\topmargin=-.9cm
\topskip=-3.5cm
\textheight=24.5cm
\textwidth=14.8cm
\oddsidemargin=1cm
\evensidemargin=-0.1cm
\parindent=0mm
\topsep=0.5ex
\itemsep=0.5ex
\marginparwidth=1.5cm
\marginparsep=1.5mm
\def\docno{VLT-MAN-ESO-19500-2722}
\def\docver{4.2}
\def\docdate{\today}
\def\eg{{e.g.~}}
\def\ie{{i.e.~}}
\makeatletter
\def\@listi{\leftmargin\leftmargini
\parsep 1\p@ \@plus0\p@ \@minus0\p@
\topsep 2\p@ \@plus0\p@ \@minus0\p@
\itemsep 1\p@ \@plus0\p@ \@minus0\p@}
\let\@listI\@listi
\@listi
\def\@listii {\leftmargin\leftmarginii
\labelwidth\leftmarginii
\advance\labelwidth-\labelsep
\topsep 2\p@ \@plus0\p@ \@minus0\p@
\parsep 1\p@ \@plus0\p@ \@minus0\p@
\itemsep \parsep}
\def\@listiii{\leftmargin\leftmarginiii
\labelwidth\leftmarginiii
\advance\labelwidth-\labelsep
\topsep 2\p@ \@plus0\p@ \@minus0\p@
\parsep \z@
\partopsep \p@ \@plus0\z@ \@minus0\p@
\itemsep \topsep}
\makeatother
\setlongtables
\def\degr{\hbox{$^\circ$}}
\def\arcmin{\hbox{$^\prime$}}
\def\arcsec{\hbox{$^{\prime\prime}$}}
\newcounter{docref}
\newcommand{\docref}[3]{\refstepcounter{docref}\label{#1}
{\begin{tabular}{p{7mm}p{75mm}l}[\thedocref]& #3 &{\tt #2}\end{tabular}\\}}
\def\thebibliography#1{\section*{}\list
{[\arabic{enumi}]}{\settowidth\labelwidth{[#1]}\leftmargin\labelwidth
\advance\leftmargin\labelsep
\usecounter{enumi}}
\def\newblock{\hskip .11em plus .33em minus .07em}
\sloppy\clubpenalty4000\widowpenalty4000
\sfcode`\.=1000\relax}
\let\endthebibliography=\endlist
\begin{document}
\newcommand{\cm}[1]{\marginpar{\scriptsize #1}}
\pagenumbering{roman}
\pagestyle{empty}
\begin{center}
\bf
\Large
\hspace{-1.4cm} {EUROPEAN SOUTHERN OBSERVATORY}
\vspace{2.7cm}
\Huge
\hspace{-1.7cm} {VERY LARGE TELESCOPE}
\vspace{2.6cm}
\begin{picture}(10,1)(0,0)
\put(-165,0){\line(0,-1){6}}
\put(-165,0){\line(1,0){6}}
\put(126,0){\line(0,-1){6}}
\put(120,0){\line(1,0){6}}
\end{picture}
% **************************************************************************
% DOCUMENT IDENTIFICATION SECTION
%
% Document Title, Up to four lines. The first or the last should be the
% document type (e.g., Statement of Work, Functional Specification, etc.)
%
\large
\hspace{-1.7cm} {\bf qfits Library} % <<<<<<< subject
\hspace{-1.7cm} {\bf Reference Manual}
\normalsize
\vspace{0.5cm}
\hspace{-1.7cm} {Doc. No. \docno} % <<<<<<< Document number
\vspace{0.5cm}
\hspace{-1.7cm} {Issue \docver} % <<<<<<< Issue [/preparation]
\vspace{0.5cm}
\hspace{-1.7cm} {Date \docdate} % <<<<<<< Date
\vspace{0.5cm}
\begin{picture}(10,1)(0,0)
\put(-165,0){\line(0,1){6}}
\put(-165,0){\line(1,0){6}}
\put(126,0){\line(0,1){6}}
\put(120,0){\line(1,0){6}}
\end{picture}
\vspace{1.6cm}
%
% *************************************************************************
% SIGNATURE SECTION
%
% - AUTHOR
%
\normalsize
\hspace{-3.0cm}\makebox[5.5cm][l]{N.~Devillard, Y.~Jung}
\vspace{-0.3cm}
\large
\hspace{-0.7cm} {Prepared \makebox[10.5cm]{\dotfill}}
\footnotesize
\hspace{2.5cm}{Name} \hspace{4cm}{Date} \hspace{2cm}{Signature}
\vspace{1cm}
% - APPROVER
\normalsize
\hspace{-3.0cm}\makebox[5.5cm][l]{M.~Peron}
\vspace{-0.3cm}
\large
\hspace{-0.7cm} {Approved \makebox[10.5cm]{\dotfill}}
\footnotesize
\hspace{2.5cm}{Name} \hspace{4cm}{Date} \hspace{2cm}{Signature}
\vspace{1cm}
% - RELEASER
\normalsize
\hspace{-3.0cm}\makebox[5.5cm][l]{P.~Quinn}
\vspace{-0.3cm}
\large
\hspace{-0.7cm} {Released \makebox[10.5cm]{\dotfill}}
\footnotesize
\hspace{2.5cm}{Name} \hspace{4cm}{Date} \hspace{2cm}{Signature}
\end{center}
% **************************************************************************
% PAGE HEADING SECTION
%
\clearpage
\pagestyle{myheadings}
\markboth
% {} % <<<<<<< uncomment for single side document
{\underline{qfits Reference Manual - \docver \hspace*{2.5cm} \docno}}
{\underline{qfits Reference Manual - \docver \hspace*{2.5cm} \docno}}
% <<<<<<<< comment the following in the case of a single side document
\vspace*{8 cm}
\begin{center}
This page was intentionally left blank
\end{center}
\newpage
% **************************************************************************
% CHANGE RECORD SECTION
%
\normalsize
\begin{center}
{\bf Change Record}
\vskip 0.5 cm
\begin{tabular}{|c|c|p{3.0cm}|p{6.5cm}|} \hline
Issue/Rev. & Date & Section affected &
Reason and Remarks \\ \hline
4.1 & Mar 2002 & All & First version \\ \hline
4.2 & Apr 2002 & All & Updated cache information \\ \hline
\end{tabular}
\end{center}
\normalsize
% <<<<<<<< comment the following in the case of a single side document
\newpage
\vspace*{8 cm}
\begin{center}
This page was intentionally left blank
\end{center}
% ***************************************************************************
% BEGINNING OF TEXT
%
%------------------------------ Introduction -----------------------------
\newpage
\parskip=2mm
\pagenumbering{arabic}
\setcounter{page}{1}
\tableofcontents
\pagenumbering{arabic}
\setcounter{page}{1}
%-------------------------------------------------------------------
\chapter{qfits Description}
\input{index.tex}
\chapter{qfits Reference}
\input{structqfits__col.tex}
\input{structqfits__header.tex}
\input{structqfits__table.tex}
\input{structqfitsdumper.tex}
\input{structqfitsloader.tex}
\input{qfits_8h}
\printindex
\end{document}
\chapter{qfits Reference manual }
\label{index}\input{index}
\chapter{qfits Directory Hierarchy}
\input{dirs}
\chapter{qfits Data Structure Index}
\input{annotated}
\chapter{qfits File Index}
\input{files}
\chapter{qfits Directory Documentation}
\input{dir_000000}
\chapter{qfits Data Structure Documentation}
\input{structqfits__col}
\include{structqfits__header}
\include{structqfits__table}
\include{structqfitsdumper}
\include{structqfitsloader}
\chapter{qfits File Documentation}
\input{qfits_8h}
\include{qfits_8head}
\printindex
\end{document}

View File

@ -1,125 +0,0 @@
\section{qfits\_\-col Struct Reference}
\label{structqfits__col}\index{qfits_col@{qfits\_\-col}}
Column object.
\subsection*{Data Fields}
\begin{CompactItemize}
\item
int {\bf atom\_\-nb}
\item
int {\bf atom\_\-dec\_\-nb}
\item
int {\bf atom\_\-size}
\item
{\bf tfits\_\-type} {\bf atom\_\-type}
\item
char {\bf tlabel} [FITSVALSZ]
\item
char {\bf tunit} [FITSVALSZ]
\item
char {\bf nullval} [FITSVALSZ]
\item
char {\bf tdisp} [FITSVALSZ]
\item
int {\bf zero\_\-present}
\item
float {\bf zero}
\item
int {\bf scale\_\-present}
\item
float {\bf scale}
\item
int {\bf off\_\-beg}
\item
int {\bf readable}
\end{CompactItemize}
\subsection{Detailed Description}
Column object.
This structure contains all information needed to read a column in a table. These informations come from the header. The {\bf qfits\_\-table}{\rm (p.\,\pageref{structqfits__table})} object contains a list of qfits\_\-col objects.
This structure has to be created from scratch and filled if one want to generate a FITS table.
\subsection{Field Documentation}
\index{qfits_col@{qfits\_\-col}!atom_dec_nb@{atom\_\-dec\_\-nb}}
\index{atom_dec_nb@{atom\_\-dec\_\-nb}!qfits_col@{qfits\_\-col}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf qfits\_\-col::atom\_\-dec\_\-nb}}\label{structqfits__col_o1}
Number of decimals in a ASCII field. This value is always 0 for BIN tables \index{qfits_col@{qfits\_\-col}!atom_nb@{atom\_\-nb}}
\index{atom_nb@{atom\_\-nb}!qfits_col@{qfits\_\-col}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf qfits\_\-col::atom\_\-nb}}\label{structqfits__col_o0}
Number of atoms in one field. In ASCII tables, it is the number of characters in the field as defined in TFORM\%d keyword. In BIN tables, it is the number of atoms in each field. For type 'A', it is the number of characters. A field with two complex object will have atom\_\-nb = 4.\index{qfits_col@{qfits\_\-col}!atom_size@{atom\_\-size}}
\index{atom_size@{atom\_\-size}!qfits_col@{qfits\_\-col}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf qfits\_\-col::atom\_\-size}}\label{structqfits__col_o2}
Size of one element in bytes. In ASCII tables, atom\_\-size is the size of the element once it has been converted in its 'destination' type. For example, if \char`\"{}123\char`\"{} is contained in an ASCII table in a column defined as I type, atom\_\-nb=3, atom\_\-size=4. In ASCII tables:\begin{itemize}
\item type 'A' : atom\_\-size = atom\_\-nb = number of chars\item type 'I', 'F' or 'E' : atom\_\-size = 4\item type 'D' : atom\_\-size = 8 In BIN tables :\item type 'A', 'L', 'X', 'B': atom\_\-size = 1\item type 'I' : atom\_\-size = 2\item type 'E', 'J', 'C', 'P' : atom\_\-size = 4\item type 'D', 'M' : atom\_\-size = 8 In ASCII table, there is one element per field. The size in bytes and in number of characters is atom\_\-nb, and the size in bytes after conversion of the field is atom\_\-size. In BIN tables, the size in bytes of a field is always atom\_\-nb$\ast$atom\_\-size.\end{itemize}
\index{qfits_col@{qfits\_\-col}!atom_type@{atom\_\-type}}
\index{atom_type@{atom\_\-type}!qfits_col@{qfits\_\-col}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf tfits\_\-type} {\bf qfits\_\-col::atom\_\-type}}\label{structqfits__col_o3}
Type of data in the column as specified in TFORM keyword In ASCII tables : TFITS\_\-ASCII\_\-TYPE\_\-$\ast$ with $\ast$=A, I, F, E or D In BIN tables : TFITS\_\-BIN\_\-TYPE\_\-$\ast$ with $\ast$=L, X, B, I, J, A, E, D, C, M or P\index{qfits_col@{qfits\_\-col}!nullval@{nullval}}
\index{nullval@{nullval}!qfits_col@{qfits\_\-col}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}char {\bf qfits\_\-col::nullval}[FITSVALSZ]}\label{structqfits__col_o6}
Null value \index{qfits_col@{qfits\_\-col}!off_beg@{off\_\-beg}}
\index{off_beg@{off\_\-beg}!qfits_col@{qfits\_\-col}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf qfits\_\-col::off\_\-beg}}\label{structqfits__col_o12}
Offset between the beg. of the table and the beg. of the column. \index{qfits_col@{qfits\_\-col}!readable@{readable}}
\index{readable@{readable}!qfits_col@{qfits\_\-col}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf qfits\_\-col::readable}}\label{structqfits__col_o13}
Flag to know if the column is readable. An empty col is not readable \index{qfits_col@{qfits\_\-col}!scale@{scale}}
\index{scale@{scale}!qfits_col@{qfits\_\-col}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}float {\bf qfits\_\-col::scale}}\label{structqfits__col_o11}
\index{qfits_col@{qfits\_\-col}!scale_present@{scale\_\-present}}
\index{scale_present@{scale\_\-present}!qfits_col@{qfits\_\-col}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf qfits\_\-col::scale\_\-present}}\label{structqfits__col_o10}
\index{qfits_col@{qfits\_\-col}!tdisp@{tdisp}}
\index{tdisp@{tdisp}!qfits_col@{qfits\_\-col}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}char {\bf qfits\_\-col::tdisp}[FITSVALSZ]}\label{structqfits__col_o7}
Display format \index{qfits_col@{qfits\_\-col}!tlabel@{tlabel}}
\index{tlabel@{tlabel}!qfits_col@{qfits\_\-col}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}char {\bf qfits\_\-col::tlabel}[FITSVALSZ]}\label{structqfits__col_o4}
Label of the column \index{qfits_col@{qfits\_\-col}!tunit@{tunit}}
\index{tunit@{tunit}!qfits_col@{qfits\_\-col}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}char {\bf qfits\_\-col::tunit}[FITSVALSZ]}\label{structqfits__col_o5}
Unit of the data \index{qfits_col@{qfits\_\-col}!zero@{zero}}
\index{zero@{zero}!qfits_col@{qfits\_\-col}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}float {\bf qfits\_\-col::zero}}\label{structqfits__col_o9}
\index{qfits_col@{qfits\_\-col}!zero_present@{zero\_\-present}}
\index{zero_present@{zero\_\-present}!qfits_col@{qfits\_\-col}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf qfits\_\-col::zero\_\-present}}\label{structqfits__col_o8}
zero and scale are used when the quantity in the field does not represent a true physical quantity. Basically, thez should be used when they are present: physical\_\-value = zero + scale $\ast$ field\_\-value They are read from TZERO and TSCAL in the header
The documentation for this struct was generated from the following file:\begin{CompactItemize}
\item
{\bf qfits.h}\end{CompactItemize}

View File

@ -1,44 +0,0 @@
\section{qfits\_\-header Struct Reference}
\label{structqfits__header}\index{qfits_header@{qfits\_\-header}}
FITS header object.
\subsection*{Data Fields}
\begin{CompactItemize}
\item
void $\ast$ {\bf first}
\item
void $\ast$ {\bf last}
\item
int {\bf n}
\end{CompactItemize}
\subsection{Detailed Description}
FITS header object.
This structure represents a FITS header in memory. It is actually no more than a thin layer on top of the keytuple object. No field in this structure should be directly modifiable by the user, only through accessor functions.
\subsection{Field Documentation}
\index{qfits_header@{qfits\_\-header}!first@{first}}
\index{first@{first}!qfits_header@{qfits\_\-header}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void$\ast$ {\bf qfits\_\-header::first}}\label{structqfits__header_o0}
\index{qfits_header@{qfits\_\-header}!last@{last}}
\index{last@{last}!qfits_header@{qfits\_\-header}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void$\ast$ {\bf qfits\_\-header::last}}\label{structqfits__header_o1}
\index{qfits_header@{qfits\_\-header}!n@{n}}
\index{n@{n}!qfits_header@{qfits\_\-header}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf qfits\_\-header::n}}\label{structqfits__header_o2}
The documentation for this struct was generated from the following file:\begin{CompactItemize}
\item
{\bf qfits.h}\end{CompactItemize}

View File

@ -1,89 +0,0 @@
\section{qfits\_\-table Struct Reference}
\label{structqfits__table}\index{qfits_table@{qfits\_\-table}}
Table object.
\subsection*{Data Fields}
\begin{CompactItemize}
\item
char {\bf filename} [FILENAMESZ]
\item
int {\bf tab\_\-t}
\item
int {\bf tab\_\-w}
\item
int {\bf nc}
\item
int {\bf nr}
\item
{\bf qfits\_\-col} $\ast$ {\bf col}
\end{CompactItemize}
\subsection{Detailed Description}
Table object.
This structure contains all information needed to read a FITS table. These information come from the header. The object is created by qfits\_\-open().
To read a FITS table, here is a code example:
\footnotesize\begin{verbatim} int main(int argc, char* argv[])
{
qfits_table * table ;
int n_ext ;
int i ;
// Query the number of extensions
n_ext = qfits_query_n_ext(argv[1]) ;
// For each extension
for (i=0 ; i<n_ext ; i++) {
// Read all the infos about the current table
table = qfits_table_open(argv[1], i+1) ;
// Display the current table
dump_extension(table, stdout, '|', 1, 1) ;
}
return ;
}
\end{verbatim}
\normalsize
\subsection{Field Documentation}
\index{qfits_table@{qfits\_\-table}!col@{col}}
\index{col@{col}!qfits_table@{qfits\_\-table}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf qfits\_\-col}$\ast$ {\bf qfits\_\-table::col}}\label{structqfits__table_o5}
Array of {\bf qfits\_\-col}{\rm (p.\,\pageref{structqfits__col})} objects \index{qfits_table@{qfits\_\-table}!filename@{filename}}
\index{filename@{filename}!qfits_table@{qfits\_\-table}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}char {\bf qfits\_\-table::filename}[FILENAMESZ]}\label{structqfits__table_o0}
Name of the file the table comes from or it is intended to end to\index{qfits_table@{qfits\_\-table}!nc@{nc}}
\index{nc@{nc}!qfits_table@{qfits\_\-table}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf qfits\_\-table::nc}}\label{structqfits__table_o3}
Number of columns \index{qfits_table@{qfits\_\-table}!nr@{nr}}
\index{nr@{nr}!qfits_table@{qfits\_\-table}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf qfits\_\-table::nr}}\label{structqfits__table_o4}
Number of raws \index{qfits_table@{qfits\_\-table}!tab_t@{tab\_\-t}}
\index{tab_t@{tab\_\-t}!qfits_table@{qfits\_\-table}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf qfits\_\-table::tab\_\-t}}\label{structqfits__table_o1}
Table type. Possible values: QFITS\_\-INVALIDTABLE, QFITS\_\-BINTABLE, QFITS\_\-ASCIITABLE\index{qfits_table@{qfits\_\-table}!tab_w@{tab\_\-w}}
\index{tab_w@{tab\_\-w}!qfits_table@{qfits\_\-table}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int {\bf qfits\_\-table::tab\_\-w}}\label{structqfits__table_o2}
Width in bytes of the table
The documentation for this struct was generated from the following file:\begin{CompactItemize}
\item
{\bf qfits.h}\end{CompactItemize}

Some files were not shown because too many files have changed in this diff Show More