ImageSpotFinder: Add 1-bit mask to the calculation
This commit is contained in:
@@ -18,8 +18,8 @@ ImageAnalysisCPU::ImageAnalysisCPU(const DiffractionExperiment &in_experiment,
|
||||
roi_count(0),
|
||||
npixels(experiment.GetPixelsNum()),
|
||||
xpixels(experiment.GetXPixelsNum()),
|
||||
mask_1byte(npixels, false),
|
||||
spotFinder(in_integration),
|
||||
mask_1bit(npixels, false),
|
||||
spotFinder(mask_1bit, in_integration),
|
||||
indexer(in_indexer),
|
||||
saturation_limit(experiment.GetSaturationLimit()),
|
||||
mask(in_mask),
|
||||
@@ -30,7 +30,7 @@ ImageAnalysisCPU::ImageAnalysisCPU(const DiffractionExperiment &in_experiment,
|
||||
roi_names = experiment.ROI().GetROINameMap();
|
||||
|
||||
for (int i = 0; i < npixels; i++)
|
||||
mask_1byte[i] = (in_mask.GetMask().at(i) != 0);
|
||||
mask_1bit[i] = (in_mask.GetMask().at(i) != 0);
|
||||
}
|
||||
|
||||
void ImageAnalysisCPU::Analyze(DataMessage &output, std::vector<uint8_t> &image, AzimuthalIntegrationProfile &profile,
|
||||
@@ -97,7 +97,7 @@ void ImageAnalysisCPU::Analyze(DataMessage &output,
|
||||
profile.Clear(integration);
|
||||
|
||||
for (int i = 0; i < npixels; i++) {
|
||||
if (mask_1byte[i] != 0) {
|
||||
if (mask_1bit[i] != 0) {
|
||||
updated_image[i] = INT32_MIN;
|
||||
++masked_pixels;
|
||||
} else if (image[i] >= sat_pixel_val) {
|
||||
|
||||
Reference in New Issue
Block a user