IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 16970


Ignore:
Timestamp:
Mar 13, 2008, 8:46:39 AM (18 years ago)
Author:
eugene
Message:

update comments

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Ohana/src/libfits/matrix/F_compress_M.c

    r16855 r16970  
    22# include <gfitsio.h>
    33# include <zlib.h>
    4 
    5 # define MOD_KEYWORD(NAME,ZNAME,TYPE,IN,OUT) { \
    6   gfits_scan (header, ZNAME, TYPE, 1, IN); \
    7   gfits_delete (header, ZNAME, 1); \
    8   gfits_print (header, NAME, TYPE, 1, OUT); }
    9 
    10 # define MOD_KEYWORD_REQUIRED(ZNAME,NAME,TYPE,IN,OUT) { \
    11   if (!gfits_scan (header, ZNAME, TYPE, 1, IN)) ESCAPE; \
    12   gfits_delete (header, ZNAME, 1); \
    13   gfits_print (header, NAME, TYPE, 1, OUT); }
    144
    155# define ESCAPE { \
     
    2818  return (FALSE); }
    2919
     20# define MOD_KEYWORD(NAME,ZNAME,TYPE,IN,OUT) { \
     21  gfits_scan (header, ZNAME, TYPE, 1, IN); \
     22  gfits_delete (header, ZNAME, 1); \
     23  gfits_print (header, NAME, TYPE, 1, OUT); }
     24
     25# define MOD_KEYWORD_REQUIRED(ZNAME,NAME,TYPE,IN,OUT) { \
     26  if (!gfits_scan (header, ZNAME, TYPE, 1, IN)) ESCAPE; \
     27  gfits_delete (header, ZNAME, 1); \
     28  gfits_print (header, NAME, TYPE, 1, OUT); }
     29
    3030int gfits_uncompress_image (Header *header, Matrix *matrix, FTable *ftable) {
    3131
     
    6969  }   
    7070
    71   // set up the tile sizes
     71  // set up the tile sizes : ztile is the default size of the tile in the Nth dimension
     72  // the actual tile size may be smaller at the edge of a dimension.  if the ZTILEn
     73  // entries are not found, default to [Nx,1,1,...]
    7274  ALLOCATE (ztile, int, header->Naxes);
    7375  if (!gfits_scan (header, "ZTILE1", "%d", 1, &ztile[0])) {
     
    8486  }
    8587
    86   // search for algorithm-specific keywords
     88  // search for algorithm-specific keywords. these are used to control compression options
     89  // note the difference between the keywords (1 indexed) and the variables (0 indexed)
    8790  NOPTIONS = 10;
    8891  ALLOCATE (optname, char *, NOPTIONS);
     
    106109  }
    107110
    108   // XXX is Noptions set to the correct value?
    109111  // XXX get ZMASKCMP
    110112  int zsimple, have_zsimple;
     
    245247// and output pixel data.....
    246248
     249// true sizes of this tile (in pixels)
    247250int gfits_tile_size (Matrix *matrix, int *otile, int *ztile) {
    248251
    249252  int i, Npixels, Ndimen;
    250253
    251   // true sizes of this tile (in pixels)
    252254  Npixels = 1;
    253255  for (i = 0; i < matrix->Naxes; i++) {
Note: See TracChangeset for help on using the changeset viewer.