- Timestamp:
- Mar 29, 2009, 6:15:31 PM (17 years ago)
- Location:
- branches/cnb_branches/cnb_branch_20090301
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/cnb_branches/cnb_branch_20090301
-
branches/cnb_branches/cnb_branch_20090301/ppSub
- Property svn:mergeinfo changed
/trunk/ppSub merged: 23356,23369,23399,23402-23403,23448-23449,23505,23535
- Property svn:mergeinfo changed
-
branches/cnb_branches/cnb_branch_20090301/ppSub/src/ppSubCamera.c
r23352 r23594 33 33 34 34 // look for the file on the RUN metadata 35 pmFPAfile *file = pmFPAfileDefineFromRun(&status, config, filerule); // File to return35 pmFPAfile *file = pmFPAfileDefineFromRun(&status, bind, config, filerule); // File to return 36 36 if (!status) { 37 37 psError(PS_ERR_UNKNOWN, false, "Failed to load file definition for %s", filerule); … … 66 66 static pmFPAfile *defineOutputFile(pmConfig *config, // Configuration 67 67 pmFPAfile *template, // File to use as basis for definition 68 bool source, // Is template a source (T), or for binding (F)? 68 69 char *filerule, // Name of file rule 69 70 pmFPAfileType fileType // Type of file … … 71 72 { 72 73 73 pmFPAfile *file = pmFPAfileDefineFromFile(config, template, 1, 1, filerule); 74 pmFPAfile *file = source ? pmFPAfileDefineFromFile(config, template, 1, 1, filerule) : 75 pmFPAfileDefineOutput(config, template->fpa, filerule); 74 76 if (!file) { 75 77 psError(PS_ERR_IO, false, _("Unable to generate output file from %s"), filerule); … … 96 98 97 99 // look for the file on the RUN metadata 98 pmFPAfile *file = pmFPAfileDefineFromRun(&status, config, filerule); // File to return100 pmFPAfile *file = pmFPAfileDefineFromRun(&status, bind, config, filerule); // File to return 99 101 if (!status) { 100 102 psError(PS_ERR_UNKNOWN, false, "Failed to load file definition for %s", filerule); … … 108 110 // define new version of file 109 111 if (!file) { 110 pmFPAfileDefineOutput(config, bind ? bind->fpa : NULL, filerule);112 file = pmFPAfileDefineOutput(config, bind ? bind->fpa : NULL, filerule); 111 113 if (!status) { 112 114 psError(PS_ERR_UNKNOWN, false, "Failed to load file definition for %s", filerule); … … 160 162 161 163 // Output image 162 pmFPAfile *output = defineOutputFile(config, input, "PPSUB.OUTPUT", PM_FPA_FILE_IMAGE);163 pmFPAfile *outMask = defineOutputFile(config, output, "PPSUB.OUTPUT.MASK", PM_FPA_FILE_MASK);164 pmFPAfile *output = defineOutputFile(config, input, true, "PPSUB.OUTPUT", PM_FPA_FILE_IMAGE); 165 pmFPAfile *outMask = defineOutputFile(config, output, false, "PPSUB.OUTPUT.MASK", PM_FPA_FILE_MASK); 164 166 if (!output || !outMask) { 165 167 psError(PS_ERR_UNKNOWN, false, "Unable to define output files"); … … 170 172 pmFPAfile *outVar = NULL; 171 173 if (inVar && refVar) { 172 outVar = defineOutputFile(config, output, "PPSUB.OUTPUT.VARIANCE", PM_FPA_FILE_VARIANCE);174 outVar = defineOutputFile(config, output, false, "PPSUB.OUTPUT.VARIANCE", PM_FPA_FILE_VARIANCE); 173 175 if (!outVar) { 174 176 psError(PS_ERR_UNKNOWN, false, "Unable to define output files"); … … 180 182 181 183 // Convolved input image 182 pmFPAfile *inConvImage = defineOutputFile(config, input, "PPSUB.INPUT.CONV", PM_FPA_FILE_IMAGE); 183 pmFPAfile *inConvMask = defineOutputFile(config, input, "PPSUB.INPUT.CONV.MASK", PM_FPA_FILE_MASK); 184 pmFPAfile *inConvImage = defineOutputFile(config, input, true, "PPSUB.INPUT.CONV", PM_FPA_FILE_IMAGE); 185 pmFPAfile *inConvMask = defineOutputFile(config, inConvImage, false, "PPSUB.INPUT.CONV.MASK", 186 PM_FPA_FILE_MASK); 184 187 if (!inConvImage || !inConvMask) { 185 188 psError(PS_ERR_UNKNOWN, false, "Unable to define output files"); … … 187 190 } 188 191 if (inVar) { 189 pmFPAfile *inConvVar = defineOutputFile(config, in put, "PPSUB.INPUT.CONV.VARIANCE",192 pmFPAfile *inConvVar = defineOutputFile(config, inConvImage, false, "PPSUB.INPUT.CONV.VARIANCE", 190 193 PM_FPA_FILE_VARIANCE); 191 194 if (!inConvVar) { … … 196 199 197 200 // Convolved ref image 198 pmFPAfile *refConvImage = defineOutputFile(config, input, "PPSUB.REF.CONV", PM_FPA_FILE_IMAGE); 199 pmFPAfile *refConvMask = defineOutputFile(config, input, "PPSUB.REF.CONV.MASK", PM_FPA_FILE_MASK); 201 pmFPAfile *refConvImage = defineOutputFile(config, input, true, "PPSUB.REF.CONV", PM_FPA_FILE_IMAGE); 202 pmFPAfile *refConvMask = defineOutputFile(config, refConvImage, false, "PPSUB.REF.CONV.MASK", 203 PM_FPA_FILE_MASK); 200 204 if (!refConvImage || !refConvMask) { 201 205 psError(PS_ERR_UNKNOWN, false, "Unable to define output files"); … … 203 207 } 204 208 if (refVar) { 205 pmFPAfile *refConvVar = defineOutputFile(config, input, "PPSUB.REF.CONV.VARIANCE",209 pmFPAfile *refConvVar = defineOutputFile(config, refConvImage, false, "PPSUB.REF.CONV.VARIANCE", 206 210 PM_FPA_FILE_VARIANCE); 207 211 if (!refConvVar) {
Note:
See TracChangeset
for help on using the changeset viewer.
