Changeset 32704 for trunk/psphot/src/psphotStackImageLoop.c
- Timestamp:
- Nov 18, 2011, 11:14:36 AM (14 years ago)
- File:
-
- 1 edited
-
trunk/psphot/src/psphotStackImageLoop.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psphot/src/psphotStackImageLoop.c
r32348 r32704 10 10 bool UpdateHeadersForFPA (pmConfig *config, pmFPAview *view); 11 11 bool UpdateHeadersForChip (pmConfig *config, pmFPAview *view); 12 bool UpdateHeadersForReadout (pmConfig *config, pmFPAview *view); 12 13 13 14 bool psphotStackImageLoop (pmConfig *config) { … … 66 67 return false; 67 68 } 69 70 UpdateHeadersForReadout(config, view); 71 68 72 psMemDump("psphot"); 69 73 } … … 101 105 } 102 106 107 bool UpdateHeadersForReadout (pmConfig *config, pmFPAview *view) { 108 109 psMetadata *recipe = psMetadataLookupPtr (NULL, config->recipes, PSPHOT_RECIPE); 110 bool useRaw = psMetadataLookupBool (NULL, recipe, "PSPHOT.STACK.USE.RAW"); 111 112 int num = psphotFileruleCount(config, "PSPHOT.INPUT"); 113 114 // loop over the available readouts 115 for (int i = 0; i < num; i++) { 116 117 // find the currently selected readout 118 pmFPAfile *output = pmFPAfileSelectSingle(config->files, "PSPHOT.STACK.OUTPUT.IMAGE", i); // File of interest 119 psAssert (output, "missing file?"); 120 121 pmFPAfile *inputRaw = pmFPAfileSelectSingle(config->files, "PSPHOT.STACK.INPUT.RAW", i); // File of interest 122 pmFPAfile *inputCnv = pmFPAfileSelectSingle(config->files, "PSPHOT.STACK.INPUT.CNV", i); // File of interest 123 pmFPAfile *input = useRaw ? inputRaw : inputCnv; 124 psAssert (input, "missing input file"); 125 126 // just copy the input headers to the output headers, then update version info 127 pmReadout *inReadout = pmFPAviewThisReadout(view, input->fpa); ///< Chip in the input 128 pmReadout *outReadout = pmFPAviewThisReadout(view, output->fpa); ///< Chip in the output 129 130 psMetadata *header = psMetadataLookupPtr (NULL, inReadout->analysis, "PSPHOT.HEADER"); 131 psMetadataAdd (outReadout->analysis, PS_LIST_TAIL, "PSPHOT.HEADER", PS_DATA_METADATA, "header stats", header); 132 } 133 return true; 134 } 135 103 136 bool UpdateHeadersForChip (pmConfig *config, pmFPAview *view) { 104 137
Note:
See TracChangeset
for help on using the changeset viewer.
