Changeset 6827 for branches/rel10_ifa/psModules/src/astrom/pmFPAfile.h
- Timestamp:
- Apr 10, 2006, 10:22:42 AM (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/rel10_ifa/psModules/src/astrom/pmFPAfile.h
r6819 r6827 7 7 * @author EAM, IfA 8 8 * 9 * @version $Revision: 1.1.2. 9$ $Name: not supported by cvs2svn $10 * @date $Date: 2006-04- 08 20:13:03$9 * @version $Revision: 1.1.2.10 $ $Name: not supported by cvs2svn $ 10 * @date $Date: 2006-04-10 20:22:42 $ 11 11 * 12 12 * Copyright 2004-2005 Institute for Astronomy, University of Hawaii … … 40 40 PM_FPA_MODE_READ, 41 41 PM_FPA_MODE_WRITE, 42 PM_FPA_MODE_INTERNAL, 42 43 } pmFPAfileMode; 43 44 … … 49 50 typedef struct 50 51 { 51 pmFPAdepth fileDepth; 52 pmFPAdepth dataDepth; 52 pmFPAfileMode mode; // is this file read, written, or only used internally? 53 pmFPAfileType type; // what type of data is read from / written to disk? 54 pmFPAfileState state; // have we opened the file, etc? 53 55 54 p sMetadata *phu;55 p sMetadata *header;56 pmFPAdepth fileDepth; // what depth in the FPA hierarchy represents a unique file? 57 pmFPAdepth dataDepth; // at what depth do we read/write the data segment? 56 58 57 pmFPA *fpa; 58 psFits *fits; 59 psMetadata *names; 59 pmFPA *fpa; // for I/O files, we carry a pointer to the complete fpa 60 psFits *fits; // for I/O files of fits type (IMAGE, CMP, CMF), we carry a file handle 60 61 61 char *filerule; 62 char *filextra; 63 char *extrule; 64 char *extxtra; 62 psMetadata *phu; // pointer (view) to the current phu header 63 psMetadata *header; // pointer (view) to the current hdu header 65 64 66 char *filename; 67 char *extname; 65 pmReadout *readout; // for internal files, we only carry a single readout 68 66 69 pmFPAfileType type; 70 pmFPAfileMode mode; 71 pmFPAfileState state; 67 psMetadata *names; // filenames supplied by the cmdline or detdb are saved here 68 69 char *filerule; // rule for constructing a filename when needed 70 char *filextra; // additional information used to define filenames (context dependent) 71 char *extrule; // rule for constructing an extension name when needed 72 char *extxtra; // additional information used to define extension names (context dependent) 73 74 char *name; // the name of the rule (useful for debugging / tracing) 75 char *filename; // the current name of an active file 76 char *extname; // the current name of an active file extension 77 78 // the following elements are used for WRITE-mode IMAGE-type pmFPAfiles to inform 79 // the creation of a new image based on an existing image 80 pmFPA *src; // if an output FPA, inherit from this FPA 81 int xBin; // desired binning in x direction 82 int yBin; // desired binning in y direction 72 83 } 73 84 pmFPAfile; … … 81 92 // load the pmFPAfile information from the camera configuration data, constructing the needed fpa structure 82 93 // XXX deprecate this function? 83 pmFPAfile *pmFPAfileConstruct (psMetadata *files, psMetadata *format, psMetadata *camera, char *name);94 // pmFPAfile *pmFPAfileConstruct (psMetadata *files, psMetadata *format, psMetadata *camera, char *name); 84 95 85 96 // open the real file corresponding to the given pmFPAfile appropriate to the current view … … 88 99 // read from the real file corresponding to the given pmFPAfile for the current view 89 100 bool pmFPAfileRead (pmFPAfile *file, const pmFPAview *view); 101 102 bool pmFPAfileCreate (pmFPAfile *file, const pmFPAview *view); 90 103 91 104 // write to the real file corresponding to the given pmFPAfile for the current view … … 100 113 // return an image corresponding to the current readout, from the specified file. if the pmFPAfile does not 101 114 // exist, construct the image using the given size and type (save it in a pmFPAfile??) 102 psImage *pmFPAfileReadoutImage (psMetadata *files, const pmFPAview *view, char *name, int Nx, int Ny, int type); 115 // psImage *pmFPAfileReadoutImage (psMetadata *files, const pmFPAview *view, char *name, int Nx, int Ny, int type); 116 117 // select the readout from the named pmFPAfile; if the named file does not exist, 118 pmReadout *pmFPAfileThisReadout (psMetadata *files, const pmFPAview *view, const char *name); 119 120 // create a file with the given name, assign it type "INTERNAL", and supply it with an image 121 // of the requested dimensions. (image only, mask and weight are ignored) 122 pmReadout *pmFPAfileCreateInternal (psMetadata *files, char *name, int Nx, int Ny, int type); 123 124 // delete the INTERNAL file of the given name (if it exists) 125 bool pmFPAfileDropInternal (psMetadata *files, char *name); 103 126 104 127 // read an image into the current view … … 120 143 char *pmFPAfileNameFromRule (char *rule, pmFPAfile *file, const pmFPAview *view); 121 144 145 bool pmFPAfileCopyView (pmFPA *out, pmFPA *in, const pmFPAview *view); 146 122 147 # endif
Note:
See TracChangeset
for help on using the changeset viewer.
