Changeset 16989 for trunk/ppMerge/src/ppMergeCheckInputs.c
- Timestamp:
- Mar 13, 2008, 2:29:14 PM (18 years ago)
- File:
-
- 1 edited
-
trunk/ppMerge/src/ppMergeCheckInputs.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ppMerge/src/ppMergeCheckInputs.c
r13246 r16989 106 106 } 107 107 108 data->in->data[i]= pmFPAConstruct(config->camera);109 pmFPAview *view = pmFPAAddSourceFromHeader( data->in->data[i], header, options->format);108 pmFPA *fpa = pmFPAConstruct(config->camera); 109 pmFPAview *view = pmFPAAddSourceFromHeader(fpa, header, options->format); 110 110 psFree(view); 111 112 // Cull chips and cells that don't have data 113 // Otherwise the abundance of metadata in the concepts (esp. for GPC) can overload the memory 114 psArray *chips = fpa->chips; // Array of chips in output 115 for (int i = 0; i < chips->n; i++) { 116 pmChip *chip = chips->data[i]; // Chip of interest 117 psArray *cells = chip->cells; // Array of cells 118 int culled = 0; // Number of culled cells 119 for (int j = 0; j < cells->n; j++) { 120 pmCell *cell = cells->data[j]; 121 pmHDU *hdu = pmHDUGetLowest(fpa, chip, cell); // HDU for cell 122 if (!hdu || hdu->blankPHU) { 123 psFree(cell->concepts); 124 cell->concepts = NULL; 125 culled++; 126 } 127 } 128 if (culled == cells->n) { 129 psFree(chip->concepts); 130 chip->concepts = NULL; 131 } 132 } 133 data->in->data[i] = fpa; 134 111 135 112 136 // Use the first valid input as the basis for the output --- including the header
Note:
See TracChangeset
for help on using the changeset viewer.
