Changeset 42000
- Timestamp:
- Jan 26, 2022, 10:05:47 AM (4 years ago)
- File:
-
- 1 edited
-
tags/ipp-ps2-20190404/ppSub/src/ppSubCamera.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
tags/ipp-ps2-20190404/ppSub/src/ppSubCamera.c
r38709 r42000 180 180 psAssert(config, "Require configuration"); 181 181 182 183 182 184 // Input image 183 185 pmFPAfile *input = defineInputFile(&success, config, NULL, "PPSUB.INPUT", "INPUT", PM_FPA_FILE_IMAGE); … … 205 207 } 206 208 209 int did_rewrite = 0; 210 207 211 // Reference image 208 212 pmFPAfile *ref = defineInputFile(&success, config, NULL, "PPSUB.REF", "REF", PM_FPA_FILE_IMAGE); 209 213 if (!success) { 210 214 psError(psErrorCodeLast(), false, "Failed to build FPA from PPSUB.REF"); 211 return false; 215 // return false; 216 217 psErrorClear(); 218 fprintf(stderr,"%s\n", config->cameraName); 219 psStringSubstitute(&( config->cameraName ),"GPC1","GPC2"); 220 fprintf(stderr,"%s\n", config->cameraName); 221 did_rewrite = 1; 222 223 ref = defineInputFile(&success, config, NULL, "PPSUB.REF", "REF", PM_FPA_FILE_IMAGE); 224 if (!success) { 225 return false; 226 } 212 227 } 213 228 … … 226 241 defineInputFile(&success, config, NULL, "PPSUB.REF.SOURCES", "REF.SOURCES", PM_FPA_FILE_CMF); 227 242 if (!success) { 243 if (did_rewrite == 1) { 244 // Sometimes we use the warp sources instead of the stack 245 psErrorClear(); 246 did_rewrite = 0; 247 248 fprintf(stderr,"%s\n", config->cameraName); 249 psStringSubstitute(&( config->cameraName ),"GPC2","GPC1"); 250 fprintf(stderr,"%s\n", config->cameraName); 251 defineInputFile(&success, config, NULL, "PPSUB.REF.SOURCES", "REF.SOURCES", PM_FPA_FILE_CMF); 252 if (!success) { 253 psError(psErrorCodeLast(), false, "Failed to build FPA from PPSUB.REF.SOURCES"); 254 return false; 255 } 256 } 257 else { 228 258 psError(psErrorCodeLast(), false, "Failed to build FPA from PPSUB.REF.SOURCES"); 229 259 return false; 230 } 231 260 } 261 } 262 263 if (did_rewrite == 1) { 264 fprintf(stderr,"%s\n", config->cameraName); 265 psStringSubstitute(&( config->cameraName ),"GPC2","GPC1"); 266 fprintf(stderr,"%s\n", config->cameraName); 267 } 268 232 269 // Now that the camera has been determined, we can read the recipe 233 270 psMetadata *recipe = psMetadataLookupMetadata(NULL, config->recipes, PPSUB_RECIPE); // Recipe for ppSim
Note:
See TracChangeset
for help on using the changeset viewer.
