- Timestamp:
- May 27, 2008, 7:12:46 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branch_20080511/ppSim/src/ppSimMergeReadouts.c
r17703 r17818 2 2 3 3 // XXX add bounds to the inputs? 4 bool ppSimMergeReadouts (pm Readout *outReadout, pmReadout *inReadout) {4 bool ppSimMergeReadouts (pmConfig *config, pmFPAview *view) { 5 5 6 6 // bool mdok; 7 8 // if we have an input image, we need to add the synthetic data on top of it below 9 // XXX we may potentially use this input file to skip missing elements 10 pmFPAfile *input = psMetadataLookupPtr(NULL, config->files, "PPSIM.INPUT"); 11 if (!input) return true; 12 13 pmReadout *inReadout = pmFPAviewThisReadout (view, input->fpa); 14 if (!inReadout) return true; 15 16 if (!inReadout->weight) { 17 if (!pmReadoutGenerateWeight(inReadout, true)) { 18 psError (PS_ERR_UNKNOWN, false, "trouble creating weight"); 19 return false; 20 } 21 } 22 23 // output must exist or we made a programming error 24 pmFPAfile *output = psMetadataLookupPtr(NULL, config->files, "PPSIM.OUTPUT"); // Output file 25 assert(output); 26 27 // XXX require outReadout? 28 pmReadout *outReadout = pmFPAviewThisReadout (view, output->fpa); 29 if (!outReadout) return true; 7 30 8 31 psImage *inSignal = inReadout->image; … … 12 35 psImage *outVariance = outReadout->weight; 13 36 14 // psMetadata *recipe = psMetadataLookupMetadata(&mdok, config->recipes, PPSIM_RECIPE); // Recipe15 37 assert (inSignal->numRows == outSignal->numRows); 16 38 assert (inSignal->numCols == outSignal->numCols);
Note:
See TracChangeset
for help on using the changeset viewer.
