Changeset 17915
- Timestamp:
- Jun 4, 2008, 3:41:14 PM (18 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
-
ppMerge/src/ppMergeCamera.c (modified) (1 diff)
-
ppSim/src/ppSimCreate.c (modified) (8 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ppMerge/src/ppMergeCamera.c
r17227 r17915 25 25 26 26 // Output image 27 pmFPA *fpa = pmFPAConstruct(config->camera ); // FPA to contain the output27 pmFPA *fpa = pmFPAConstruct(config->camera, config->cameraName); // FPA to contain the output 28 28 if (!fpa) { 29 29 psError(PS_ERR_UNEXPECTED_NULL, false, "Unable to construct an FPA from camera configuration."); -
trunk/ppSim/src/ppSimCreate.c
r17557 r17915 18 18 pmFPAfile *input = pmFPAfileDefineFromArgs (&status, config, "PPIMAGE.INPUT", "INPUT"); 19 19 if (!input) { 20 // if we have not specified the camera already, we need to interpolate the recipes associated with this camera, and read other command-line recipes20 // if we have not specified the camera already, we need to interpolate the recipes associated with this camera, and read other command-line recipes 21 21 if (!pmConfigReadRecipes(config, PM_RECIPE_SOURCE_CL)) { 22 22 psError(PS_ERR_IO, false, "Error merging recipes from camera config for %s", config->cameraName); … … 24 24 } 25 25 26 simImage = true;27 fpa = pmFPAConstruct(config->camera); // FPA to contain the observation28 if (!fpa) {29 psError(PS_ERR_UNEXPECTED_NULL, false, "Unable to construct an FPA from camera configuration.");30 return NULL;31 }32 26 simImage = true; 27 fpa = pmFPAConstruct(config->camera, config->cameraName); // FPA to contain the observation 28 if (!fpa) { 29 psError(PS_ERR_UNEXPECTED_NULL, false, "Unable to construct an FPA from camera configuration."); 30 return NULL; 31 } 32 33 33 } else { 34 simImage = false;35 if (input->type != PM_FPA_FILE_IMAGE) {36 psError(PS_ERR_IO, true, "PPIMAGE.INPUT is not of type IMAGE");37 return NULL;38 }39 fpa = input->fpa;34 simImage = false; 35 if (input->type != PM_FPA_FILE_IMAGE) { 36 psError(PS_ERR_IO, true, "PPIMAGE.INPUT is not of type IMAGE"); 37 return NULL; 38 } 39 fpa = input->fpa; 40 40 } 41 41 … … 49 49 if (file->type != PM_FPA_FILE_IMAGE) { 50 50 psError(PS_ERR_BAD_PARAMETER_TYPE, true, "%s type is not IMAGE", OUTPUT_FILE); 51 psFree(fpa);51 psFree(fpa); 52 52 psFree(file); 53 53 return NULL; … … 60 60 // have we supplied a psf model? 61 61 if (psMetadataLookupPtr(NULL, config->arguments, "PSPHOT.PSF")) { 62 bool status = false;62 bool status = false; 63 63 64 // tie the psf file to the chipMosaic 64 // tie the psf file to the chipMosaic 65 65 pmFPAfileBindFromArgs(&status, file, config, "PSPHOT.PSF.LOAD", "PSPHOT.PSF"); 66 66 if (!status) { 67 67 psError(PS_ERR_UNKNOWN, false, "Failed to find/build PSPHOT.PSF.LOAD"); 68 psFree(fpa);69 psFree(file);68 psFree(fpa); 69 psFree(file); 70 70 return NULL; 71 71 } … … 83 83 // if we have loaded an input image, we do not need to populate the fpa 84 84 if (!simImage) { 85 return file;85 return file; 86 86 } 87 87 … … 95 95 psFree(fpa); 96 96 psFree(view); 97 psFree(file);97 psFree(file); 98 98 return NULL; 99 99 } … … 107 107 psFree(fpa); 108 108 psFree(view); 109 psFree(file);109 psFree(file); 110 110 return NULL; 111 111 } … … 119 119 psFree(fpa); 120 120 psFree(view); 121 psFree(file);121 psFree(file); 122 122 return NULL; 123 123 }
Note:
See TracChangeset
for help on using the changeset viewer.
