diff --git a/script/device/Image.py b/script/device/Image.py index 10f4848..f5bb1a7 100644 --- a/script/device/Image.py +++ b/script/device/Image.py @@ -8,9 +8,14 @@ class ImageIntensity(DeviceBase, Readable): self.setParent(image) def read(self): + global AUTO_THRESH1_COUNT, AUTO_THRESH2_COUNT, AUTO_THRESH3_COUNT, AUTO_THRESH4_COUNT ret = self.getParent().read() if ret is not None: (I_sum, area_I, thresh1_count, thresh2_count, thresh3_count, thresh4_count, I_sum_bgr, area_bgr) = ret + AUTO_THRESH1_COUNT=thresh1_count + AUTO_THRESH2_COUNT=thresh2_count + AUTO_THRESH3_COUNT=thresh3_count + AUTO_THRESH4_COUNT=thresh4_count ret = I_sum #if area_bgr > 0: # ret = ret - ((I_sum_bgr / area_bgr) * area_I)