- Timestamp:
- Apr 21, 2014, 5:42:34 AM (12 years ago)
- Location:
- branches/eam_branches/ps2-tc3-20130727
- Files:
-
- 2 edited
-
. (modified) (1 prop)
-
ppSkycell/src/ppSkycellCamera.c (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/ps2-tc3-20130727
- Property svn:mergeinfo changed
-
branches/eam_branches/ps2-tc3-20130727/ppSkycell/src/ppSkycellCamera.c
r35852 r36680 56 56 data->numInputs = images->n; 57 57 58 psArray *masks = NULL; // Mask names59 if (data->masksName) {60 masks = fileList(data->masksName);61 if (!masks) {62 psError(psErrorCodeLast(), false, "No masks provided.");63 psFree(images);64 return false;65 }66 if (masks->n != data->numInputs) {67 psError(PS_ERR_BAD_PARAMETER_SIZE, true, "Number of images (%ld) and masks (%ld) do not match",68 images->n, masks->n);69 psFree(images);70 psFree(masks);71 return false;72 }73 }74 75 58 psArray *wcsref = NULL; // Names of WCS reference images 76 59 if (data->wcsrefName) { … … 79 62 psError(psErrorCodeLast(), false, "No WCSrefs provided."); 80 63 psFree(images); 81 psFree(masks);82 64 return(false); 83 65 } … … 86 68 images->n, wcsref->n); 87 69 psFree(images); 88 psFree(masks);89 70 psFree(wcsref); 90 71 return(false); … … 104 85 } 105 86 106 if (data->masksName) {107 fileArguments("MASK", masks->data[i], "Name of the mask", data->config);108 if (!pmFPAfileBindFromArgs(&status, image, data->config, "PPSKYCELL.MASK", "MASK") || !status) {109 psError(PS_ERR_IO, false, "Failed to build file from PPSKYCELL.MASK");110 // XXX Cleanup111 return false;112 }113 }114 115 87 if (data->wcsrefName) { 116 88 fileArguments("WCSREF", wcsref->data[i], "Name of the WCS reference", data->config); … … 120 92 return(false); 121 93 } 122 /* if (!pmFPAfileBindFromArgs(&status, image, data->config, "PPSKYCELL.WCSREF", "WCSREF") || !status) { */123 /* psError(PS_ERR_IO, false, "Failed to build file from PPSKYCELL.WCSREF"); */124 /* return false; */125 /* } */126 94 } 127 128 95 } 129 96 … … 145 112 psError(psErrorCodeLast(), false, "Unable to define output."); 146 113 return false; 147 }148 if (data->masksName) {149 pmFPAfile *mask1 = pmFPAfileDefineOutput(data->config, bin1->fpa , "PPSKYCELL.BIN1.MASK");150 if (!mask1) {151 psError(psErrorCodeLast(), false, "Unable to define output.");152 return false;153 }154 mask1->save = true;155 pmFPAfile *mask2 = pmFPAfileDefineOutput(data->config, bin2->fpa , "PPSKYCELL.BIN2.MASK");156 if (!mask2) {157 psError(psErrorCodeLast(), false, "Unable to define output.");158 return false;159 }160 mask2->save = true;161 114 } 162 115
Note:
See TracChangeset
for help on using the changeset viewer.
