- Timestamp:
- Dec 31, 2008, 10:31:29 AM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branch_20081230/psModules/src/imcombine/pmReadoutCombine.c
r19086 r21075 105 105 106 106 // note the mask value actually used 107 ps MaskType maskVal = params->maskVal; // The mask value107 psImageMaskType maskVal = params->maskVal; // The mask value 108 108 if (maskVal) { 109 109 psString comment = NULL; // Comment to add to header … … 247 247 psF32 *pixelsData = pixels->data.F32; // Dereference pixels 248 248 249 psVector *mask = psVectorAlloc(inputs->n, PS_TYPE_ U8); // Mask for stack250 ps U8 *maskData = mask->data.U8; // Dereference mask249 psVector *mask = psVectorAlloc(inputs->n, PS_TYPE_VECTOR_MASK); // Mask for stack 250 psVectorMaskType *maskData = mask->data.PS_TYPE_VECTOR_MASK_DATA; // Dereference mask 251 251 252 252 psVector *weights = NULL; // Stack of weights … … 260 260 261 261 float keepFrac = 1.0 - params->fracLow - params->fracHigh; // Fraction of pixels to keep 262 ps MaskType maskVal = params->maskVal; // The mask value262 psImageMaskType maskVal = params->maskVal; // The mask value 263 263 264 264 #ifndef PS_NO_TRACE … … 278 278 // Dereference output products 279 279 psF32 **outputImage = output->image->data.F32; // Output image 280 ps U8 **outputMask = output->mask->data.U8; // Output mask280 psImageMaskType **outputMask = output->mask->data.PS_TYPE_IMAGE_MASK_DATA; // Output mask 281 281 psF32 **outputWeight = NULL; // Output weight map 282 282 if (output->weight) { … … 303 303 304 304 int numValid = 0; // Number of valid pixels in the stack 305 memset(maskData, 0, mask->n * sizeof(ps U8)); // Reset the mask305 memset(maskData, 0, mask->n * sizeof(psImageMaskType)); // Reset the mask 306 306 for (int r = 0; r < inputs->n; r++) { 307 307 pmReadout *readout = inputs->data[r]; // Input readout … … 318 318 // Check mask 319 319 psImage *roMask = readout->mask; // The mask image 320 if (roMask && roMask->data. U8[yIn][xIn] & maskVal) {320 if (roMask && roMask->data.PS_TYPE_IMAGE_MASK_DATA[yIn][xIn] & maskVal) { 321 321 maskData[r] = 1; 322 322 continue;
Note:
See TracChangeset
for help on using the changeset viewer.
