next up previous 264
Next: Addressing Cards in a FitsChan
Up: Storing AST Objects in FITS Headers (FitsChans)
Previous: The FitsChan Model


Creating a FitsChan

The FitsChan constructor function, astFitsChan, is straightforward to use:

#include "ast.h"
AstFitsChan *fitschan;

...

fitschan = astFitsChan( NULL, NULL, "Encoding=NATIVE" );

Here, we have omitted any source or sink functions by supplying NULL pointers for the first two arguments. We have also initialised the FitsChan's Encoding attribute to NATIVE. This indicates that we will be using the native encoding ([*]) to store and retrieve Objects. If this was left unspecified, the default would depend on the FitsChan's contents. An attempt is made to use whatever encoding appears to have been used previously. For an empty FitsChan, the default is NATIVE, but it does no harm to be sure.


next up previous 264
Next: Addressing Cards in a FitsChan
Up: Storing AST Objects in FITS Headers (FitsChans)
Previous: The FitsChan Model

AST A Library for Handling World Coordinate Systems in Astronomy
Starlink User Note 211
R.F. Warren-Smith & D.S. Berry
24th May 2011
E-mail:ussc@star.rl.ac.uk

Copyright (C) 2009 Science \& Technology Facilities Council